compile on BSD

This commit is contained in:
psyc://psyced.org/~lynX 2015-01-07 18:55:08 +01:00
parent 727399dbcf
commit a83b39cb87
3 changed files with 20 additions and 9 deletions

2
TODO
View File

@ -24,6 +24,8 @@ BUGS
' parse' in ' net/irc/user.c' (' net/irc/user#User') line 32 ' parse' in ' net/irc/user.c' (' net/irc/user#User') line 32
[...] [...]
' CATCH' in ('drivers/ldmud/library/library') ' CATCH' in ('drivers/ldmud/library/library')
- libpsyc detection fails on BSD, hotfix by adding #define HAS_PSYC manually
- BSD needs -liconv in generated makefile
WINDOWS SUPPORT WINDOWS SUPPORT
+ with the new __NO_SRV__ detection psyclpc compiles under cygwin but it + with the new __NO_SRV__ detection psyclpc compiles under cygwin but it

View File

@ -1221,6 +1221,7 @@ echo "*** libpsyc"
lp_cv_has_psyc_lib="no" lp_cv_has_psyc_lib="no"
AC_CHECK_LIB(psyc,main, lp_cv_has_psyc_lib="yes") AC_CHECK_LIB(psyc,main, lp_cv_has_psyc_lib="yes")
# dont know why this fails on bsd, had to patch machine.h manually... FIXME
if test $lp_cv_has_psyc_lib = yes; then if test $lp_cv_has_psyc_lib = yes; then
LIBS="-lpsyc" LIBS="-lpsyc"
AC_CACHE_CHECK(for libpsyc usability,lp_cv_has_psyc, AC_CACHE_CHECK(for libpsyc usability,lp_cv_has_psyc,
@ -1304,7 +1305,13 @@ if test -f /usr/sbin/iconvconfig; then
lp_cv_has_broken_iconv="no" lp_cv_has_broken_iconv="no"
fi fi
else else
if test -f /usr/local/bin/iconv; then
lp_cv_has_broken_iconv="no" lp_cv_has_broken_iconv="no"
lp_cv_has_iconv="yes"
else
lp_cv_has_broken_iconv="no"
lp_cv_has_iconv="no"
fi
fi fi
echo "$as_me:$LINENO: result: $lp_cv_has_broken_iconv" >&5 echo "$as_me:$LINENO: result: $lp_cv_has_broken_iconv" >&5
echo "${ECHO_T}$lp_cv_has_broken_iconv" >&6 echo "${ECHO_T}$lp_cv_has_broken_iconv" >&6

View File

@ -267,6 +267,7 @@ typedef bytecode_t * bytecode_p;
# define LOAD_INT32(d,p) LOAD_4BYTE(d,p) # define LOAD_INT32(d,p) LOAD_4BYTE(d,p)
# define STORE_INT32(p,d) STORE_4BYTE(p,d) # define STORE_INT32(p,d) STORE_4BYTE(p,d)
#else #else
# ifndef GET_LONG /* happens on BSD */
# define GET_LONG(d,p) GET_4BYTE(d,p) # define GET_LONG(d,p) GET_4BYTE(d,p)
# define LOAD_LONG(d,p) LOAD_4BYTE(d,p) # define LOAD_LONG(d,p) LOAD_4BYTE(d,p)
# define PUT_LONG(p,d) MACRO(unsigned long _us = (unsigned long)d; \ # define PUT_LONG(p,d) MACRO(unsigned long _us = (unsigned long)d; \
@ -279,6 +280,7 @@ typedef bytecode_t * bytecode_p;
# define LOAD_INT32(d,p) LOAD_2BYTE(d,p) # define LOAD_INT32(d,p) LOAD_2BYTE(d,p)
# endif # endif
#endif
#endif /* CHAR_BIT */ #endif /* CHAR_BIT */