[Buildroot] [PATCH v2 4/4] cdrkit: convert to CMAKETARGETS infrastructure

Bjørn Forsman bjorn.forsman at gmail.com
Wed Jan 26 09:56:02 UTC 2011


On 26 January 2011 09:43, Thomas Petazzoni
<thomas.petazzoni at free-electrons.com> wrote:
> Hello Bjorn,
>
> On Sat, 15 Jan 2011 21:53:28 +0100
> Bjørn Forsman <bjorn.forsman at gmail.com> wrote:
>
>> +## cdrkit isn't completely re-rooted by CMAKE_FIND_ROOT_PATH, so add
>> +## some extra flags so it finds needed libs and headers.
>> +CDRKIT_CONF_OPT += -DCMAKE_REQUIRED_INCLUDES="$(STAGING_DIR)/usr/include"
>> +CDRKIT_CONF_OPT += -DCMAKE_EXE_LINKER_FLAGS="$(TARGET_LDFLAGS)"
>> +HOST_CDRKIT_CONF_OPT += -DCMAKE_REQUIRED_INCLUDES="$(HOST_DIR)/usr/include"
>> +HOST_CDRKIT_CONF_OPT += -DCMAKE_EXE_LINKER_FLAGS="$(HOST_LDFLAGS)"
>
> This does not seem to be sufficient: I don't have <sys/capability.h>
> installed system-wide, but it is present in $(HOST_DIR)/usr/include,
> but still host-cdrkit doesn't build:
>
> /home/thomas/local/outputs/cmake/build/host-cdrkit-1.1.10/wodim/wodim.c:78:56: error: sys/capability.h: No such file or directory

Ah, I see. CMAKE_REQUIRED_INCLUDES is only used by CHECK_INCLUDE_FILES
(the macro that initially finds sys/capability.h):

-- Looking for include files HAVE_SYS_CAPABILITY_H
-- Looking for include files HAVE_SYS_CAPABILITY_H - found

But CMAKE_REQUIRED_INCLUDES is clearly not used during the build. I
guess I misinterpreted the docs. (Hm... I wonder what purpose
CMAKE_REQUIRED_INCLUDES has then...) I'll replace it with
CMAKE_C_FLAGS. And I'll remove sys/capability.h from my system so I
can spot these things :-)

Thanks for the report.

Best regards,
Bjørn Forsman



More information about the buildroot mailing list