SHORT VERSION:
I have some information for the FreeRADIUS developers regarding building
FreeRADIUS v0.9.3 under Cygwin on MS Windows. With your help/input, I hope to get you
the necessary patch(es) you need to have FreeRADIUS build cleanly under Cygwin as it
does elsewhere.
LONG VERSION:
Ok, though I've been using FreeRADIUS since v0.81, this is my first post to this list,
so a quick "hey" to everyone. Now down to business. :-)
Back in April 2003 I had an email exchange with Alan DeKok regarding FreeRADIUS and
mod_auth_radius. At the time I was looking for a Windows binary of mod_auth_radius to
use with Apache 1.3.x for Windows, and since then have been sidetracked by one project
or another. I hope to get back to that issue at some point, but first, FreeRADIUS
itself.
I would very much like to tackle the issue of getting FreeRADIUS to run on Windows
(most likely under Cygwin). I did some Googling and found that there's been some
chitchat here and there, but nothing definitive. So here's my initial input on the
subject, aimed towards the FreeRADIUS developers.
Using the following configuration:
* Intel PIII 866 PC w/ 512MB RAM, 20GB HD, etc.
(irrelevant really, but just in case you think you need to know)
* Windows XP SP1 w/ all Windows Updates
* Cygwin v1.5.8-1 with ALL packages installed (just to be sure ;-) )
* FreeRADIUS v0.9.3
I have been able to follow the standard
./configure
make
sequence, only having the build blow up on an undefined _inet_pton near the end of the
build process. The last few lines of output follow for reference:
______________________________________________________________________
dlltool --as=as --dllname cyggdbm-4.dll --def .libs/cyggdbm-4.dll-def --output-l
ib .libs/libimp-cyggdbm-4.a
gcc rlm_ippool_tool.o -o rlm_ippool_tool.exe -lresolv -lpthread .libs/libimp-cy
ggdbm-4.a
rlm_ippool_tool.o(.text+0x26f): In function `addip':
/usr/local/freeradius-0.9.3/src/modules/rlm_ippool/rlm_ippool_tool.c:115: undefi
ned reference to `_inet_pton'
collect2: ld returned 1 exit status
make[6]: *** [rlm_ippool_tool] Error 1
make[6]: Leaving directory `/usr/local/freeradius-0.9.3/src/modules/rlm_ippool'
make[5]: *** [common] Error 1
make[5]: Leaving directory `/usr/local/freeradius-0.9.3/src/modules'
make[4]: *** [all] Error 2
make[4]: Leaving directory `/usr/local/freeradius-0.9.3/src/modules'
make[3]: *** [common] Error 1
make[3]: Leaving directory `/usr/local/freeradius-0.9.3/src'
make[2]: *** [all] Error 2
make[2]: Leaving directory `/usr/local/freeradius-0.9.3/src'
make[1]: *** [common] Error 1
make[1]: Leaving directory `/usr/local/freeradius-0.9.3'
make: *** [all] Error 2
______________________________________________________________________
This is not a surprise to me. inet_pton() is an IPv6 function, and I've often found
network app builds die due to this or similar. Cygwin only supports IPv4 functions
like inet_aton()/inet_ntoa() (i.e., no INET6 support yet), and at the moment IPv6
support in Windows OSes is quite limited (only available in beta form as it were for
XP Pro and up, and I believe only now being shipped in a commercial grade version in
Windows 2003 Server). Talk of adding INET6 support to Cygwin is ongoing, with a site
in Japan leading development, but who knows how long that will be.
A quick 'grep' of the FreeRADIUS source shows this function is called only ONE time in
all of the source code, and that call is in the file
./src/modules/rlm_ippool/rlm_ippool_tool.c
and there are no instances of inet_pton() in the source.
So the question is, would it be possible to modify the FreeRADIUS source to use IPv4
functions like inet_ntoa() instead of inet_ntop() when building under Cygwin? I will
investigate this when I have time, but as you guys have been doing this for some time
and know the code like the back of your hand, figured it's likely a quick click/bang
for you to make the necessary adjustments to the above file.
For what it's worth, I found the following link, which might be of some help (though
not really sure, as I don't code at this level near as much as I'd like):
http://www.kame.net/newsletter/19980604/
However, as I've been working on getting other open-source projects to build under
Cygwin, I'm starting to learn the ins and outs slowly. (My proudest moment thus far
was getting the open-source Jabberd 1.4.x source to build cleanly, and my patches are
now part of Jabberd 1.4.3. Yeah! Ok ok, nothing major, but it's a start.)
I don't know if there are other Cygwin-unsupported functions lurking in the FreeRADIUS
code, but I must say that this build process has gone much further than it ever did in
the past, so I believe it's quite close.
For those not familiar with recent changes in Cygwin, one thing that has helped
immensely is the addition of the minires package, which provides a minimalist BIND
resolver set of functions (something SORELY missing from Cygwin). This has allowed
net apps like FreeRADIUS to build where they would fail much earlier in the past due
to a lack of libresolv, etc.
If one of the developers is bored and thinks they know how I can replace the
inet_pton() function with something like inet_aton(), I'll be more than glad to apply
the changes and attempt another build. Otherwise, I'll have to sit and read for
awhile to fathom the intricacies of these functions and how to use one in place of the
other. :-/
Anyway, hope this is of some help.
__ _ _ _ ________________ Frank Seesink _______
\\ // \\ / Tele. Network Specialist II
\\ /\ // \\ / (304) 293-5192 x.241
____ \/ \/ \/ NET______________________________________
West Virginia Network [EMAIL PROTECTED]
--
This message has been scanned for viruses and dangerous
content by WVNET, and is believed to be clean.
-
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html