diff --git a/mbuni/ChangeLog b/mbuni/ChangeLog index 7631e51..e614699 100644 --- a/mbuni/ChangeLog +++ b/mbuni/ChangeLog @@ -1,3 +1,5 @@ +2010-09-21 P. A. Bagyenda + * Patch to allow compilation under FreeBSD 8.1 (thanks to Piotr Isajew ) 2010-08-09 P. A. Bagyenda * mmsbox-mm1 change: sleep after each run, so that under high load, we are not hanging up too soon on modem diff --git a/mbuni/configure.ac b/mbuni/configure.ac index 47dc750..a4886f0 100644 --- a/mbuni/configure.ac +++ b/mbuni/configure.ac @@ -85,10 +85,15 @@ case "$host" in CFLAGS="$CFLAGS -D_XOPEN_SOURCE=600 -D_BSD_SOURCE -O4 -Wall" LDFLAGS="$LDFLAGS -rdynamic" ;; - *-*-openbsd* | *-*-freebsd*) + *-*-openbsd*) CFLAGS="$CFLAGS -pthread" AC_CHECK_LIB(c_r, pthread_exit, [LIBS="$LIBS -lc_r -lpthread"; pthread="yes"]) ;; + *-*-freebsd*) + LDFLAGS="$LDFLAGS -export-dynamic" + CFLAGS="$CFLAGS -DFREEBSD=1 -pthread" + AC_CHECK_LIB(c_r, pthread_exit, [LIBS="$LIBS -lc_r -lpthread"; pthread="yes"]) + ;; esac AC_ARG_WITH(cflags, diff --git a/mbuni/mmsc/mms_billing_shell.c b/mbuni/mmsc/mms_billing_shell.c index ca17b64..85dcca7 100644 --- a/mbuni/mmsc/mms_billing_shell.c +++ b/mbuni/mmsc/mms_billing_shell.c @@ -13,8 +13,10 @@ #include #include #ifndef DARWIN +#ifndef FREEBSD #include #endif +#endif #include