Hello Ingo;
I'm now trying to integrate this tool into the jam-based build system.
I'm having a bit of trouble getting jam to recognize the target.
Looking at the example you had suggested;
cd ~/Haiku/haiku/generated.x86gcc2
jam -q "update_package_requires"
...I get...
Starting build of type regular ...
WebKit build feature not available for x86_gcc2
don't know how to make update_package_requires
...patience...
...found 1 target(s)...
...can't find 1 target(s)...
The same happens with my new target based on the
"update_package_requires" directory contents.
Am I missing something?
Also, unless I write the PNG out manually, I will need libpng as a
dependency of my tool. I guess a build-host variant of libpng is not
being built as part of the build system. Do you have any advice around
that?
Regards;
On 7/07/15 13:42, Ingo Weinhold wrote:
On 06.07.2015 13:29, Andrew Lindesay wrote:
I'm a bit new to the Haiku code-base and the build system. I'm trying
to get a HVIF render happening linux-native so that I can raster the
icons on the HDS application-server.
I think that to use libicon, I'm going to need to link in;
* BBitmap (c.f. IconRenderer)
* BList (c.f. StyleContainer)
I can see the object files for those in the build artifacts or
intermediates;
../generat../linux/x86_64/release/build/libbe/interface
../generat../linux/x86_64/release/build/libbe/support
Is there a build platform "libbe_build" or equivalent?
Yes, there is (libbe_build.so). Surprisingly enough, I seem to have
included the libicon code in it (cf. [1] which is the subtree
responsible for building libbe_build), so you don't need to bother with
libicon_build, but can just link against libbe_build.
If you want to work within the framework of the build system -- that
would be easiest -- just have a look at how a simple build system tool
using libbe_build is built [2]. This example also links against
libpackage_build.so, which you can omit, but aside from that you can
just copy and paste + search and replace the directory and its Jamfile.
Include the subdirectory in the parent directory's Jamfile
(src/tools/Jamfile) and everything will be set up to build your tool
with "jam -q name_of_tool".
Note that the libraries are built as shared libraries and placed in
objects/<host-OS>/lib/. You can use "jam -q run :name_of_tool ..." to
directly run your tool (all arguments prefixed with a colon will be
considered targets, which will be built, and the arguments in the
command line will be replaced with the respective file names). It will
automatically set up LD_LIBRARY_PATH (or whatever it is called on the
host OS) to include the library directory.
CU, Ingo
[1]
http://cgit.haiku-os.org/haiku/tree/src/build/libbe?id=db8517e2d7ecdd0e776cbcf5f5cb4d70f0f4d52f
[2]
http://cgit.haiku-os.org/haiku/tree/src/tools/update_package_requires?id=db8517e2d7ecdd0e776cbcf5f5cb4d70f0f4d52f