SUMMARY="A cross-platform application and UI framework (Development Tools, QtHelp)" DESCRIPTION="The QtTools modules contains some tools mostly useful for application \ development. Included are Qt Designer (GUI design), QDbusViewer and more." HOMEPAGE="https://qt.io/" COPYRIGHT="2015-2026 The Qt Company Ltd." LICENSE="GNU LGPL v2.1 GNU LGPL v3 GNU FDL v1" REVISION="1" QT_MIRROR_URI="https://download.qt.io/official_releases" SOURCE_URI="$QT_MIRROR_URI/qt/${portVersion%.*}/$portVersion/submodules/qttools-everywhere-src-$portVersion.tar.xz" CHECKSUM_SHA256="8f00b9e3d1f80973d81cff67684972b89993183ef19924404d5b8ff0f89675b6" SOURCE_DIR="qttools-everywhere-src-$portVersion" ADDITIONAL_FILES=" Assistant.rdef.in Designer.rdef.in Linguist.rdef.in QDBusViewer.rdef.in FindWrapLibClang.cmake.in " ARCHITECTURES="all !x86_gcc2" SECONDARY_ARCHITECTURES="x86" libVersion="$portVersion" libVersionCompat="$libVersion compat >= ${libVersion%%.*}" clangVer="21" PROVIDES=" qt6_tools$secondaryArchSuffix = $portVersion compat >= 6 cmd:assistant6$secondaryArchSuffix = $portVersion compat >= 6 cmd:designer6$secondaryArchSuffix = $portVersion compat >= 6 cmd:linguist6$secondaryArchSuffix = $portVersion compat >= 6 cmd:pixeltool6$secondaryArchSuffix = $portVersion compat >= 6 cmd:qdbus6$secondaryArchSuffix = $portVersion compat >= 6 cmd:qdbusviewer6$secondaryArchSuffix = $portVersion compat >= 6 cmd:qdistancefieldgenerator6$secondaryArchSuffix = $portVersion compat >= 6 cmd:qdoc6$secondaryArchSuffix = $portVersion compat >= 6 cmd:qtdiag6$secondaryArchSuffix = $portVersion compat >= 6 cmd:qtplugininfo6$secondaryArchSuffix = $portVersion compat >= 6 lib:libQt6Designer$secondaryArchSuffix = $libVersionCompat lib:libQt6DesignerComponents$secondaryArchSuffix = $libVersionCompat lib:libQt6Help$secondaryArchSuffix = $libVersionCompat lib:libQt6UiTools$secondaryArchSuffix = $libVersionCompat " REQUIRES=" haiku$secondaryArchSuffix lib:libclang$secondaryArchSuffix lib:libcrypto$secondaryArchSuffix lib:libLLVM$secondaryArchSuffix lib:libGL$secondaryArchSuffix lib:libQt6Core$secondaryArchSuffix lib:libQt6Gui$secondaryArchSuffix lib:libQt6Qml$secondaryArchSuffix lib:libQt6QmlModels$secondaryArchSuffix lib:libQt6Quick$secondaryArchSuffix lib:libQt6Widgets$secondaryArchSuffix lib:libvulkan$secondaryArchSuffix lib:libz$secondaryArchSuffix lib:libzstd$secondaryArchSuffix " PROVIDES_devel=" qt6_tools${secondaryArchSuffix}_devel = $portVersion compat >= 6 devel:libQt6Designer$secondaryArchSuffix = $libVersionCompat devel:libQt6DesignerComponents$secondaryArchSuffix = $libVersionCompat devel:libQt6Help$secondaryArchSuffix = $libVersionCompat devel:libQt6UiTools$secondaryArchSuffix = $libVersionCompat " REQUIRES_devel=" qt6_tools$secondaryArchSuffix == $portVersion base haiku${secondaryArchSuffix}_devel " BUILD_REQUIRES=" haiku${secondaryArchSuffix}_devel devel:libclang$secondaryArchSuffix >= $clangVer devel:libclang_cpp$secondaryArchSuffix >= $clangVer devel:libcrypto$secondaryArchSuffix devel:libLLVM_$clangVer$secondaryArchSuffix devel:libQt6Core$secondaryArchSuffix == $portVersion devel:libQt6Gui$secondaryArchSuffix == $portVersion devel:libQt6JsonRpc$secondaryArchSuffix devel:libQt6LanguageServer$secondaryArchSuffix devel:libQt6Qml$secondaryArchSuffix == $portVersion devel:libQt6QmlModels$secondaryArchSuffix == $portVersion devel:libQt6Quick$secondaryArchSuffix == $portVersion devel:libQt6Widgets$secondaryArchSuffix == $portVersion devel:libssl$secondaryArchSuffix devel:libvulkan$secondaryArchSuffix devel:libz$secondaryArchSuffix devel:libzstd$secondaryArchSuffix " BUILD_PREREQUIRES=" cmd:awk cmd:cmake cmd:find cmd:g++$secondaryArchSuffix cmd:ld$secondaryArchSuffix cmd:ninja cmd:perl cmd:pkg_config$secondaryArchSuffix cmd:python3 cmd:sed cmd:xargs " BUILD() { export DISABLE_ASLR=1 local LLVM_VERSION=$(llvm-config --version) local LLVM_VERION_MAJOR="`echo "$LLVM_VERSION" | cut -d. -f1`" local LLVM_VERION_MINOR="`echo "$LLVM_VERSION" | cut -d. -f2`" local LLVM_VERION_PATCH="`echo "$LLVM_VERSION" | cut -d. -f3`" sed \ -e "s|@CLANG_VERSION_MAJOR@|$LLVM_VERION_MAJOR|" \ -e "s|@CLANG_VERSION_MINOR@|$LLVM_VERION_MINOR|" \ -e "s|@CLANG_VERSION_PATCH@|$LLVM_VERION_PATCH|" \ -e "s|@CLANG_VERSION@|$LLVM_VERSION|" \ -e "s|@CLANG_LIBDIR@|/system/$relativeDevelopLibDir|" \ -e "s|@CLANG_INCLUDE_DIR@|/system/$relativeLibDir/clang/$LLVM_VERSION/include|" \ $portDir/additional-files/FindWrapLibClang.cmake.in > $sourceDir/cmake/FindWrapLibClang.cmake cmake -B build -S $sourceDir -G Ninja \ -DCMAKE_BUILD_TYPE=Release \ -DCMAKE_CXX_FLAGS=-fPIC \ -DINSTALL_PUBLICBINDIR=$binDir \ -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() { ninja -C build install prepareInstalledDevelLibs \ libQt6Designer \ libQt6DesignerComponents \ libQt6Help \ libQt6UiTools # fix pkgconfig files fixPkgconfig sed -i "s|includedir=.*|includedir=$includeDir/Qt6|" \ $developLibDir/pkgconfig/*.pc # add tools to Deskbar menu mkdir -p \ $binDir \ $dataDir/deskbar/menu/Applications/Qt # install symlinks for user-facing tools binFiles="linguist designer pixeltool assistant qdistancefieldgenerator qtplugininfo \ qdoc qdbus qdbusviewer qtdiag" suffix="6" for f in $binFiles; do ln -s $libDir/Qt6/$f $binDir/$f$suffix done # add resources local MAJOR="`echo "$portVersion" | cut -d. -f1`" local MIDDLE="`echo "$portVersion" | cut -d. -f2`" local MINOR="`echo "$portVersion" | cut -d. -f3`" local VARIETY="B_APPV_FINAL" resFiles="Assistant Designer Linguist QDBusViewer" for j in $resFiles; do sed \ -e "s|@MAJOR@|$MAJOR|" \ -e "s|@MIDDLE@|$MIDDLE|" \ -e "s|@MINOR@|$MINOR|" \ -e "s|@VARIETY@|$VARIETY|" \ $portDir/additional-files/$j.rdef.in > $sourceDir/$j.rdef mv $libDir/Qt6/${j,,} $libDir/Qt6/$j ln -s $libDir/Qt6/$j $libDir/Qt6/${j,,} addResourcesToBinaries $sourceDir/$j.rdef $libDir/Qt6/$j addAppDeskbarSymlink $libDir/Qt6/$j "Qt/Qt6 $j" mimeset -f $libDir/Qt6/$j done mkdir -p $libDir/Qt6/lib cp -f `finddir B_SYSTEM_DIRECTORY`/$relativeDevelopLibDir/libclang.so.$clangVer.1 $libDir/Qt6/lib cp -f `finddir B_SYSTEM_DIRECTORY`/$relativeDevelopLibDir/libclang-cpp.so.$clangVer.1 $libDir/Qt6/lib strip -s $libDir/Qt6/lib/libclang* 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 }