utils: build utility programs by Open Watcom for Linux and Windows

This commit is contained in:
Jiří Malák 2024-07-06 08:54:27 +02:00 committed by Kenneth J Davis
parent c012700190
commit e985cc36b3
5 changed files with 12 additions and 14 deletions

View File

@ -100,14 +100,11 @@ static unsigned short __inline getSS(void)
asm mov ax, ss;
}
#elif defined(__WATCOMC__) && defined(BUILD_UTILS)
/* workaround for building some utils with OpenWatcom (owcc) */
#define MC68K
#elif defined(__WATCOMC__) /* don't know a better way */
#if defined(_M_I86)
#define I86
#endif
#define __int__(intno) asm int intno;
void disable(void);
#pragma aux disable = "cli" modify exact [];
@ -131,10 +128,11 @@ unsigned short getSS(void);
/* enable Possible loss of precision warning for compatibility with Borland */
#pragma enable_message(130)
#if _M_IX86 >= 300 || defined(M_I386)
#ifndef I386
#define I386
#endif
#else
/* workaround for building some utils with OpenWatcom (flat model) */
#define MC68K
#endif
#elif defined (_MYMC68K_COMILER_)

View File

@ -12,7 +12,7 @@ CP=cp
ECHOTO=echo>>
INITPATCH=@echo > /dev/null
CLDEF=1
CLT=gcc -Wall -DDOSC_TIME_H -I../hdr -o $@
CLT=wcl386 -bcl=linux -DDOSC_TIME_H -I../hdr -fe=$@ -I$(COMPILERPATH)/lh
CLC=$(CLT)
CFLAGST=-fo=.obj $(CFLAGST)
ALLCFLAGS=-fo=.obj $(ALLCFLAGS)

View File

@ -7,13 +7,13 @@ include "../mkfiles/watcom.mak"
DIRSEP=\
INCLUDEPATH=$(COMPILERPATH)$(DIRSEP)h
INCLUDEPATH=$(COMPILERPATH)\h
#RM=del 2>nul
#CP=copy
#ECHOTO=echo>>
#INITPATCH=@echo > nul
CLDEF=1
CLT=owcc -DDOSC_TIME_H -DBUILD_UTILS -I../hdr -o $@
CLT=wcl386 -bcl=nt -DDOSC_TIME_H -I..\hdr -fe=$@ -I$(COMPILERPATH)\h -I$(COMPILERPATH)\h\nt
CLC=$(CLT)
CFLAGST=-fo=.obj $(CFLAGST)
ALLCFLAGS=-fo=.obj $(ALLCFLAGS)

View File

@ -13,7 +13,7 @@
*****************************************************************************/
#include <stdio.h>
#ifdef __GNUC__
#if defined(__GNUC__) || defined(__WATCOMC__)
#include <unistd.h>
#else
#include <io.h>