Am 10.06.2013 16:09, schrieb Manuel Nickschas:
On Friday 24 May 2013 16:56:41 Stefan Herbrechtsmeier wrote:
Am 24.05.2013 15:03, schrieb Manuel Nickschas:
The path specified there is clearly wrong for cross-compiling, because it
references the location in the target itself, without prepending the
sysroot prefix. Thus, it won't find moc. In particular, it needs not even
find the moc from the target sysroot, but from the native sysroot, as
it's a host tool.
All paths in the target sysroot represents the path on the target. They
should be
adapted via an variable or automatically detected during runtime.
What would be the proper way of doing this in the CMake files shipped by
Qt5?

/usr/bin/qt5/moc is hard-coded. We could prepend that with
${STAGING_DIR_NATIVE} maybe, which could be exported (via
EXTRA_OECMAKE) by recipes so it's picked up by CMake, and it would
resolve to nothing if it's not set (so the CMake file would still work outside 
of
Bitbake).
You can try to import the executable from a file passed via -P parameter to cmake. I'm not sure if this works.

add_executable(Qt5::rcc IMPORTED)
set_target_properties(Qt5::rcc PROPERTIES IMPORTED_LOCATION "${STAGING_BINDIR_NATIVE}/rcc4")

Regards,
  Stefan

_______________________________________________
Openembedded-devel mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-devel

Reply via email to