1
0
Fork 0
mirror of git://git.psyced.org/git/psyclpc synced 2024-08-15 03:20:16 +00:00

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

6
TODO
View file

@ -21,9 +21,11 @@ BUGS
Error loading place: *Error in loading object: 'place/testotest'. Error loading place: *Error in loading object: 'place/testotest'.
Warning: place "/place/testotest" did not return ME on load() Warning: place "/place/testotest" did not return ME on load()
2009.04.21 12:35:19 ERROR caught. Backtrace: 2009.04.21 12:35:19 ERROR caught. Backtrace:
' 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
lp_cv_has_broken_iconv="no" if test -f /usr/local/bin/iconv; then
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,17 +267,19 @@ 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
# define GET_LONG(d,p) GET_4BYTE(d,p) # ifndef GET_LONG /* happens on BSD */
# define LOAD_LONG(d,p) LOAD_4BYTE(d,p) # define GET_LONG(d,p) GET_4BYTE(d,p)
# define PUT_LONG(p,d) MACRO(unsigned long _us = (unsigned long)d; \ # define LOAD_LONG(d,p) LOAD_4BYTE(d,p)
# define PUT_LONG(p,d) MACRO(unsigned long _us = (unsigned long)d; \
PUT_4BYTE(p,_us);) PUT_4BYTE(p,_us);)
# define STORE_LONG(p,d) MACRO(unsigned long _us = (unsigned long)d; \ # define STORE_LONG(p,d) MACRO(unsigned long _us = (unsigned long)d; \
STORE_4BYTE(p,_us);) STORE_4BYTE(p,_us);)
# define RSTORE_LONG(p,d) MACRO(unsigned long _us = (unsigned long)d; \ # define RSTORE_LONG(p,d) MACRO(unsigned long _us = (unsigned long)d; \
RSTORE_4BYTE(p,_us);) RSTORE_4BYTE(p,_us);)
/* TODO: The above assumes sizeof(long) == 4. */ /* TODO: The above assumes sizeof(long) == 4. */
# 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 */