Hi, ptxdist respects the 'select' statements in Kconfig, so you should be able to make ptxdist build libsepol before libselinux by adding a "select LIBSEPOL" to your "config LIBSELINUX" entry in rules/libselinux.in. You can look at many other packages as an example, or at this section [1] in the docs. But make sure that the 'select' is directly in the "config LIBSELINUX" option and not in a sub-option, otherwise the dependency parser will not find it.
[1]: https://www.ptxdist.org/doc/dev_manual.html#managing-external-compile-time-dependencies Hope that solves your problem? - Roland On Tue, Mar 12, 2019 at 06:56:24PM +0800, Chin You Wen (WMSC-HW) wrote: > Hello, > > I am compiling the SELINUX userspace tools ( > https://github.com/SELinuxProject/selinux) and I encountered this error. > > load_policy.c:15:25: fatal error: sepol/sepol.h: No such file or directory > compilation terminated. > > The sub-package libselinux depends on libsepol, but by default the PTXDist > rule file does not run makefile sections in sequential order, i.e. it > executes the compile section for all sub-packages first, followed by > install section. This results in the required libsepol dependencies to not > be found when libselinux needs it, and thus the above error. > > Is there any way to accomplish this without splitting the sub-packages into > separate rule files? I am thinking of calling something like this: > > @$(call compile, libsepol) > @$(call install, libsepol) > @$(call compile, libselinux) > @$(call install, libselinux) > > but I am unsure if that is possible, or what the correct syntax is. Kindly > advise. Thanks. > > > Regards, > You Wen > _______________________________________________ > ptxdist mailing list > [email protected] -- Roland Hieber | [email protected] | Pengutronix e.K. | https://www.pengutronix.de/ | Peiner Str. 6-8, 31137 Hildesheim | Phone: +49-5121-206917-5086 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 | _______________________________________________ ptxdist mailing list [email protected]
