51 lines
2.0 KiB
Plaintext
51 lines
2.0 KiB
Plaintext
# Description: A cross-platform application and UI framework
|
|
# URL: https://www.qt.io/
|
|
# Maintainer: Danny Rawlins, crux at romster dot me
|
|
# Depends on: brotli cups double-conversion gst-plugins-base libb2 libinput libxkbcommon shared-mime-info vulkan-headers xorg-libxi xorg-xcb-util-cursor xorg-xcb-util-keysyms xorg-xcb-util-wm
|
|
# Optional: gtk3 mariadb postgresql unixodbc pulseaudio pipewire md4c tslib xmlstarlet xdg-utils libproxy
|
|
|
|
name=qt6-base
|
|
version=6.2.2
|
|
release=1
|
|
source=(https://download.qt.io/official_releases/qt/${version%.*}/$version/submodules/qtbase-everywhere-src-$version.tar.xz
|
|
qt6-base-cflags.patch qt6-base-nostrip.patch)
|
|
|
|
build() {
|
|
patch -d qtbase-everywhere-src-$version -p1 -i $SRC/qt6-base-cflags.patch
|
|
patch -d qtbase-everywhere-src-$version -p1 -i $SRC/qt6-base-nostrip.patch
|
|
|
|
prt-get isinst ninja && PKGMK_QT6+=' -G Ninja'
|
|
prt-get isinst ccache && PKGMK_QT6+=' -D QT_USE_CCACHE=ON' && PATH="$(echo ${PATH} | awk -v RS=: -v ORS=: '/ccache/ {next} {print}' | sed 's/:*$//')"
|
|
|
|
cmake -S qtbase-everywhere-src-$version -B build $PKGMK_QT6 \
|
|
-D CMAKE_INSTALL_PREFIX=/usr \
|
|
-D INSTALL_BINDIR=lib/qt6/bin \
|
|
-D INSTALL_PUBLICBINDIR=usr/bin \
|
|
-D INSTALL_LIBEXECDIR=lib/qt6 \
|
|
-D INSTALL_DOCDIR=share/doc/qt6 \
|
|
-D INSTALL_ARCHDATADIR=lib/qt6 \
|
|
-D INSTALL_DATADIR=share/qt6 \
|
|
-D INSTALL_INCLUDEDIR=include/qt6 \
|
|
-D INSTALL_MKSPECSDIR=lib/qt6/mkspecs \
|
|
-D INSTALL_EXAMPLESDIR=share/doc/qt6/examples \
|
|
-D CMAKE_BUILD_TYPE=Release \
|
|
-D CMAKE_CXX_FLAGS_RELEASE="$CXXFLAGS" \
|
|
-D CMAKE_C_FLAGS_RELEASE="$CFLAGS" \
|
|
-D QT_DISABLE_RPATH=TRUE \
|
|
-D QT_FEATURE_openssl_linked=ON \
|
|
-D QT_FEATURE_system_sqlite=ON \
|
|
-Wno-dev
|
|
|
|
cmake --build build
|
|
DESTDIR=$PKG cmake --install build
|
|
|
|
rm -r $PKG/usr/share/doc
|
|
|
|
# Install useful symlinks
|
|
install -d $PKG/usr/bin
|
|
for file in $PKG/usr/lib/qt6/bin/*; do
|
|
ln -s ../lib/qt6/bin/$(basename $file) $PKG/usr/bin/$(basename $file)-qt6
|
|
#ln -s ../lib/qt6/bin/$(basename $file) $PKG/usr/bin/$(basename $file)
|
|
done
|
|
}
|