Skip to content
Snippets Groups Projects
Commit ad0e04d2 authored by Deucе's avatar Deucе :ok_hand_tone4:
Browse files

Various fixes for 64-bit support

parent 20c5b3b5
Branches
Tags
No related merge requests found
Pipeline #5888 failed
...@@ -4,7 +4,7 @@ ...@@ -4,7 +4,7 @@
#endif /* OpenBSD safe string functions */ #endif /* OpenBSD safe string functions */
/* Widechar functions */ /* Widechar functions */
+#if (!defined(__GNUC__)) || (__GNUC__ < 5) +#if (!defined(__GNUC__)) || (__GNUC__ < 5) || (!defined(__MINGW32__))
int mbstowcs_s( size_t *retval, wchar_t *dst, size_t dstmax, int mbstowcs_s( size_t *retval, wchar_t *dst, size_t dstmax,
const char *src, size_t len ); const char *src, size_t len );
int wcstombs_s( size_t *retval, char *dst, size_t dstmax, int wcstombs_s( size_t *retval, char *dst, size_t dstmax,
...@@ -19,7 +19,7 @@ ...@@ -19,7 +19,7 @@
****************************************************************************/ ****************************************************************************/
#ifndef __STDC_LIB_EXT1__ #ifndef __STDC_LIB_EXT1__
+#if (!defined(__GNUC__)) || (__GNUC__ < 5) +#if (!defined(__GNUC__)) || (__GNUC__ < 5) || (!defined(__MINGW32__))
/* Minimal wrappers for the TR 24731 functions to map them to older stdlib /* Minimal wrappers for the TR 24731 functions to map them to older stdlib
equivalents. Because of potential issues when comparing a (signed) equivalents. Because of potential issues when comparing a (signed)
......
...@@ -49,11 +49,13 @@ UTIL_LDFLAGS += $(SMBLIB_LDFLAGS) $(UIFC-MT_LDFLAGS) $(CIOLIB-MT_LDFLAGS) $(XPDE ...@@ -49,11 +49,13 @@ UTIL_LDFLAGS += $(SMBLIB_LDFLAGS) $(UIFC-MT_LDFLAGS) $(CIOLIB-MT_LDFLAGS) $(XPDE
CONSOLE_LDFLAGS += $(LDFLAGS) $(SMBLIB_LDFLAGS) $(XPDEV_LDFLAGS) CONSOLE_LDFLAGS += $(LDFLAGS) $(SMBLIB_LDFLAGS) $(XPDEV_LDFLAGS)
UTIL_LIBS += $(HASH_LIBS) UTIL_LIBS += $(HASH_LIBS)
ifndef win
ifndef bcc ifndef bcc
ifneq ($(os),sunos) ifneq ($(os),sunos)
LDFLAGS += -lutil LDFLAGS += -lutil
endif endif
endif endif
endif
ifeq ($(os),sunos) # Solaris ifeq ($(os),sunos) # Solaris
LDFLAGS += -lnsl -lrt LDFLAGS += -lnsl -lrt
......
...@@ -3,7 +3,7 @@ include ${SRC_ROOT}/build/Common.gmake ...@@ -3,7 +3,7 @@ include ${SRC_ROOT}/build/Common.gmake
CFLAGS += -I${SRC_ROOT}/comio -I${SRC_ROOT}/sbbs3 $(XPDEV-MT_CFLAGS) CFLAGS += -I${SRC_ROOT}/comio -I${SRC_ROOT}/sbbs3 $(XPDEV-MT_CFLAGS)
LDFLAGS += $(XPDEV-MT_LDFLAGS) LDFLAGS += $(XPDEV-MT_LDFLAGS)
ifeq ($(os), win32) ifdef win
OBJS += $(MTOBJODIR)$(DIRSEP)comio_win32$(OFILE) OBJS += $(MTOBJODIR)$(DIRSEP)comio_win32$(OFILE)
CFLAGS += -DTELNET_NO_DLL CFLAGS += -DTELNET_NO_DLL
else else
......
...@@ -14,7 +14,9 @@ char* ltoa(long val, char* str, int radix); ...@@ -14,7 +14,9 @@ char* ltoa(long val, char* str, int radix);
} }
#endif #endif
#if (!defined(__MINGW32__)) || (__GNUC__ < 5)
#define strset(x,y) memset(x, y, strlen(x)) #define strset(x,y) memset(x, y, strlen(x))
#endif
#endif #endif
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment