Andrew Geissler | 517393d | 2023-01-13 08:55:19 -0600 | [diff] [blame] | 1 | SUMMARY = "The SPIR-V Tools project provides an API and commands for \ |
| 2 | processing SPIR-V modules" |
| 3 | DESCRIPTION = "The project includes an assembler, binary module parser, \ |
| 4 | disassembler, validator, and optimizer for SPIR-V." |
| 5 | HOMEPAGE = "https://github.com/KhronosGroup/SPIRV-Tools" |
| 6 | SECTION = "graphics" |
| 7 | LICENSE = "Apache-2.0" |
| 8 | LIC_FILES_CHKSUM = "file://LICENSE;md5=3b83ef96387f14655fc854ddc3c6bd57" |
| 9 | |
Patrick Williams | 520786c | 2023-06-25 16:20:36 -0500 | [diff] [blame^] | 10 | SRCREV = "e7c6084fd1d6d6f5ac393e842728d8be309688ca" |
Patrick Williams | 864cc43 | 2023-02-09 14:54:44 -0600 | [diff] [blame] | 11 | SRC_URI = "git://github.com/KhronosGroup/SPIRV-Tools.git;branch=main;protocol=https" |
Andrew Geissler | 517393d | 2023-01-13 08:55:19 -0600 | [diff] [blame] | 12 | PE = "1" |
Andrew Geissler | 028142b | 2023-05-05 11:29:21 -0500 | [diff] [blame] | 13 | # These recipes need to be updated in lockstep with each other: |
| 14 | # glslang, vulkan-headers, vulkan-loader, vulkan-tools, spirv-headers, spirv-tools |
| 15 | # The tags versions should always be sdk-x.y.z, as this is what |
| 16 | # upstream considers a release. |
Andrew Geissler | 517393d | 2023-01-13 08:55:19 -0600 | [diff] [blame] | 17 | UPSTREAM_CHECK_GITTAGREGEX = "sdk-(?P<pver>\d+(\.\d+)+)" |
| 18 | S = "${WORKDIR}/git" |
| 19 | |
Andrew Geissler | 028142b | 2023-05-05 11:29:21 -0500 | [diff] [blame] | 20 | inherit cmake |
Andrew Geissler | 517393d | 2023-01-13 08:55:19 -0600 | [diff] [blame] | 21 | |
| 22 | DEPENDS = "spirv-headers" |
| 23 | |
| 24 | EXTRA_OECMAKE += "\ |
| 25 | -DSPIRV-Headers_SOURCE_DIR=${STAGING_EXECPREFIXDIR} \ |
| 26 | -DSPIRV_TOOLS_BUILD_STATIC=OFF \ |
| 27 | -DBUILD_SHARED_LIBS=ON \ |
| 28 | -DSPIRV_SKIP_TESTS=ON \ |
| 29 | " |
| 30 | |
| 31 | do_install:append:class-target() { |
| 32 | # Properly set _IMPORT_PREFIX in INTERFACE_LINK_LIBRARIES so that dependent |
| 33 | # tools can find the right library |
| 34 | sed -i ${D}${libdir}/cmake/SPIRV-Tools/SPIRV-ToolsTarget.cmake \ |
Patrick Williams | 520786c | 2023-06-25 16:20:36 -0500 | [diff] [blame^] | 35 | -e 's:INTERFACE_LINK_LIBRARIES.*$:INTERFACE_LINK_LIBRARIES "\$\{_IMPORT_PREFIX\}/${baselib}":' |
Andrew Geissler | 517393d | 2023-01-13 08:55:19 -0600 | [diff] [blame] | 36 | } |
| 37 | |
| 38 | # all the libraries are unversioned, so don't pack it on PN-dev |
| 39 | SOLIBS = ".so" |
| 40 | FILES_SOLIBSDEV = "" |
| 41 | |
| 42 | PACKAGES =+ "${PN}-lesspipe" |
| 43 | FILES:${PN}-lesspipe = "${base_bindir}/spirv-lesspipe.sh" |
| 44 | RDEPENDS:${PN}-lesspipe += "${PN} bash" |
| 45 | |
| 46 | BBCLASSEXTEND = "native nativesdk" |