2.0.0-pre1 - cannot build on FreeBSD
David Wood
david at wood2.org.uk
Tue May 22 19:47:46 CEST 2007
Dear all,
I've put in quite a bit of work today towards porting 2.0.0-pre1 to
FreeBSD, with the intention of submitting a FreeRADIUS 2 port as soon as
possible.
Unfortunately, there's a problem which I don't have the autoconf skills
to patch quickly. When checking (and later attempting to use) net/if.h,
you need to #include sys/socket.h on FreeBSD to get the definition of
struct sockaddr.
If someone can give me a patch, I'll carry on with the work.
What actually happens is that configure complains:
configure: WARNING: net/if.h: present but cannot be compiled
configure: WARNING: net/if.h: check for missing prerequisite
headers?
configure: WARNING: net/if.h: see the Autoconf documentation
configure: WARNING: net/if.h: section "Present But Cannot Be
Compiled"
configure: WARNING: net/if.h: proceeding with the preprocessor's result
configure: WARNING: net/if.h: in the future, the compiler will take
precedence
with the underlying entry in config.log of:
configure:22662: checking net/if.h usability
configure:22679: cc -c -O -pipe -march=pentium3 -I/usr/local/include
-L/usr/local/lib -D_REENTRANT -D_POSIX_PTHREAD_SEMANTICS conft
est.c >&5
In file included from conftest.c:83:
/usr/include/net/if.h:265: error: field `ifru_addr' has incomplete type
/usr/include/net/if.h:266: error: field `ifru_dstaddr' has incomplete
type
/usr/include/net/if.h:267: error: field `ifru_broadaddr' has incomplete
type
/usr/include/net/if.h:299: error: field `ifra_addr' has incomplete type
/usr/include/net/if.h:300: error: field `ifra_broadaddr' has incomplete
type
/usr/include/net/if.h:301: error: field `ifra_mask' has incomplete type
/usr/include/net/if.h:368: error: field `addr' has incomplete type
/usr/include/net/if.h:369: error: field `dstaddr' has incomplete type
(the incomplete type is no definition of struct sockaddr).
If you let things continue, the build eventually fails thus:
/usr/local/bin/libtool --mode=compile cc -O -pipe -march=pentium3
-I/usr/local/include -L/usr/local/lib -D_REENTRANT -D_POSIX_PTHRE
AD_SEMANTICS -Wall -D_GNU_SOURCE -DNDEBUG -D_LIBRADIUS
-I/var/ports/usr/ports_updated/net/freeradius2/work/freeradius-server-2.0
.0-p
re1/src -c misc.c
cc -O -pipe -march=pentium3 -I/usr/local/include -L/usr/local/lib
-D_REENTRANT -D_POSIX_PTHREAD_SEMANTICS -Wall -D_GNU_SOURCE -DNDE
BUG -D_LIBRADIUS
-I/var/ports/usr/ports_updated/net/freeradius2/work/freeradius-server-2.0
.0-pre1/src -c misc.c -fPIC -DPIC -o .lib
s/misc.o
misc.c: In function `ip_hton':
misc.c:424: error: `AF_INET' undeclared (first use in this function)
misc.c:424: error: (Each undeclared identifier is reported only once
misc.c:424: error: for each function it appears in.)
misc.c: In function `ip_ntoh':
misc.c:455: error: storage size of 'ss' isn't known
misc.c:469: error: `AF_INET' undeclared (first use in this function)
misc.c:455: warning: unused variable `ss'
misc.c: In function `lrad_ipaddr_cmp':
misc.c:585: error: `AF_INET' undeclared (first use in this function)
gmake[4]: *** [misc.lo] Error 1
(sys/socket.h contains the #define for AF_INET - so if it's not the same
problem, it's a very similar one).
If anyone wants more information (logs, typescript), I'll happily
provide them.
I also can't get the PGP signature on the 2.0.0-pre1 tarball to verify -
in the fairly old version of PGP 7 on my Windows XP box (which is the
only place I have my keyrings), I get a bad signature error. The
signature on 1.1.6 works just fine.
Looking forward to 2.0 - and trusting this is useful,
David
--
David Wood
david at wood2.org.uk
More information about the Freeradius-Users
mailing list