# Template file for 'amdvlk' pkgname=amdvlk version=2022.Q4.4 revision=1 _xgl_commit=8aa0e76a110fa264608ee1b4e412aa8fb40286d3 _pal_commit=287ef684bc36a86af55d4ed1c4c4f4c35577e21e _llpc_commit=37dcb2e5cedb00bb025c84238d816f19c93b3060 _gpurt_commit=1f0c4f7e9cea22452e5e20a6cdfc4a84a2bf5bac _llvm_project_commit=42a4d92d3c68995d04f1ed580613d162054f5795 _MetroHash_commit=18893fb28601bb9af1154cd1a671a121fff6d8d3 _CWPack_commit=4f8cf0584442a91d829d269158567d7ed926f026 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" 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" checksum="19e1b4344b76aa52429f06bf083ba90070c2415bda90f0991dddebf846e84752 d3b465c84bdff774d2b2916121d7e9d6b31cb8467eb08fa8e1de9a5136dfe7be b992d8f4b4093793de87375a3f7b0ded71a1a2443c620fbc017776588861421d 9a2d41a49dd69a9634ab7aa30e750dfdc255c4f2e0c4c739028ac8a52c1bb5a6 11c31d5da5a846476825b2af2c67fd2025c892b6133b1b0a97c3548d691e5584 2b154a73681aa0424446b09737263fb35ae842fc92ee60fed999bad5fe15a7f9 141e6c156a834b8e0f90ba108664d7f35193df11acddefa117f394dbf2b7371a 87ed9209c129f47d0b64c914fb99d6c69e59a257445ec3a394c3e00d5e2b4484" nocross=yes lib32files="/usr/share/vulkan/icd.d/amd_icd32.json" case "$XBPS_TARGET_MACHINE" in i686*) nodebug=yes;; esac pre_build() { pwd ninja -C build GpuRtGenerateShaders } 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 } 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 }