[xmail] Quickfix for FreeBSD-7.x build error
There is a build error when building XMail-1.26 on FreeBSD-7.x servers, I didnt try it on 6.x but I guess they also have this problem. #gmake -f Makefile.bsd g++ -I. -D__UNIX__ -D__BSD__ -D__FREEBSD__ -D_REENTRANT=1 -D_THREAD_SAFE=1 -DHAS_SYSMACHINE -D_GNU_SOURCE -D_LARGEFILE64_SOURCE -D_POSIX_PTHREAD_SEMANTICS -O2 -c MkMachDep.cpp g++ -o bin/MkMachDep MkMachDep.o -lssl -lcrypto -lkvm -lcrypt -pthread -lc_r /usr/bin/ld: cannot find -lc_r gmake: *** [bin/MkMachDep] Error 1 This is simply because libc_r is deprecated and no longer installed by default in FreeBSD, however it works fine on FreeBSD-4.11. To fix the problem, open Makefile.bsd with your favorite text editor. Find this: SYSTYPE = freebsd CFLAGS := $(CFLAGS) -I. -D__UNIX__ -D__BSD__ -D__FREEBSD__ -D_REENTRANT=1 -D_THREAD_SAFE=1 -DHAS_SYSMACHINE LDFLAGS := $(LDFLAGS) $(SSLLIBS) -lkvm -lcrypt -pthread -lc_r Remove the last argument -lc_r Save and exit. ___ xmail mailing list xmail@xmailserver.org http://xmailserver.org/mailman/listinfo/xmail
Re: [xmail] Quickfix for FreeBSD-7.x build error
On Wed, 1 Jul 2009, fred wrote: There is a build error when building XMail-1.26 on FreeBSD-7.x servers, I didn?t try it on 6.x but I guess they also have this problem. #gmake -f Makefile.bsd g++ -I. -D__UNIX__ -D__BSD__ -D__FREEBSD__ -D_REENTRANT=1 -D_THREAD_SAFE=1 -DHAS_SYSMACHINE -D_GNU_SOURCE -D_LARGEFILE64_SOURCE -D_POSIX_PTHREAD_SEMANTICS -O2 -c MkMachDep.cpp g++ -o bin/MkMachDep MkMachDep.o -lssl -lcrypto -lkvm -lcrypt -pthread -lc_r /usr/bin/ld: cannot find -lc_r gmake: *** [bin/MkMachDep] Error 1 This is simply because libc_r is deprecated and no longer installed by default in FreeBSD, however it works fine on FreeBSD-4.11. To fix the problem, open Makefile.bsd with your favorite text editor. Thank you, but the problem is that in older versions of FreeBSD, libc was not reentrant by default (on certain functions), so w/out explicit linking against libc_r it'd break. Probably the correct fix is one that tests the FreeBSD version and use or not, the libc_r linking explicitly. - Davide ___ xmail mailing list xmail@xmailserver.org http://xmailserver.org/mailman/listinfo/xmail
Re: [xmail] Quickfix for FreeBSD-7.x build error
On Wed, 1 Jul 2009, Davide Libenzi wrote: On Wed, 1 Jul 2009, fred wrote: There is a build error when building XMail-1.26 on FreeBSD-7.x servers, I didn?t try it on 6.x but I guess they also have this problem. #gmake -f Makefile.bsd g++ -I. -D__UNIX__ -D__BSD__ -D__FREEBSD__ -D_REENTRANT=1 -D_THREAD_SAFE=1 -DHAS_SYSMACHINE -D_GNU_SOURCE -D_LARGEFILE64_SOURCE -D_POSIX_PTHREAD_SEMANTICS -O2 -c MkMachDep.cpp g++ -o bin/MkMachDep MkMachDep.o -lssl -lcrypto -lkvm -lcrypt -pthread -lc_r /usr/bin/ld: cannot find -lc_r gmake: *** [bin/MkMachDep] Error 1 This is simply because libc_r is deprecated and no longer installed by default in FreeBSD, however it works fine on FreeBSD-4.11. To fix the problem, open Makefile.bsd with your favorite text editor. Thank you, but the problem is that in older versions of FreeBSD, libc was not reentrant by default (on certain functions), so w/out explicit linking against libc_r it'd break. Probably the correct fix is one that tests the FreeBSD version and use or not, the libc_r linking explicitly. I did fix it so that it recognizes is libc_r is there or not. That should work for both old and new FreeBSD versions. - Davide ___ xmail mailing list xmail@xmailserver.org http://xmailserver.org/mailman/listinfo/xmail