Thank you for the response. I've sort of generated a port for a part of the boost libraries. It builds the src/lib/boost in the contrib folder, the dummy application links the library also. (How do I run applications built on linux_x86 platform?) The boost libraries are mainly .hpp files. By dependencies, I meant, header files #including other header files.
For instance: for simplicity, if I set DIRS_CONTENT(include/regex) := src/lib/boost/boost/regex/regex.hpp. But the actual header file simply has more includes to header files in the same directory, does the build system recognise this?
Cheers
AdityaOn May 4, 2015 22:56, "Josef Söntgen" <josef.soentgen@...1...> wrote:Hello Aditya,
* Aditya Kousik <adit267.kousik@...9...> [2015-05-04 20:15:16 -0700]:
> If I get the order of the .port and libports/lib/mk/<port-name>.mk right,
> DIRS and DIRS_CONTENT are the generated/copied headers during the build;
> and INC_DIR in the .mk file configures make to look at the current folder
> for local includes.
Yes, directories in DIRS get populated from the content in DIRS_CONTENT
while preparing the port. Basically, the populated include directory
should only contain the files that are needed on Genode. The same goes
for the src directory, although we do not do that for most small
libraries/applications but only for larger ones (VirtualBox, Linux
sources etc).
> I'm asking this because if the include files that appear in
> contrib-<hash>/src/lib/include have multiple dependencies, the build will
> still work, right? I'm guessing the headers in the DIRS are just for the
> genode application to include and the build system takes the actual src
> while compiling.
Actually, these header files are also used by the library/application
itself. If the libraries depend on other libraries you only have
to add the library to the LIBS variable in the .mk file and the build
system will try to pick up the matching import-<port-name>.mk file.
This in return will extend INC_DIR, that is used by the build system
to generate the right compiler flags.
On that account, the INC_DIR variable in the import file should only
contain the public header paths used by other libraries/applications.
In the lib/target.mk file it is fine to point the build system and
thereby the compiler to other directories in addition, e.g.
$(REP_DIR)/src/lib/<port-name> or even contrib-<hash>/src. In this
regard, the SDL port is a good example.
Regards
Josef
------------------------------------------------------------------------------
One dashboard for servers and applications across Physical-Virtual-Cloud
Widest out-of-the-box monitoring support with 50+ applications
Performance metrics, stats and reports that give you Actionable Insights
Deep dive visibility with transaction tracing using APM Insight.
http://ad.doubleclick.net/ddm/clk/290420510;117567292;y
_______________________________________________
genode-main mailing list
genode-main@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/genode-main