[openbeosnetteam] Networking and the new Build System
- From: Ingo Weinhold <bonefish@xxxxxxxxxxxxxxx>
- To: openbeosnetteam@xxxxxxxxxxxxx
- Date: Thu, 27 Oct 2005 16:48:06 +0200
Howdy networkers,
with the new build system I introduced a strict separation between tools,
libraries, and headers for the platform that hosts the build and the one we
build for. In case of TARGET_PLATFORM=haiku the specified cross compilation
tools are used, *only* the headers in the tree and the ones belonging to
the compiler, and the only libraries we link against are those we build
ourselves from the sources.
If the TARGET_PLATFORM is anything else, the build system builds for the
host platform, which has to be at least compatible with what is set as
target platform (i.e. you can build for R5 under Dan0, but not the other
way around). Therefore it uses the tools, headers, and libraries of the
host platform.
This is more restrictive than it was before, but for good reason. For one
it solves the convoluted mess we had before, which only worked because
Haiku is mostly source and binary compatible to BeOS. The other reason
being that it simplifies the build system a good deal, since not every
cross-compilation combination has to be supported (the only
cross-compilation done now is for target platform Haiku).
Now you wonder what this all has to do with networking. Well, I tried to
build the haiku-networkingkit-cvs package for TARGET_PLATFORM=r5 with the
new build system and it fails quite early. Apparently there are
dependencies to libroot.so and libbe.so (the ones for Haiku), but once
found where, this can probably easily be solved. The real problem is that
public networking headers are used that don't exist on BeOS R5 (and one
probably wouldn't want to use them anyway). For libkernelppp.a
(src/add-ons/kernel/network/ppp/shared/libkernelppp) I added:
if $(TARGET_PLATFORM) != haiku {
UseHeaders [ FDirName $(HAIKU_TOP) headers posix ] : true ;
}
I.e. when not compiling for Haiku we use Haiku's public POSIX headers. This
gets the build a bit further, but it nevertheless fails complaining:
/boot/home/develop/obos/build_system_redesign/src/add-ons/kernel/network/ppp
/shared/libkernelppp/KPPPInterface.cpp:1317: implicit declaration of
function `int atomic_add64(...)'
But besides that using POSIX headers indeed mean using *all* POSIX headers,
not only the networking headers. This is not correct, though it may work as
long as Haiku is basically source and binary compatible with BeOS.
How shall we proceed? Shall I try and fix things before merging the build
system changes into the trunk or do you want to do that yourself afterwards?
CU, Ingo
- Follow-Ups:
- [openbeosnetteam] Re: Networking and the new Build System
- From: Philippe Houdoin
Other related posts:
- » [openbeosnetteam] Networking and the new Build System
- » [openbeosnetteam] Re: Networking and the new Build System
- » [openbeosnetteam] Re: Networking and the new Build System
- » [openbeosnetteam] Re: Networking and the new Build System
- » [openbeosnetteam] Re: Networking and the new Build System
- » [openbeosnetteam] Re: Networking and the new Build System
- » [openbeosnetteam] Re: Networking and the new Build System
- » [openbeosnetteam] Re: Networking and the new Build System
- » [openbeosnetteam] Re: Networking and the new Build System
- » [openbeosnetteam] Re: Networking and the new Build System
- » [openbeosnetteam] Re: Networking and the new Build System
- [openbeosnetteam] Re: Networking and the new Build System
- From: Philippe Houdoin