diff options
Diffstat (limited to 'dynamic-layers/clang-layer/recipes-opencl/igc/intel-graphics-compiler_2.10.10.bb')
-rw-r--r-- | dynamic-layers/clang-layer/recipes-opencl/igc/intel-graphics-compiler_2.10.10.bb | 79 |
1 files changed, 79 insertions, 0 deletions
diff --git a/dynamic-layers/clang-layer/recipes-opencl/igc/intel-graphics-compiler_2.10.10.bb b/dynamic-layers/clang-layer/recipes-opencl/igc/intel-graphics-compiler_2.10.10.bb new file mode 100644 index 00000000..b6d8ddeb --- /dev/null +++ b/dynamic-layers/clang-layer/recipes-opencl/igc/intel-graphics-compiler_2.10.10.bb | |||
@@ -0,0 +1,79 @@ | |||
1 | SUMMARY = "The Intel(R) Graphics Compiler for OpenCL(TM)" | ||
2 | DESCRIPTION = "The Intel(R) Graphics Compiler for OpenCL(TM) is an \ | ||
3 | llvm based compiler for OpenCL(TM) targeting Intel Gen graphics \ | ||
4 | hardware architecture." | ||
5 | |||
6 | LICENSE = "MIT & Apache-2.0" | ||
7 | LIC_FILES_CHKSUM = "file://IGC/BiFModule/Implementation/ExternalLibraries/libclc/LICENSE.TXT;md5=311cfc1a5b54bab8ed34a0b5fba4373e \ | ||
8 | file://LICENSE.md;md5=488d74376edf2765f6e78d271543dde3 \ | ||
9 | file://NOTICES.txt;md5=b81a52411c84df3419f20bad4d755880" | ||
10 | |||
11 | SRC_URI = "git://github.com/intel/intel-graphics-compiler.git;protocol=https;name=igc;branch=releases/2.10.x \ | ||
12 | git://github.com/intel/vc-intrinsics.git;protocol=https;destsuffix=git/vc-intrinsics;name=vc;nobranch=1 \ | ||
13 | git://github.com/KhronosGroup/SPIRV-Tools.git;protocol=https;destsuffix=git/SPIRV-Tools;name=spirv-tools;branch=main \ | ||
14 | git://github.com/KhronosGroup/SPIRV-Headers.git;protocol=https;destsuffix=git/SPIRV-Headers;name=spirv-headers;branch=main \ | ||
15 | file://0003-Improve-Reproducibility-for-src-package.patch \ | ||
16 | file://0001-BiF-CMakeLists.txt-remove-opt-from-DEPENDS.patch \ | ||
17 | file://0001-external-SPIRV-Tools-change-path-to-tools-and-header.patch \ | ||
18 | file://0001-Build-not-able-to-locate-BiFManager-bin.patch \ | ||
19 | " | ||
20 | |||
21 | SRC_URI:append:class-native = " file://0001-fix-tblgen.patch" | ||
22 | |||
23 | SRCREV_igc = "83925314d4fc32b017fcbfcd73e0667ba833fb8f" | ||
24 | SRCREV_vc = "9d255266e1df8f1dc5d11e1fbb03213acfaa4fc7" | ||
25 | SRCREV_spirv-tools = "f289d047f49fb60488301ec62bafab85573668cc" | ||
26 | SRCREV_spirv-headers = "0e710677989b4326ac974fd80c5308191ed80965" | ||
27 | |||
28 | SRCREV_FORMAT = "igc_vc_spirv-tools_spirv-headers" | ||
29 | |||
30 | # Used to replace with relative path in reproducibility patch | ||
31 | export B | ||
32 | |||
33 | S = "${WORKDIR}/git" | ||
34 | |||
35 | inherit cmake pkgconfig qemu python3native | ||
36 | |||
37 | CXXFLAGS:append = " -Wno-error=nonnull" | ||
38 | |||
39 | COMPATIBLE_HOST = '(x86_64).*-linux' | ||
40 | COMPATIBLE_HOST:libc-musl = "null" | ||
41 | |||
42 | DEPENDS += " flex-native bison-native clang clang-cross-x86_64 opencl-clang qemu-native python3-mako-native \ | ||
43 | python3-pyyaml-native \ | ||
44 | " | ||
45 | |||
46 | RDEPENDS:${PN} += "opencl-clang" | ||
47 | |||
48 | PACKAGECONFIG ??= "vc" | ||
49 | PACKAGECONFIG[vc] = "-DIGC_BUILD__VC_ENABLED=ON -DIGC_OPTION__LINK_KHRONOS_SPIRV_TRANSLATOR=ON -DIGC_OPTION__SPIRV_TRANSLATOR_MODE=Prebuilds,-DIGC_BUILD__VC_ENABLED=OFF," | ||
50 | |||
51 | EXTRA_OECMAKE = " \ | ||
52 | -DIGC_OPTION__LLVM_PREFERRED_VERSION=${LLVMVERSION} \ | ||
53 | -DVC_INTRINSICS_SRC="${S}/vc-intrinsics" \ | ||
54 | -DIGC_OPTION__LLVM_MODE=Prebuilds \ | ||
55 | -DLLVM_TABLEGEN=${STAGING_BINDIR_NATIVE}/llvm-tblgen \ | ||
56 | -DLLVM_LINK_EXE=${STAGING_BINDIR_NATIVE}/llvm-link \ | ||
57 | -DCLANG_EXE=${STAGING_BINDIR_NATIVE}/clang \ | ||
58 | -DCMAKE_CROSSCOMPILING_EMULATOR=${WORKDIR}/qemuwrapper \ | ||
59 | " | ||
60 | |||
61 | do_configure:prepend:class-target () { | ||
62 | # Write out a qemu wrapper that will be used by cmake. | ||
63 | qemu_binary="${@qemu_wrapper_cmdline(d, d.getVar('STAGING_DIR_HOST'), [d.expand('${STAGING_DIR_HOST}${libdir}'),d.expand('${STAGING_DIR_HOST}${base_libdir}')])}" | ||
64 | cat > ${WORKDIR}/qemuwrapper << EOF | ||
65 | #!/bin/sh | ||
66 | $qemu_binary "\$@" | ||
67 | EOF | ||
68 | chmod +x ${WORKDIR}/qemuwrapper | ||
69 | } | ||
70 | |||
71 | |||
72 | UPSTREAM_CHECK_GITTAGREGEX = "^v(?P<pver>\d+(\.\d+)+)$" | ||
73 | |||
74 | FILES:${PN} += " \ | ||
75 | ${libdir}/igc2/NOTICES.txt \ | ||
76 | " | ||
77 | |||
78 | # libigc.so contains buildpaths | ||
79 | INSANE_SKIP:${PN} += "buildpaths" | ||