mirror of
https://github.com/yann64/haikuports.git
synced 2026-04-08 21:00:05 +02:00
104 lines
2.6 KiB
Bash
104 lines
2.6 KiB
Bash
SUMMARY="Qt6 shader tools module"
|
|
DESCRIPTION="The Qt Shader Tools module builds on the SPIR-V Open Source Ecosystem as described \
|
|
at the Khronos SPIR-V web site. For compiling into SPIR-V glslang is used, while translating \
|
|
and reflecting is done via SPIRV-Cross."
|
|
HOMEPAGE="https://qt.io/"
|
|
COPYRIGHT="2015-2025 The Qt Company Ltd."
|
|
LICENSE="GNU LGPL v2.1
|
|
GNU LGPL v3
|
|
GNU FDL v1"
|
|
REVISION="1"
|
|
QT_MIRROR_URI="https://qt-mirror.dannhauer.de/archive"
|
|
SOURCE_URI="$QT_MIRROR_URI/qt/${portVersion%.*}/$portVersion/submodules/qtshadertools-everywhere-src-$portVersion.tar.xz"
|
|
CHECKSUM_SHA256="916c40281ac3dee23b163f6ca73fb5bdeee344838b9a922b6f36269642d6f4bb"
|
|
SOURCE_DIR="qtshadertools-everywhere-src-$portVersion"
|
|
|
|
ARCHITECTURES="?all !x86_gcc2"
|
|
SECONDARY_ARCHITECTURES="?x86"
|
|
|
|
PROVIDES="
|
|
qt6_shadertools$secondaryArchSuffix = $portVersion compat >= 6
|
|
lib:libQt6ShaderTools$secondaryArchSuffix = $portVersion compat >= 6
|
|
cmd:qsb$secondaryArchSuffix = $portVersion compat >= 6
|
|
"
|
|
REQUIRES="
|
|
haiku$secondaryArchSuffix
|
|
lib:libGL$secondaryArchSuffix
|
|
lib:libQt6Core$secondaryArchSuffix
|
|
lib:libQt6Gui$secondaryArchSuffix
|
|
"
|
|
|
|
PROVIDES_devel="
|
|
qt6_shadertools${secondaryArchSuffix}_devel = $portVersion compat >= 6
|
|
devel:libQt6ShaderTools$secondaryArchSuffix = $portVersion compat >= 6
|
|
"
|
|
REQUIRES_devel="
|
|
qt6_shadertools$secondaryArchSuffix == $portVersion base
|
|
qt6_base${secondaryArchSuffix}_devel
|
|
"
|
|
|
|
BUILD_REQUIRES="
|
|
haiku${secondaryArchSuffix}_devel
|
|
devel:libQt6Core$secondaryArchSuffix == $portVersion
|
|
devel:libQt6Gui$secondaryArchSuffix == $portVersion
|
|
"
|
|
BUILD_PREREQUIRES="
|
|
cmd:awk
|
|
cmd:cmake
|
|
cmd:find
|
|
cmd:g++$secondaryArchSuffix
|
|
cmd:ld$secondaryArchSuffix
|
|
cmd:make
|
|
cmd:ninja
|
|
cmd:perl
|
|
cmd:pkg_config$secondaryArchSuffix
|
|
cmd:python3
|
|
cmd:sed
|
|
cmd:xargs
|
|
"
|
|
|
|
BUILD()
|
|
{
|
|
export DISABLE_ASLR=1
|
|
|
|
cmake -Bbuild -S. -G Ninja \
|
|
-DCMAKE_BUILD_TYPE=Release \
|
|
-DCMAKE_CXX_FLAGS=-fPIC \
|
|
-DQT_GENERATE_SBOM=ON \
|
|
-Wno-dev
|
|
|
|
find -name cmake_install.cmake -exec sed -i "s|set(CMAKE_INSTALL_PREFIX.*|set(CMAKE_INSTALL_PREFIX \"$prefix\")|" {} \;
|
|
|
|
ninja -v -C build $jobArgs
|
|
}
|
|
|
|
INSTALL()
|
|
{
|
|
# needs work, finds the library but tries to install to /boot/system
|
|
# sed -i "s|$ENV{DESTDIR}/boot/system|{DESTDIR}$prefix|" \
|
|
# build/qt_sbom/*.cmake
|
|
|
|
ninja -C build install
|
|
|
|
prepareInstalledDevelLib \
|
|
libQt6ShaderTools
|
|
|
|
# fix pkgconfig files
|
|
fixPkgconfig
|
|
sed -i "s|includedir=.*|includedir=$includeDir/Qt6|" \
|
|
$developLibDir/pkgconfig/*.pc
|
|
|
|
mkdir -p $binDir
|
|
ln -s -t $binDir $libDir/Qt6/qsb
|
|
|
|
cd $libDir
|
|
for i in lib*.so.6.*;do
|
|
ln -fs $i $(echo $i | cut -f1,2 -d.)
|
|
done
|
|
|
|
packageEntries devel \
|
|
$developDir \
|
|
$libDir/cmake \
|
|
$dataDir/Qt6/mkspecs
|
|
}
|