[nasm:nasm-2.15.xx] portability: Watcom C portability updates
nasm-bot for sezero
sezero at users.sourceforge.net
Mon Jul 6 13:06:03 PDT 2020
Commit-ID: 1969dab9c6d4b3d1e44850c013069ce2f088c23a
Gitweb: http://repo.or.cz/w/nasm.git?a=commitdiff;h=1969dab9c6d4b3d1e44850c013069ce2f088c23a
Author: sezero <sezero at users.sourceforge.net>
AuthorDate: Fri, 4 Oct 2019 22:13:00 +0300
Committer: H. Peter Anvin (Intel) <hpa at zytor.com>
CommitDate: Mon, 6 Jul 2020 13:02:26 -0700
portability: Watcom C portability updates
- config/watcom.h: update.
- Mkfiles/openwcom.mak: -wcd=124 to silence "Comparison result always 0"
warnings from error.h::debug_level()
Signed-off-by: H. Peter Anvin (Intel) <hpa at zytor.com>
---
Mkfiles/openwcom.mak | 4 ++--
config/watcom.h | 30 +++++++++++++++++++++++-------
2 files changed, 25 insertions(+), 9 deletions(-)
diff --git a/Mkfiles/openwcom.mak b/Mkfiles/openwcom.mak
index f5bdf085..262a0419 100644
--- a/Mkfiles/openwcom.mak
+++ b/Mkfiles/openwcom.mak
@@ -14,13 +14,13 @@ mandir = $(prefix)\man
CC = *wcl386
DEBUG =
-CFLAGS = -zq -6 -ox -wx -ze -fpi $(DEBUG)
+CFLAGS = -zq -6 -ox -wx -wcd=124 -ze -fpi $(DEBUG)
BUILD_CFLAGS = $(CFLAGS) $(%TARGET_CFLAGS)
INTERNAL_CFLAGS = -I$(srcdir) -I. -I$(srcdir)\include -I$(srcdir)\x86 -Ix86 -I$(srcdir)\asm -Iasm -I$(srcdir)\disasm -I$(srcdir)\output
ALL_CFLAGS = $(BUILD_CFLAGS) $(INTERNAL_CFLAGS)
LD = *wlink
LDEBUG =
-LDFLAGS = op quiet $(%TARGET_LFLAGS) $(LDEBUG)
+LDFLAGS = op q $(%TARGET_LFLAGS) $(LDEBUG)
LIBS =
STRIP = wstrip
diff --git a/config/watcom.h b/config/watcom.h
index 1ef2ee74..8d49026d 100644
--- a/config/watcom.h
+++ b/config/watcom.h
@@ -48,32 +48,39 @@
#define HAVE_DECL_STRLCPY 1
#define HAVE_DECL_STRNCASECMP 1
#define HAVE_DECL_STRNICMP 1
-#define HAVE_INTTYPES_H 1
#ifndef __LINUX__
#define HAVE_IO_H 1
#endif
#define HAVE_LIMITS_H 1
#define HAVE_MEMORY_H 1
#define HAVE_SNPRINTF 1
+#if (__WATCOMC__ >= 1230)
+#undef HAVE__BOOL /* need stdbool.h */
#define HAVE_STDBOOL_H 1
+#define HAVE_INTTYPES_H 1
#define HAVE_STDINT_H 1
+#define HAVE_UINTPTR_T 1
+#endif
#define HAVE_STDLIB_H 1
-#define HAVE_STRCASECMP 1
#define HAVE_STRCSPN 1
#define HAVE_STRICMP 1
-#define HAVE_STRINGS_H 1
-#define HAVE_STRING_H 1
-#define HAVE_STRLCPY 1
-#define HAVE_STRNCASECMP 1
#define HAVE_STRNICMP 1
#define HAVE_STRSPN 1
+#define HAVE_STRING_H 1
+#if (__WATCOMC__ >= 1240)
+#define HAVE_STRCASECMP 1
+#define HAVE_STRNCASECMP 1
+#define HAVE_STRLCPY 1
+#define HAVE_STRINGS_H 1
+#endif
#define HAVE_SYS_STAT_H 1
#define HAVE_SYS_TYPES_H 1
+#define HAVE_FCNTL_H 1
#define HAVE_UNISTD_H 1
#define HAVE_VSNPRINTF 1
#define STDC_HEADERS 1
-#define inline __inline
+#define HAVE__FULLPATH 1
#define HAVE_ACCESS
#define HAVE_STRUCT_STAT
#define HAVE_STAT
@@ -85,5 +92,14 @@
#define HAVE_CHSIZE
#define HAVE__CHSIZE
#endif
+#define HAVE_ISASCII
+#define HAVE_ISCNTRL
+
+#if (__WATCOMC__ >= 1250)
+#define restrict __restrict
+#else
+#define restrict
+#endif
+#define inline __inline
#endif /* NASM_CONFIG_WATCOM_H */
More information about the Nasm-commits
mailing list