# Template file for 'amdvlk' pkgname=amdvlk version=2024.Q2.2 revision=1 _xgl_commit=3abea9dfab5ae515f76a429945ed94196285fc08 _pal_commit=2076667db1fa57f03d1624d1c59c3d024afb42f6 _llpc_commit=6c770c7d276d2c2504aed2a0278aab1610993ecf _gpurt_commit=c0196c83e76ca4a6dfefae33ddcf97b761429e38 _llvm_project_commit=c3793ad7bf21ce66a13f72178270cd19fa4311de _MetroHash_commit=18893fb28601bb9af1154cd1a671a121fff6d8d3 _CWPack_commit=4f8cf0584442a91d829d269158567d7ed926f026 _llvm_dialects_commit=55e176fb88bcfc4fae45bafaa3ff209ec4c0d4ee archs="i686* x86_64*" create_wrksrc=yes build_wrksrc="xgl" build_style=cmake configure_args="-DBUILD_WAYLAND_SUPPORT=ON -DCMAKE_BUILD_TYPE=Release -DLLVM_PARALLEL_LINK_JOBS=2" hostmakedepends="pkg-config python3 perl" makedepends="libxml2-devel xorg-server-devel libXrandr-devel libffi-devel wayland-devel DirectXShaderCompiler-devel glslang-devel python3-Jinja2 python3-ruamel.yaml" depends="vulkan-loader" short_desc="AMD Open Source Driver For Vulkan" maintainer="John " license="MIT" homepage="https://github.com/GPUOpen-Drivers/AMDVLK" distfiles="https://github.com/GPUOpen-Drivers/AMDVLK/archive/v-${version}.tar.gz https://github.com/GPUOpen-Drivers/llpc/archive/${_llpc_commit}.tar.gz https://github.com/GPUOpen-Drivers/gpurt/archive/${_gpurt_commit}.tar.gz https://github.com/GPUOpen-Drivers/xgl/archive/${_xgl_commit}.tar.gz https://github.com/GPUOpen-Drivers/pal/archive/${_pal_commit}.tar.gz https://github.com/GPUOpen-Drivers/llvm-project/archive/${_llvm_project_commit}.tar.gz https://github.com/GPUOpen-Drivers/MetroHash/archive/${_MetroHash_commit}.tar.gz https://github.com/GPUOpen-Drivers/CWPack/archive/${_CWPack_commit}.tar.gz https://github.com/GPUOpen-Drivers/llvm-dialects/archive/${_llvm_dialects_commit}.tar.gz" checksum="d8bf5e3367289b6322a53f0775a99a1565f94003e33c1867e8639c4de5619758 e2d6c8e74c474556380265d3403351979dc57c2a5924280f3106dc397d11c541 15f15f1ea9e1a532b95bb695a9f07ed9880ab80708aff857bbaf634753cc97a2 ba47639920b705c141a6415f70375f00ec0c19d8f963c11d681689be52000b6b 698f62f8eb9014e00879a95b85588231368a36d59bb6dacff1f391566659f524 f7383666f1098d120ef8f30539357eabb97bcf434419adbcd553778590e6d25f 141e6c156a834b8e0f90ba108664d7f35193df11acddefa117f394dbf2b7371a 87ed9209c129f47d0b64c914fb99d6c69e59a257445ec3a394c3e00d5e2b4484 996b27e2b9b1d40d038a8c8b741a398ae1dab06e5ef24d48b2f9d006871b9a2d" nocross=yes lib32files="/usr/share/vulkan/icd.d/amd_icd32.json" case "$XBPS_TARGET_MACHINE" in i686*) nodebug=yes;; esac post_extract() { mv ${wrksrc}/AMDVLK-v-${version} ${wrksrc}/AMDVLK mv ${wrksrc}/xgl-${_xgl_commit} ${wrksrc}/xgl mv ${wrksrc}/pal-${_pal_commit} ${wrksrc}/pal mv ${wrksrc}/llpc-${_llpc_commit} ${wrksrc}/llpc mv ${wrksrc}/gpurt-${_gpurt_commit} ${wrksrc}/gpurt mv ${wrksrc}/llvm-project-${_llvm_project_commit} ${wrksrc}/llvm-project mkdir ${wrksrc}/third_party mv ${wrksrc}/MetroHash-${_MetroHash_commit} ${wrksrc}/third_party/metrohash mv ${wrksrc}/CWPack-${_CWPack_commit} ${wrksrc}/third_party/cwpack rmdir ${wrksrc}/llpc/imported/llvm-dialects/ mv ${wrksrc}/llvm-dialects-${_llvm_dialects_commit}/ ${wrksrc}/llpc/imported/llvm-dialects/ } pre_configure() { case "$XBPS_TARGET_MACHINE" in i686*) _arch="X86";; x86_64*) _arch="X86";; esac configure_args+=" -DLLVM_TARGET_ARCH=${_arch}" configure_args+=" -DLLVM_DEFAULT_TARGET_TRIPLE=${XBPS_CROSS_TRIPLET:-$XBPS_TRIPLET}" } do_install() { vinstall build/icd/amdvlk${XBPS_TARGET_WORDSIZE}.so 644 usr/lib/ vinstall build/icd/amd_icd${XBPS_TARGET_WORDSIZE}.json \ 644 usr/share/vulkan/icd.d/ vlicense ${wrksrc}/AMDVLK/LICENSE.txt }