how to compile the HOSTAPD into a liberary?

Stjepan Gros sgros at zemris.fer.hr
Wed Oct 17 02:53:00 EDT 2007


On Wed, 2007-10-17 at 10:40 +0800, Joren Joanna wrote:
> Hi all,

Hi,

> Now I am developing a software using with RADIUS protocol, then found
> that your work HOSTAPD is a great software, so I wanna use the
> radius_client part in hostapd for my software as the Radius Client.
> 
> These days, I have done many tests of this idea. So, my question is:
> 1. Is the idea correct?
> 2. If correct, Which files should be included in the liberary makefile?
> 3. How to use the liberary? Especially for the workflow.
> 
> Your help will be great appreciated. Thanks.

This is a good question. I was planning to raise similar question also,
but due to the lack of time wasn't able to do so. So, I'll do that now.

We use supplicant part as a library in IKEv2 protocol implementation.
More specifically, version 0.4.7. Makefiles that produce dynamic
libraries can be found in the contrib/ subdirectory of the ikev2
(ikev2.sourceforge.net) source as well as README file that details how
to build libraries.

The exact content of the Makefiles was trial and error process. But
eventually, it worked. The main problem are some auxiliary functions,
e.g. logging, that are mixed with other functions and so are not easily
replaceable with ikev2's equivalents. This is necessary in order to
better integrate the supplicant code into ikev2 implementation.

This problem is temporarily solved in a way that we exclude problematic
files from the library build process and duplicate code in our codebase.
I believe that not much of the code is duplicated, but obviously, we
might argue about licensing issues, so it's on our TODO list to resolve
this, as well as to use newer versions of the supplicant code.

The best way to resolve this issue is to put the problematic functions
into separate file in order to make them replaceable. The question is,
is this possible? 

Stjepan




More information about the HostAP mailing list