Now that intel-skylake-64 can use qemu-user as well, don't build native version of the recipe simply for use by the target version. Build a qemuwrapper that can be passed to CMAKE_CROSSCOMPILING_EMULATOR.
Signed-off-by: Anuj Mittal <[email protected]> --- .../intel-graphics-compiler_1.0.13822.6.bb | 23 +++++++++---------- 1 file changed, 11 insertions(+), 12 deletions(-) diff --git a/dynamic-layers/clang-layer/recipes-opencl/igc/intel-graphics-compiler_1.0.13822.6.bb b/dynamic-layers/clang-layer/recipes-opencl/igc/intel-graphics-compiler_1.0.13822.6.bb index a8039b9b..69bdac56 100644 --- a/dynamic-layers/clang-layer/recipes-opencl/igc/intel-graphics-compiler_1.0.13822.6.bb +++ b/dynamic-layers/clang-layer/recipes-opencl/igc/intel-graphics-compiler_1.0.13822.6.bb @@ -31,15 +31,14 @@ export B S = "${WORKDIR}/git" -inherit cmake pkgconfig +inherit cmake pkgconfig qemu CXXFLAGS:append = " -Wno-error=nonnull" COMPATIBLE_HOST = '(x86_64).*-linux' COMPATIBLE_HOST:libc-musl = "null" -DEPENDS += " flex-native bison-native clang opencl-clang" -DEPENDS:append:class-target = " clang-cross-x86_64 intel-graphics-compiler-native" +DEPENDS += " flex-native bison-native clang clang-cross-x86_64 opencl-clang qemu-native" RDEPENDS:${PN} += "opencl-clang" @@ -54,19 +53,19 @@ EXTRA_OECMAKE = " \ -DLLVM_TABLEGEN=${STAGING_BINDIR_NATIVE}/llvm-tblgen \ -DLLVM_LINK_EXE=${STAGING_BINDIR_NATIVE}/llvm-link \ -DCLANG_EXE=${STAGING_BINDIR_NATIVE}/clang \ + -DCMAKE_CROSSCOMPILING_EMULATOR=${WORKDIR}/qemuwrapper \ " -do_install:append:class-native () { - install -d ${D}${bindir} - install ${B}/IGC/Release/elf_packager ${D}${bindir}/ - if ${@bb.utils.contains('PACKAGECONFIG', 'vc', 'true', 'false', d)}; then - install ${B}/IGC/Release/CMCLTranslatorTool ${D}${bindir}/ - install ${B}/IGC/Release/vcb ${D}${bindir}/ - fi +do_configure:prepend:class-target () { + # Write out a qemu wrapper that will be used by cmake. + qemu_binary="${@qemu_wrapper_cmdline(d, d.getVar('STAGING_DIR_HOST'), [d.expand('${STAGING_DIR_HOST}${libdir}'),d.expand('${STAGING_DIR_HOST}${base_libdir}')])}" + cat > ${WORKDIR}/qemuwrapper << EOF +#!/bin/sh +$qemu_binary "\$@" +EOF + chmod +x ${WORKDIR}/qemuwrapper } -BBCLASSEXTEND = "native nativesdk" - UPSTREAM_CHECK_GITTAGREGEX = "^igc-(?P<pver>(?!19\..*)\d+(\.\d+)+)$" FILES:${PN} += " \ -- 2.41.0
-=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#8039): https://lists.yoctoproject.org/g/meta-intel/message/8039 Mute This Topic: https://lists.yoctoproject.org/mt/100000368/21656 Group Owner: [email protected] Unsubscribe: https://lists.yoctoproject.org/g/meta-intel/leave/6694807/21656/1869269227/xyzzy [[email protected]] -=-=-=-=-=-=-=-=-=-=-=-
