1166 lines
32 KiB
Bash
1166 lines
32 KiB
Bash
# Template file for 'qt5'
|
|
#
|
|
# revbump libqtxdg after bumping patch version
|
|
pkgname=qt5
|
|
version=5.15.7+20221119
|
|
# commit f8c9fb304bc3e53b3aa07f962cd74e9160decccc
|
|
# base repo: https://invent.kde.org/qt/qt/qt5
|
|
revision=4
|
|
build_style=meta
|
|
hostmakedepends="cmake clang flex perl glib-devel pkg-config
|
|
python re2c ruby which"
|
|
makedepends="SDL2-devel Vulkan-Headers alsa-lib-devel double-conversion-devel
|
|
eudev-libudev-devel ffmpeg-devel freetds-devel glib-devel gst-plugins-base1-devel
|
|
gtk+3-devel icu-devel libXv-devel libbluetooth-devel libcap-devel
|
|
libinput-devel libmng-devel libmariadbclient-devel libproxy-devel
|
|
libvpx-devel libwebp-devel libxkbcommon-devel
|
|
libxslt-devel libxml2-devel cups-devel minizip-devel
|
|
opus-devel pciutils-devel pcre2-devel postgresql-libs-devel
|
|
protobuf-devel pulseaudio-devel tslib-devel openssl-devel
|
|
unixodbc-devel xcb-util-image-devel xcb-util-keysyms-devel
|
|
xcb-util-renderutil-devel xcb-util-wm-devel libzstd-devel harfbuzz-devel"
|
|
depends="qt5-dbus qt5-gui qt5-core qt5-widgets qt5-network qt5-xml
|
|
qt5-test qt5-sql qt5-concurrent qt5-printsupport qt5-opengl"
|
|
short_desc="Cross-platform application and UI framework (QT5)"
|
|
maintainer="John <me@johnnynator.dev>"
|
|
license="GPL-3.0-or-later, LGPL-3.0-or-later"
|
|
homepage="https://qt.io/"
|
|
# https://pypi.org/project/git-archive-all
|
|
# tarball is generated with `git archive-all qt5-$version.tar.gz`
|
|
# to keep the size smaller qtwebengine, qtwebview, qtdocgallery, qtactiveqt and qtpim
|
|
# can be marked with the export-ignore attribute
|
|
distfiles="https://void.johnnynator.dev/distfiles/qt5-${version}.tar.gz"
|
|
checksum=9d57af471c78029a362276b7c99108ea009f511bb9ba6ff6cb884f6ddd255e9f
|
|
python_version=2 #unverified
|
|
replaces="qt5-doc<5.6.0 qt5-quick1<5.6.0 qt5-quick1-devel<5.6.0 qt5-webkit<5.6.0 qt5-webkit-devel<5.6.0
|
|
qt5-enginio<5.7.1 qt5-enginio-devel<5.7.1 qt5-plugin-gtk<5.7.1 qt5-canvas3d<5.13.0"
|
|
lib32mode=full
|
|
|
|
CXXFLAGS="-Wno-deprecated-declarations -Wno-class-memaccess -Wno-packed-not-aligned"
|
|
# Required for musl libc
|
|
LDFLAGS="-pthread -ldl -fPIE -Wl,-z,stack-size=2097152"
|
|
|
|
if [ "$CROSS_BUILD" ]; then
|
|
# Need some devel packages in the host to build qmake, moc, uic, rcc
|
|
# wayland-devel contains /usr/bin/wayland-scanner
|
|
hostmakedepends+=" icu-devel wayland-devel zlib-devel libxml2-devel"
|
|
hostmakedepends+=" postgresql-libs-devel"
|
|
fi
|
|
|
|
if [ "$XBPS_TARGET_NO_ATOMIC8" ]; then
|
|
makedepends+=" libatomic-devel"
|
|
fi
|
|
|
|
_cleanup_wrksrc_leak() {
|
|
if [ -d "${PKGDESTDIR}/usr/lib/cmake" ]; then
|
|
# Replace references to ${wrksrc} in cmake files
|
|
vsed -i ${PKGDESTDIR}/usr/lib/cmake/*/*.cmake \
|
|
-e "s;${wrksrc}/host;/usr/lib/qt5;g" \
|
|
-e "s;devices/void-${XBPS_CROSS_TRIPLET}-g++;linux-g++;g"
|
|
fi
|
|
if [ -d "${PKGDESTDIR}/usr/lib/pkgconfig" ]; then
|
|
# Replace references to ${wrksrc} in pkgconfig files
|
|
vsed -i ${PKGDESTDIR}/usr/lib/pkgconfig/*.pc \
|
|
-e "s;${wrksrc}/host;/usr/lib/qt5;g" \
|
|
-e "s;devices/void-${XBPS_CROSS_TRIPLET}-g++;linux-g++;g"
|
|
fi
|
|
# Remove QMAKE_PRL_BUILD_DIR from hint files for static libraries
|
|
# and replace references to ${wrksrc}
|
|
find ${PKGDESTDIR} -iname "*.prl" -exec sed -i "{}" \
|
|
-e "/^QMAKE_PRL_BUILD_DIR/d" \
|
|
-e "s;-L${wrksrc}/qtbase/lib;-L/usr/lib;g" \;
|
|
# Replace ${wrksrc} in project include files
|
|
find ${PKGDESTDIR} -iname "*.pri" -exec sed -i "{}" \
|
|
-e "s;${wrksrc}/qtbase;/usr/lib/qt5;g" \;
|
|
}
|
|
|
|
_install_subpkg() {
|
|
local module=$1 f base
|
|
cd ${wrksrc}/${module}
|
|
make INSTALL_ROOT=${PKGDESTDIR} install
|
|
rm -rf ${PKGDESTDIR}/builddir
|
|
rm -rf ${PKGDESTDIR}/usr/include
|
|
rm -rf ${PKGDESTDIR}/usr/lib/cmake
|
|
rm -rf ${PKGDESTDIR}/usr/lib/qt5/mkspecs
|
|
rm -rf ${PKGDESTDIR}/usr/lib/pkgconfig
|
|
rm -f ${PKGDESTDIR}/usr/lib/*.a
|
|
rm -f ${PKGDESTDIR}/usr/lib/*.so
|
|
rm -f ${PKGDESTDIR}/usr/lib/*.prl
|
|
if [ -d ${PKGDESTDIR}/usr/lib/qt5/bin ]; then
|
|
if [ "$CROSS_BUILD" ]; then
|
|
for f in $(find ${PKGDESTDIR}/usr/lib/qt5/bin -name "*-target" -type f); do
|
|
base=${f##*/}
|
|
mv -v ${f} ${f%-target}
|
|
done
|
|
fi
|
|
vmkdir usr/bin
|
|
for f in $(find ${PKGDESTDIR}/usr/lib/qt5/bin -type f); do
|
|
base=${f##*/}
|
|
ln -sf /usr/lib/qt5/bin/${base} ${PKGDESTDIR}/usr/bin/${base}-qt5
|
|
done
|
|
fi
|
|
}
|
|
|
|
_install_devel() {
|
|
local module=$1
|
|
cd ${wrksrc}/${module}
|
|
make INSTALL_ROOT=${PKGDESTDIR} install
|
|
vmkdir usr/lib/qt5/mkspecs/modules
|
|
if [ -d "${PKGDESTDIR}${wrksrc}/host/mkspecs/modules" ]; then
|
|
mv -nv ${PKGDESTDIR}${wrksrc}/host/mkspecs/modules/* \
|
|
${PKGDESTDIR}/usr/lib/qt5/mkspecs/modules/
|
|
fi
|
|
rm -rf ${PKGDESTDIR}/usr/lib/metatypes
|
|
rm -rf ${PKGDESTDIR}/builddir
|
|
rm -rf ${PKGDESTDIR}/usr/share
|
|
rm -rf ${PKGDESTDIR}/usr/lib/qt5/bin
|
|
rm -rf ${PKGDESTDIR}/usr/lib/qt5/qml
|
|
rm -rf ${PKGDESTDIR}/usr/lib/qt5/libexec
|
|
rm -rf ${PKGDESTDIR}/usr/lib/qt5/plugins
|
|
rm -f ${PKGDESTDIR}/usr/lib/*.so.*
|
|
_cleanup_wrksrc_leak
|
|
}
|
|
|
|
_move_target_binaries() {
|
|
local f
|
|
[ -z "$CROSS_BUILD" ] && return 0
|
|
vmkdir usr/lib/qt5/bin
|
|
for f in $@; do
|
|
if [ -f ${DESTDIR}/usr/lib/qt5/bin/${f}-target ]; then
|
|
mv -v ${DESTDIR}/usr/lib/qt5/bin/${f}-target \
|
|
${PKGDESTDIR}/usr/lib/qt5/bin/${f}
|
|
fi
|
|
done
|
|
}
|
|
|
|
_create_config() {
|
|
local specs=${wrksrc}/qtbase/mkspecs/devices device="$1"
|
|
local qmake_conf="${specs}/${device}/qmake.conf"
|
|
|
|
mkdir -p ${specs}/${device}
|
|
|
|
echo "#" > ${qmake_conf}
|
|
echo "# qmake configuration for building with $XBPS_TARGET_MACHINE" >> ${qmake_conf}
|
|
echo "#" >> ${qmake_conf}
|
|
echo >> ${qmake_conf}
|
|
echo "include(../common/linux_device_pre.conf)" >> ${qmake_conf}
|
|
echo >> ${qmake_conf}
|
|
# Fake distro name to tell we want control
|
|
echo "DISTRO = arch" >> ${qmake_conf}
|
|
# Hard float on armv6, armv7, not on armv5tel
|
|
case "$XBPS_TARGET_MACHINE" in
|
|
armv6*|armv7*)
|
|
echo "DISTRO_OPTS += hard-float" >> ${qmake_conf}
|
|
;;
|
|
esac
|
|
echo "QMAKE_CC = ${CC}" >> ${qmake_conf}
|
|
echo "QMAKE_CXX = ${CXX}" >> ${qmake_conf}
|
|
echo "QMAKE_LINK = ${CXX}" >> ${qmake_conf}
|
|
echo "QMAKE_LINK_SHLIB = ${CXX}" >> ${qmake_conf}
|
|
echo "QMAKE_LFLAGS = ${LDFLAGS}" >> ${qmake_conf}
|
|
echo "QMAKE_CFLAGS = ${CFLAGS}" >> ${qmake_conf}
|
|
echo "QMAKE_CXXFLAGS = ${CXXFLAGS}" >> ${qmake_conf}
|
|
echo >> ${qmake_conf}
|
|
case "$XBPS_TARGET_MACHINE" in
|
|
arm*)
|
|
echo "include(../common/linux_arm_device_post.conf)" >> ${qmake_conf} ;;
|
|
*)
|
|
echo "include(../common/linux_device_post.conf)" >> ${qmake_conf} ;;
|
|
esac
|
|
echo "load(qt_config)" >> ${qmake_conf}
|
|
|
|
echo '#include "../../linux-g++/qplatformdefs.h"' > ${specs}/${device}/qplatformdefs.h
|
|
}
|
|
|
|
_msg_cross() {
|
|
msg_normal "***************************************************\n"
|
|
msg_normal "$1 for target ${CROSS_BUILD} ...\n"
|
|
msg_normal "***************************************************\n"
|
|
}
|
|
|
|
post_extract() {
|
|
find -maxdepth 1 -type d -exec mkdir -p {}/.git \;
|
|
}
|
|
|
|
do_configure() {
|
|
local opts spec
|
|
|
|
case "$XBPS_TARGET_MACHINE" in
|
|
mips*) grep -rl "<sgidefs.h>" | xargs sed -i -e "s;<sgidefs.h>;<asm/sgidefs.h>;" ;;
|
|
esac
|
|
|
|
# Cross build patches
|
|
if [ "$CROSS_BUILD" ]; then
|
|
# This also sets default {C,CXX,LD}FLAGS for projects built using qmake
|
|
vsed -i -e "s|^\(QMAKE_CFLAGS_RELEASE.*\)|\1 ${XBPS_CFLAGS}|" \
|
|
${wrksrc}/qtbase/mkspecs/common/gcc-base.conf
|
|
vsed -i -e "s|^\(QMAKE_LFLAGS_RELEASE.*\)|\1 ${XBPS_LDFLAGS}|" \
|
|
${wrksrc}/qtbase/mkspecs/common/g++-unix.conf
|
|
else
|
|
# qmake {CXX,L}FLAGS patches
|
|
vsed -i -e "s|^\(CXXFLAGS =.*\)|\1 ${CXXFLAGS}|" \
|
|
-e "s|^\(LFLAGS =.*\)|\1 ${LDFLAGS}|" \
|
|
${wrksrc}/qtbase/qmake/Makefile.unix
|
|
|
|
# Build qmake using Void {C,LD}FLAGS
|
|
# This also sets default {C,CXX,LD}FLAGS for projects built using qmake
|
|
vsed -i -e "s|^\(QMAKE_CFLAGS_RELEASE.*\)|\1 ${CFLAGS}|" \
|
|
${wrksrc}/qtbase/mkspecs/common/gcc-base.conf
|
|
vsed -i -e "s|^\(QMAKE_LFLAGS_RELEASE.*\)|\1 ${LDFLAGS}|" \
|
|
${wrksrc}/qtbase/mkspecs/common/g++-unix.conf
|
|
fi
|
|
|
|
opts+=" -confirm-license"
|
|
opts+=" -opensource"
|
|
opts+=" -prefix /usr"
|
|
opts+=" -bindir /usr/lib/qt5/bin"
|
|
opts+=" -datadir /usr/share/qt5"
|
|
opts+=" -headerdir /usr/include/qt5"
|
|
opts+=" -sysconfdir /etc/xdg"
|
|
opts+=" -plugindir /usr/lib/qt5/plugins"
|
|
opts+=" -docdir /usr/share/doc/qt5"
|
|
opts+=" -importdir /usr/lib/qt5/imports"
|
|
opts+=" -translationdir /usr/share/qt5/translations"
|
|
opts+=" -examplesdir /usr/share/qt5/examples"
|
|
opts+=" -archdatadir /usr/lib/qt5"
|
|
opts+=" -accessibility"
|
|
opts+=" -fontconfig"
|
|
opts+=" -icu"
|
|
opts+=" -openssl-linked"
|
|
opts+=" -dbus-linked"
|
|
opts+=" -sql-mysql"
|
|
opts+=" -mysql_config ${XBPS_CROSS_BASE}/usr/bin/mysql_config"
|
|
opts+=" -sql-psql"
|
|
opts+=" -psql_config /usr/bin/pg_config"
|
|
opts+=" -no-pch"
|
|
opts+=" -no-strip"
|
|
opts+=" -nomake examples"
|
|
opts+=" -optimized-qmake"
|
|
# opts+=" -opengl dynamic"
|
|
opts+=" -no-use-gold-linker"
|
|
opts+=" -system-libjpeg"
|
|
opts+=" -system-libpng"
|
|
opts+=" -system-zlib"
|
|
opts+=" -system-sqlite"
|
|
opts+=" -system-harfbuzz"
|
|
opts+=" -no-feature-eglfs_brcm" # missing include path
|
|
opts+=" -silent"
|
|
# opts+=" -v"
|
|
opts+=" -skip qtwebengine"
|
|
opts+=" -skip qtwebview"
|
|
opts+=" -skip qtdocgallery"
|
|
opts+=" -skip qtpim"
|
|
opts+=" -skip qtsystems"
|
|
opts+=" -skip qtspeech"
|
|
LDFLAGS+=" -Wl,--no-keep-memory" # needs more than 8GB RAM else
|
|
if [ "$CROSS_BUILD" ]; then
|
|
spec=void-${XBPS_CROSS_TRIPLET}-g++
|
|
_create_config ${spec}
|
|
opts+=" -device ${spec}"
|
|
opts+=" -device-option CROSS_COMPILE=${XBPS_CROSS_TRIPLET}-"
|
|
opts+=" -sysroot ${XBPS_CROSS_BASE}"
|
|
opts+=" -hostprefix host"
|
|
opts+=" -extprefix /usr"
|
|
|
|
# Make sure libQt5Designer is built
|
|
cp -v ${FILESDIR}/qttools_src.pro qttools/src/src.pro
|
|
cp -v ${FILESDIR}/designer_src.pro qttools/src/designer/src/src.pro
|
|
cp -v ${FILESDIR}/assistant.pro qttools/src/assistant/assistant.pro
|
|
cp -v ${FILESDIR}/linguist.pro qttools/src/linguist/linguist.pro
|
|
cp -v ${FILESDIR}/uitools.pro qttools/src/designer/src/uitools/uitools.pro
|
|
fi
|
|
|
|
CC="cc" CXX="c++" CPP="cpp" LD="c++" AR="ar" AS="as" NM="nm" \
|
|
OBJDUMP="objdump" STRIP="strip" RANLIB="ranlib" \
|
|
CFLAGS="$XBPS_CFLAGS" CXXFLAGS="$XBPS_CXXFLAGS" \
|
|
CPPFLAGS="$XBPS_CPPFLAGS" LDFLAGS="$XBPS_LDFLAGS" \
|
|
LFLAGS="$XBPS_LDFLAGS" \
|
|
${wrksrc}/configure ${opts}
|
|
export LD_LIBRARY_PATH="${wrksrc}/qtbase/lib:${wrksrc}/qttools/lib:${LD_LIBRARY_PATH}"
|
|
}
|
|
|
|
do_build() {
|
|
# Run make twice because sometimes a file "chrome/grit/generated_resources.h"
|
|
# is not yet ready when it is to be included. Repeating make works around that
|
|
# problem without having to resort to disable_parallel_build=yes
|
|
# or some other files
|
|
make ${makejobs} || make ${makejobs}
|
|
}
|
|
|
|
do_install() {
|
|
local f base bin dir dirs
|
|
|
|
if [ -z "$CROSS_BUILD" ]; then
|
|
unset CC CXX LD CPP AR AS RANLIB
|
|
fi
|
|
cd ${wrksrc}/qtbase
|
|
make INSTALL_ROOT=${DESTDIR} install
|
|
|
|
_cleanup_wrksrc_leak
|
|
|
|
# Symbolic links for remaining binaries
|
|
vmkdir usr/bin
|
|
for f in $(find ${DESTDIR}/usr/lib/qt5/bin -type f); do
|
|
base=${f##*/}
|
|
ln -sf /usr/lib/qt5/bin/${base} ${PKGDESTDIR}/usr/bin/${base}-qt5
|
|
done
|
|
|
|
if [ "$CROSS_BUILD" ]; then
|
|
vmkdir usr/bin
|
|
vmkdir usr/lib/qt5/bin
|
|
|
|
#
|
|
# Build qmake for the target
|
|
#
|
|
_msg_cross "Building qmake"
|
|
cd ${wrksrc}/qtbase/qmake
|
|
sed Makefile \
|
|
-e"s;^\(CC\\s*=\).*;\1 $CC;" \
|
|
-e"s;^\(CXX\\s*=\).*;\1 $CXX;" \
|
|
-e"s;^\(LINK\\s*=\).*;\1 $CXX;" \
|
|
-e"s;^\(QMAKE_CFLAGS\\s*=\).*;\1 $CFLAGS;" \
|
|
-e"s;^\(QMAKE_CXXFLAGS\\s*=\).*;\1 $CXXFLAGS;" \
|
|
-e"s;^\(QMAKE_LFLAGS\\s*=\).*;\1 $LDFLAGS;" \
|
|
-e"s;\$(BUILD_PATH)/bin;${PKGDESTDIR}/usr/lib/qt5/bin;" \
|
|
> Makefile.target
|
|
make clean
|
|
make -f Makefile.target ${makejobs}
|
|
ln -sf ../lib/qt5/bin/qmake ${PKGDESTDIR}/usr/bin/qmake-qt5
|
|
cp -ar ${wrksrc}/qtbase/mkspecs ${PKGDESTDIR}/usr/lib/qt5
|
|
_cleanup_wrksrc_leak
|
|
|
|
#
|
|
# Build qmldevtools for the target
|
|
#
|
|
base=qmldevtools
|
|
dir=qtdeclarative/src
|
|
_msg_cross " Building ${base}"
|
|
cd ${wrksrc}/${dir}/${base}
|
|
[ -f "${base}.pro" ] && cp -v -a ${base}.pro{,.orig}
|
|
vsed -i ${base}.pro \
|
|
-e "/option(host_build)/d" \
|
|
-e "/include(..\/3rdparty\/masm\/masm-defs.pri)/i include(../3rdparty/masm/masm.pri)"
|
|
make clean
|
|
# Create the Makefile
|
|
mv -v Makefile{,.orig}
|
|
${wrksrc}/qtbase/bin/qmake -o Makefile ${base}.pro
|
|
make ${makejobs}
|
|
# Restore profile, if any
|
|
[ -f "${base}.pro.orig" ] && mv -v ${base}.pro{.orig,}
|
|
mv -v Makefile{.orig,}
|
|
# Avoid rebuilding the Makefile by changing the rule
|
|
vsed -i Makefile -e "s;^Makefile:;Makefile.host:;"
|
|
|
|
#
|
|
# Build various tools for the target
|
|
#
|
|
dirs+=" qtdeclarative/tools/qmlmin"
|
|
dirs+=" qtdeclarative/tools/qmllint"
|
|
dirs+=" qtdeclarative/tools/qmlformat"
|
|
dirs+=" qtdeclarative/tools/qmlcachegen"
|
|
dirs+=" qtdeclarative/tools/qmlimportscanner"
|
|
dirs+=" qtbase/src/tools/moc"
|
|
dirs+=" qtbase/src/tools/rcc"
|
|
dirs+=" qtbase/src/tools/uic"
|
|
dirs+=" qtbase/src/tools/qdbuscpp2xml"
|
|
dirs+=" qtbase/src/tools/qdbusxml2cpp"
|
|
dirs+=" qtbase/src/tools/qvkgen"
|
|
dirs+=" qtbase/src/tools/tracegen"
|
|
dirs+=" qtbase/src/tools/qlalr"
|
|
dirs+=" qt3d/tools/qgltf"
|
|
dirs+=" qtremoteobjects/tools/repc"
|
|
dirs+=" qtscxml/tools/qscxmlc"
|
|
dirs+=" qttools/src/qtattributionsscanner"
|
|
dirs+=" qttools/src/linguist/lconvert"
|
|
dirs+=" qttools/src/linguist/lrelease"
|
|
dirs+=" qttools/src/linguist/lrelease-pro"
|
|
dirs+=" qttools/src/linguist/lprodump"
|
|
dirs+=" qttools/src/linguist/lupdate"
|
|
dirs+=" qttools/src/linguist/lupdate-pro"
|
|
# Cannot be cross compiled (target clang issue)
|
|
# dirs+=" qttools/src/qdoc"
|
|
|
|
for f in ${dirs}; do
|
|
base=${f##*/}
|
|
dir=${f%%/*}
|
|
|
|
_msg_cross " Building ${base}"
|
|
|
|
cd ${wrksrc}/${f}
|
|
if [ -x "${wrksrc}/${dir}/bin/${base}" ]; then
|
|
mv -v ${wrksrc}/${dir}/bin/${base}{,-host}
|
|
fi
|
|
[ -f Makefile ] && make clean
|
|
[ -f "${base}.pro" ] && cp -a ${base}.pro{,.orig}
|
|
if [ -f "${FILESDIR}/${base}.pro" ]; then
|
|
# A specific *.pro file is available, use it.
|
|
cp ${FILESDIR}/${base}.pro ${base}.pro
|
|
else
|
|
# Otherwise strip the option(host_build)
|
|
vsed -i ${base}.pro -e "/option(host_build)/d"
|
|
fi
|
|
# Create the Makefile
|
|
[ -f Makefile ] && mv -v Makefile{,.orig}
|
|
${wrksrc}/qtbase/bin/qmake -o Makefile ${base}.pro
|
|
|
|
# Now patch the Makefile(s) to not use the bootstrap libs and
|
|
# use the compiler, linker, flags, etc. for the target arch
|
|
find . -name "Makefile*" -exec sed -i "{}" \
|
|
-e "s; force_bootstrap;;" \
|
|
-e "s;^\(CC\\s*=\).*;\1 $CC;" \
|
|
-e "s;^\(CXX\\s*=\).*;\1 $CXX;" \
|
|
-e "s;^\(LINK\\s*=\).*;\1 $CXX;" \
|
|
-e "s;^\(CFLAGS\\s*=.*\);\1 $CFLAGS;" \
|
|
-e "s;^\(CXXFLAGS\\s*=.*\);\1 $CXXFLAGS;" \
|
|
-e "s;^\(LFLAGS\\s*=.*\);\1 $LDFLAGS;" \
|
|
-e "s;^\(AR\\s*=\).*;\1 $AR cqs;" \
|
|
-e "s;^\(RANLIB\\s*=\).*;\1 $RANLIB;" \
|
|
\;
|
|
# Set a different destination directory and target name
|
|
vsed -i Makefile \
|
|
-e "s;^\(DESTDIR\\s*=\).*;\1 ${DESTDIR}/usr/lib/qt5/bin/;" \
|
|
-e "s;^\(TARGET\\s*=\).*;\1 ${DESTDIR}/usr/lib/qt5/bin/${base}-target;"
|
|
make ${makejobs}
|
|
# Restore profile, if any
|
|
[ -f "${base}.pro.orig" ] && mv -v ${base}.pro{.orig,}
|
|
[ -f Makefile.orig ] && mv -v Makefile{.orig,}
|
|
# Avoid rebuilding the Makefile by changing the rule
|
|
vsed -i Makefile -e 's;^all:.*;all:;'
|
|
vsed -i Makefile -e "s;^Makefile:;Makefile.host:;"
|
|
if [ -x "${wrksrc}/${dir}/bin/${base}-host" ]; then
|
|
mv -v ${wrksrc}/${dir}/bin/${base}{-host,}
|
|
touch ${wrksrc}/${dir}/bin/${base}
|
|
fi
|
|
done
|
|
fi
|
|
# Remove builddir from installation
|
|
rm -rf ${DESTDIR}/builddir
|
|
}
|
|
|
|
qt5-gui_package() {
|
|
short_desc+=" - Gui"
|
|
pkg_install() {
|
|
vmove "usr/lib/libQt5Gui.so*"
|
|
vmove "usr/lib/libQt5XcbQpa.so*"
|
|
vmove "usr/lib/libQt5EglFSDeviceIntegration.so*"
|
|
vmove "usr/lib/libQt5EglFsKmsSupport.so*"
|
|
vmove usr/lib/qt5/plugins/generic
|
|
vmove usr/lib/qt5/plugins/platforms
|
|
vmove usr/lib/qt5/plugins/xcbglintegrations
|
|
vmove usr/lib/qt5/plugins/imageformats
|
|
vmove usr/lib/qt5/plugins/egldeviceintegrations
|
|
vmove usr/lib/qt5/plugins/platforminputcontexts
|
|
vmove usr/lib/qt5/plugins/platformthemes
|
|
}
|
|
}
|
|
|
|
qt5-dbus_package() {
|
|
short_desc+=" - DBus"
|
|
pkg_install() {
|
|
vmove "usr/lib/libQt5DBus.so*"
|
|
}
|
|
}
|
|
|
|
qt5-core_package() {
|
|
short_desc+=" - Core"
|
|
pkg_install() {
|
|
vmove "usr/lib/libQt5Core.so*"
|
|
}
|
|
}
|
|
|
|
qt5-opengl_package() {
|
|
short_desc+=" - OpenGL"
|
|
pkg_install() {
|
|
vmove "usr/lib/libQt5OpenGL.so*"
|
|
}
|
|
}
|
|
|
|
qt5-printsupport_package() {
|
|
short_desc+=" - Print Support"
|
|
pkg_install() {
|
|
vmove "usr/lib/libQt5PrintSupport.so*"
|
|
vmove usr/lib/qt5/plugins/printsupport
|
|
}
|
|
}
|
|
|
|
qt5-concurrent_package() {
|
|
short_desc+=" - Concurrency"
|
|
pkg_install() {
|
|
vmove "usr/lib/libQt5Concurrent.so*"
|
|
}
|
|
}
|
|
|
|
qt5-widgets_package() {
|
|
short_desc+=" - Widgets"
|
|
pkg_install() {
|
|
vmove "usr/lib/libQt5Widgets.so*"
|
|
}
|
|
}
|
|
|
|
qt5-network_package() {
|
|
short_desc+=" - Network"
|
|
pkg_install() {
|
|
vmove "usr/lib/libQt5Network.so*"
|
|
vmove usr/lib/qt5/plugins/bearer
|
|
}
|
|
}
|
|
|
|
qt5-sql_package() {
|
|
short_desc+=" - Sql"
|
|
pkg_install() {
|
|
vmove "usr/lib/libQt5Sql.so*"
|
|
}
|
|
}
|
|
|
|
qt5-test_package() {
|
|
short_desc+=" - Test"
|
|
pkg_install() {
|
|
vmove "usr/lib/libQt5Test.so*"
|
|
}
|
|
}
|
|
|
|
qt5-xml_package() {
|
|
short_desc+=" - Xml"
|
|
pkg_install() {
|
|
vmove "usr/lib/libQt5Xml.so*"
|
|
}
|
|
}
|
|
|
|
qt5-base-docs_package() {
|
|
short_desc+=" - Documentation"
|
|
pkg_install() {
|
|
vmove usr/share/doc/qt5
|
|
}
|
|
}
|
|
|
|
qt5-3d-devel_package() {
|
|
short_desc+=" - C++ and QML APIs for 3D graphics (development)"
|
|
depends="qt5-3d-${version}_${revision} qt5-devel-${version}_${revision}"
|
|
pkg_install() {
|
|
_install_devel qt3d
|
|
_move_target_binaries qgltf
|
|
}
|
|
}
|
|
|
|
qt5-3d_package() {
|
|
short_desc+=" - C++ and QML APIs for 3D graphics"
|
|
pkg_install() {
|
|
_install_subpkg qt3d
|
|
}
|
|
}
|
|
|
|
qt5-charts-devel_package() {
|
|
short_desc+=" - Charts component (development)"
|
|
depends="qt5-charts-${version}_${revision} qt5-declarative-devel-${version}_${revision}"
|
|
pkg_install() {
|
|
_install_devel qtcharts
|
|
}
|
|
}
|
|
|
|
qt5-charts_package() {
|
|
short_desc+=" - Charts component"
|
|
pkg_install() {
|
|
_install_subpkg qtcharts
|
|
}
|
|
}
|
|
|
|
qt5-connectivity-devel_package() {
|
|
short_desc+=" - Connectivity component (development)"
|
|
depends="qt5-connectivity-${version}_${revision} qt5-declarative-devel-${version}_${revision}"
|
|
pkg_install() {
|
|
_install_devel qtconnectivity
|
|
}
|
|
}
|
|
|
|
qt5-connectivity_package() {
|
|
short_desc+=" - Connectivity component"
|
|
pkg_install() {
|
|
_install_subpkg qtconnectivity
|
|
}
|
|
}
|
|
|
|
qt5-datavis3d-devel_package() {
|
|
short_desc+=" - 3D data visualization (development)"
|
|
depends="qt5-datavis3d-${version}_${revision} qt5-declarative-devel-${version}_${revision}"
|
|
pkg_install() {
|
|
_install_devel qtdatavis3d
|
|
}
|
|
}
|
|
|
|
qt5-datavis3d_package() {
|
|
short_desc+=" - 3D data visualization"
|
|
pkg_install() {
|
|
_install_subpkg qtdatavis3d
|
|
}
|
|
}
|
|
|
|
qt5-declarative-devel_package() {
|
|
short_desc+=" - Declarative component (development)"
|
|
depends="qt5-declarative-${version}_${revision} qt5-devel-${version}_${revision}"
|
|
pkg_install() {
|
|
_install_devel qtdeclarative
|
|
}
|
|
}
|
|
|
|
qt5-declarative_package() {
|
|
short_desc+=" - Declarative component"
|
|
pkg_install() {
|
|
_install_subpkg qtdeclarative
|
|
_move_target_binaries qmlmin qmllint qmlformat qmlimportscanner qmlcachegen
|
|
}
|
|
}
|
|
|
|
qt5-examples_package() {
|
|
short_desc+=" - Examples"
|
|
depends="qt5-devel-${version}_${revision} qt5-qmake-${version}_${revision}
|
|
qt5-host-tools-${version}_${revision}"
|
|
pkg_install() {
|
|
local dir mod base=usr/share/qt5/examples
|
|
vmkdir ${base}
|
|
vcopy qtbase/examples/examples.pro ${base}/
|
|
# Copy examples source
|
|
for dir in $(find ${wrksrc} -maxdepth 2 -type d -name examples); do
|
|
mod=${dir%/examples}
|
|
mod=${mod##*/}
|
|
vcopy ${dir}/* ${base}/
|
|
if [ -e "${PKGDESTDIR}/${base}/README" ]; then
|
|
mv ${PKGDESTDIR}/${base}/README{,.${mod}}
|
|
fi
|
|
done
|
|
}
|
|
}
|
|
|
|
qt5-lottie-devel_package() {
|
|
pkg_install() {
|
|
_install_devel qtlottie
|
|
}
|
|
}
|
|
|
|
qt5-lottie_package() {
|
|
pkg_install() {
|
|
_install_subpkg qtlottie
|
|
}
|
|
}
|
|
|
|
qt5-gamepad-devel_package() {
|
|
short_desc+=" - Gamepad component (development)"
|
|
depends="qt5-gamepad-${version}_${revision} qt5-declarative-devel-${version}_${revision}"
|
|
pkg_install() {
|
|
_install_devel qtgamepad
|
|
}
|
|
}
|
|
|
|
qt5-gamepad_package() {
|
|
short_desc+=" - Gamepad component"
|
|
pkg_install() {
|
|
_install_subpkg qtgamepad
|
|
}
|
|
}
|
|
|
|
qt5-graphicaleffects_package() {
|
|
short_desc+=" - Graphicaleffects component"
|
|
pkg_install() {
|
|
_install_subpkg qtgraphicaleffects
|
|
}
|
|
}
|
|
|
|
qt5-imageformats_package() {
|
|
short_desc+=" - Plugins for additional image formats"
|
|
pkg_install() {
|
|
_install_subpkg qtimageformats
|
|
}
|
|
}
|
|
|
|
qt5-location-devel_package() {
|
|
short_desc+=" - Location and Positioning components (development)"
|
|
depends="qt5-location-${version}_${revision} qt5-devel-${version}_${revision}"
|
|
pkg_install() {
|
|
_install_devel qtlocation
|
|
}
|
|
}
|
|
|
|
qt5-location_package() {
|
|
short_desc+=" - Location and Positioning components"
|
|
pkg_install() {
|
|
_install_subpkg qtlocation
|
|
}
|
|
}
|
|
|
|
qt5-multimedia-devel_package() {
|
|
short_desc+=" - Multimedia component (development)"
|
|
depends="qt5-multimedia-${version}_${revision} qt5-devel-${version}_${revision}"
|
|
pkg_install() {
|
|
_install_devel qtmultimedia
|
|
}
|
|
}
|
|
|
|
qt5-multimedia_package() {
|
|
short_desc+=" - Multimedia component"
|
|
pkg_install() {
|
|
_install_subpkg qtmultimedia
|
|
}
|
|
}
|
|
|
|
qt5-networkauth-devel_package() {
|
|
short_desc+=" - NetworkAuth component (development)"
|
|
depends="qt5-networkauth-${version}_${revision} qt5-devel-${version}_${revision}"
|
|
pkg_install() {
|
|
_install_devel qtnetworkauth
|
|
}
|
|
}
|
|
|
|
qt5-networkauth_package() {
|
|
short_desc+=" - NetworkAuth component"
|
|
pkg_install() {
|
|
_install_subpkg qtnetworkauth
|
|
}
|
|
}
|
|
|
|
qt5-purchasing-devel_package() {
|
|
short_desc+=" - Purchasing component (development)"
|
|
depends="qt5-purchasing-${version}_${revision} qt5-devel-${version}_${revision}"
|
|
pkg_install() {
|
|
_install_devel qtpurchasing
|
|
}
|
|
}
|
|
|
|
qt5-purchasing_package() {
|
|
short_desc+=" - Purchasing component"
|
|
pkg_install() {
|
|
_install_subpkg qtpurchasing
|
|
}
|
|
}
|
|
|
|
qt5-quickcontrols_package() {
|
|
short_desc+=" - Quick UI controls"
|
|
pkg_install() {
|
|
_install_subpkg qtquickcontrols
|
|
}
|
|
}
|
|
|
|
qt5-quickcontrols2-devel_package() {
|
|
short_desc+=" - Quick2 UI controls (development)"
|
|
depends="qt5-quickcontrols2-${version}_${revision} qt5-devel-${version}_${revision}"
|
|
pkg_install() {
|
|
_install_devel qtquickcontrols2
|
|
}
|
|
}
|
|
|
|
qt5-quickcontrols2_package() {
|
|
short_desc+=" - Quick2 UI controls"
|
|
pkg_install() {
|
|
_install_subpkg qtquickcontrols2
|
|
}
|
|
}
|
|
|
|
qt5-quicktimeline_package() {
|
|
short_desc+=" - Keyframe-based animations"
|
|
pkg_install() {
|
|
_install_subpkg qtquicktimeline
|
|
}
|
|
}
|
|
|
|
qt5-remoteobjects-devel_package() {
|
|
short_desc+=" - Remote Objects (development)"
|
|
depends="qt5-remoteobjects-${version}_${revision} qt5-devel-${version}_${revision}"
|
|
pkg_install() {
|
|
_install_devel qtremoteobjects
|
|
}
|
|
}
|
|
|
|
qt5-remoteobjects_package() {
|
|
short_desc+=" - Remote Objects"
|
|
pkg_install() {
|
|
_install_subpkg qtremoteobjects
|
|
_move_target_binaries repc
|
|
}
|
|
}
|
|
|
|
qt5-script-devel_package() {
|
|
short_desc+=" - Scriptable classes (development)"
|
|
depends="qt5-script-${version}_${revision} qt5-devel-${version}_${revision}"
|
|
pkg_install() {
|
|
_install_devel qtscript
|
|
}
|
|
}
|
|
|
|
qt5-script_package() {
|
|
short_desc+=" - Scriptable classes"
|
|
pkg_install() {
|
|
_install_subpkg qtscript
|
|
}
|
|
}
|
|
|
|
qt5-scxml-devel_package() {
|
|
short_desc+=" - SCXML model integration (development)"
|
|
depends="qt5-scxml-${version}_${revision} qt5-devel-${version}_${revision}"
|
|
pkg_install() {
|
|
_install_devel qtscxml
|
|
}
|
|
}
|
|
|
|
qt5-scxml_package() {
|
|
short_desc+=" - SCXML model integration"
|
|
pkg_install() {
|
|
_install_subpkg qtscxml
|
|
_move_target_binaries qscxmlc
|
|
}
|
|
}
|
|
|
|
qt5-sensors-devel_package() {
|
|
short_desc+=" - Sensors component (development)"
|
|
depends="qt5-sensors-${version}_${revision} qt5-devel-${version}_${revision}"
|
|
pkg_install() {
|
|
_install_devel qtsensors
|
|
}
|
|
}
|
|
|
|
qt5-sensors_package() {
|
|
short_desc+=" - Sensors component"
|
|
pkg_install() {
|
|
_install_subpkg qtsensors
|
|
}
|
|
}
|
|
|
|
qt5-serialbus-devel_package() {
|
|
short_desc+=" - Serial bus component (development)"
|
|
depends="qt5-serialbus-${version}_${revision} qt5-serialport-devel-${version}_${revision}
|
|
qt5-devel-${version}_${revision}"
|
|
pkg_install() {
|
|
_install_devel qtserialbus
|
|
}
|
|
}
|
|
|
|
qt5-serialbus_package() {
|
|
short_desc+=" - Serial bus component"
|
|
pkg_install() {
|
|
_install_subpkg qtserialbus
|
|
}
|
|
}
|
|
|
|
qt5-serialport-devel_package() {
|
|
short_desc+=" - Serial port component (development)"
|
|
depends="qt5-serialport-${version}_${revision} qt5-devel-${version}_${revision}"
|
|
pkg_install() {
|
|
_install_devel qtserialport
|
|
}
|
|
}
|
|
|
|
qt5-serialport_package() {
|
|
short_desc+=" - Serial port component"
|
|
pkg_install() {
|
|
_install_subpkg qtserialport
|
|
}
|
|
}
|
|
|
|
qt5-svg-devel_package() {
|
|
short_desc+=" - Svg component (development)"
|
|
depends="qt5-svg-${version}_${revision} qt5-devel-${version}_${revision}"
|
|
pkg_install() {
|
|
_install_devel qtsvg
|
|
}
|
|
}
|
|
|
|
qt5-svg_package() {
|
|
short_desc+=" - Svg component"
|
|
pkg_install() {
|
|
_install_subpkg qtsvg
|
|
}
|
|
}
|
|
|
|
qt5-virtualkeyboard-devel_package() {
|
|
short_desc+=" - Virtual keyboard (development)"
|
|
depends="qt5-virtualkeyboard-${version}_${revision} qt5-declarative-devel-${version}_${revision}"
|
|
pkg_install() {
|
|
_install_devel qtvirtualkeyboard
|
|
}
|
|
}
|
|
|
|
qt5-virtualkeyboard_package() {
|
|
short_desc+=" - Virtual keyboard"
|
|
pkg_install() {
|
|
_install_subpkg qtvirtualkeyboard
|
|
}
|
|
}
|
|
|
|
qt5-wayland-devel_package() {
|
|
short_desc+=" - Wayland component (development)"
|
|
depends="qt5-wayland-${version}_${revision} qt5-devel-${version}_${revision}"
|
|
pkg_install() {
|
|
_install_devel qtwayland
|
|
}
|
|
}
|
|
|
|
qt5-wayland_package() {
|
|
short_desc+=" - Wayland component"
|
|
pkg_install() {
|
|
_install_subpkg qtwayland
|
|
}
|
|
}
|
|
|
|
qt5-webchannel-devel_package() {
|
|
short_desc+=" - WebChannel component (development)"
|
|
depends="qt5-webchannel-${version}_${revision} qt5-devel-${version}_${revision}"
|
|
pkg_install() {
|
|
_install_devel qtwebchannel
|
|
}
|
|
}
|
|
|
|
qt5-webchannel_package() {
|
|
short_desc+=" - WebChannel component"
|
|
pkg_install() {
|
|
_install_subpkg qtwebchannel
|
|
}
|
|
}
|
|
|
|
qt5-webglplugin-devel_package() {
|
|
short_desc+=" - WebGL plugin (development)"
|
|
depends="qt5-webglplugin-${version}_${revision} qt5-devel-${version}_${revision}"
|
|
pkg_install() {
|
|
_install_devel qtwebglplugin
|
|
}
|
|
}
|
|
|
|
qt5-webglplugin_package() {
|
|
short_desc+=" - WebGL plugin"
|
|
pkg_install() {
|
|
_install_subpkg qtwebglplugin
|
|
}
|
|
}
|
|
|
|
qt5-websockets-devel_package() {
|
|
short_desc+=" - WebSockets component (development)"
|
|
depends="qt5-websockets-${version}_${revision} qt5-devel-${version}_${revision}"
|
|
pkg_install() {
|
|
_install_devel qtwebsockets
|
|
}
|
|
}
|
|
|
|
qt5-websockets_package() {
|
|
short_desc+=" - WebSockets component"
|
|
pkg_install() {
|
|
_install_subpkg qtwebsockets
|
|
}
|
|
}
|
|
|
|
qt5-x11extras-devel_package() {
|
|
short_desc+=" - X11 extras (development)"
|
|
depends="qt5-x11extras-${version}_${revision} qt5-devel-${version}_${revision}"
|
|
pkg_install() {
|
|
_install_devel qtx11extras
|
|
}
|
|
}
|
|
|
|
qt5-x11extras_package() {
|
|
short_desc+=" - X11 extras"
|
|
pkg_install() {
|
|
_install_subpkg qtx11extras
|
|
}
|
|
}
|
|
|
|
qt5-xmlpatterns-devel_package() {
|
|
short_desc+=" - XML components (development)"
|
|
depends="qt5-xmlpatterns-${version}_${revision} qt5-devel-${version}_${revision}"
|
|
pkg_install() {
|
|
_install_devel qtxmlpatterns
|
|
}
|
|
}
|
|
|
|
qt5-xmlpatterns_package() {
|
|
short_desc+=" - XML components"
|
|
depends="qtchooser"
|
|
pkg_install() {
|
|
_install_subpkg qtxmlpatterns
|
|
}
|
|
}
|
|
|
|
qt5-translations_package() {
|
|
short_desc+=" - Translations"
|
|
pkg_install() {
|
|
_install_subpkg qttranslations
|
|
}
|
|
}
|
|
|
|
qt5-host-tools_package() {
|
|
short_desc+=" - Tools required when cross compiling"
|
|
depends="qtchooser"
|
|
pkg_install() {
|
|
local dest=${XBPS_DESTDIR}/${XBPS_CROSS_TRIPLET}/qt5-tools-${version}
|
|
vmkdir usr/lib/qt5/bin
|
|
vmkdir usr/bin
|
|
for f in moc rcc uic qlalr qdbuscpp2xml qdbusxml2cpp qvkgen fixqt4headers.pl tracegen \
|
|
syncqt.pl lconvert lupdate lupdate-pro lprodump lrelease lrelease-pro; do
|
|
if [ -r ${dest}/usr/lib/qt5/bin/${f} ]; then
|
|
mv -v ${dest}/usr/lib/qt5/bin/${f} ${PKGDESTDIR}/usr/lib/qt5/bin/
|
|
fi
|
|
if [ -f ${DESTDIR}/usr/lib/qt5/bin/${f}-target ]; then
|
|
mv -v ${DESTDIR}/usr/lib/qt5/bin/${f}{-target,}
|
|
fi
|
|
if [ -f ${DESTDIR}/usr/lib/qt5/bin/${f} ]; then
|
|
vmove usr/lib/qt5/bin/${f}
|
|
fi
|
|
if [ -f ${DESTDIR}/usr/bin/${f}-qt5 ] || [ -h ${DESTDIR}/usr/bin/${f}-qt5 ]; then
|
|
vmove usr/bin/${f}-qt5
|
|
else
|
|
ln -sf ../lib/qt5/bin/${f} ${PKGDESTDIR}/usr/bin/${f}-qt5
|
|
fi
|
|
done
|
|
}
|
|
}
|
|
|
|
qt5-tools-devel_package() {
|
|
short_desc+=" - Development tools (development)"
|
|
depends="qt5-tools-${version}_${revision} qt5-devel-${version}_${revision}"
|
|
pkg_install() {
|
|
_install_devel qttools
|
|
}
|
|
}
|
|
|
|
qt5-tools_package() {
|
|
short_desc+=" - Development tools"
|
|
depends="qtchooser qt5-translations desktop-file-utils hicolor-icon-theme"
|
|
pkg_install() {
|
|
local f dest=${XBPS_DESTDIR}/${XBPS_CROSS_TRIPLET}/qt5-host-tools-${version}
|
|
_install_subpkg qttools
|
|
# install missing icons and desktop files
|
|
for icon in ${wrksrc}/qttools/src/linguist/linguist/images/icons/linguist-*-32.png ; do
|
|
size=$(echo $(basename ${icon}) | cut -d- -f2)
|
|
install -p -D -m644 ${icon} \
|
|
${PKGDESTDIR}/usr/share/icons/hicolor/${size}x${size}/apps/linguist-qt5.png
|
|
done
|
|
install -Dm644 ${wrksrc}/qttools/src/assistant/assistant/images/assistant.png \
|
|
${PKGDESTDIR}/usr/share/icons/hicolor/32x32/apps/assistant-qt5.png
|
|
install -Dm644 ${wrksrc}/qttools/src/assistant/assistant/images/assistant-128.png \
|
|
${PKGDESTDIR}/usr/share/icons/hicolor/128x128/apps/assistant-qt5.png
|
|
install -Dm644 ${wrksrc}/qttools/src/designer/src/designer/images/designer.png \
|
|
${PKGDESTDIR}/usr/share/icons/hicolor/128x128/apps/designer-qt5.png
|
|
install -Dm644 ${wrksrc}/qttools/src/qdbus/qdbusviewer/images/qdbusviewer.png \
|
|
${PKGDESTDIR}/usr/share/icons/hicolor/32x32/apps/qdbusviewer-qt5.png
|
|
install -Dm644 ${wrksrc}/qttools/src/qdbus/qdbusviewer/images/qdbusviewer-128.png \
|
|
${PKGDESTDIR}/usr/share/icons/hicolor/128x128/apps/qdbusviewer-qt5.png
|
|
# install desktop files
|
|
vmkdir usr/share/applications
|
|
install -m644 ${FILESDIR}/*.desktop ${PKGDESTDIR}/usr/share/applications
|
|
_move_target_binaries qtattributionsscanner qdoc
|
|
# Move some binaries to qt5-host-tools
|
|
for f in lconvert lupdate lupdate-pro lprodump lrelease lrelease-pro; do
|
|
if [ -f ${PKGDESTDIR}/usr/lib/qt5/bin/${f} ]; then
|
|
mkdir -p ${dest}/usr/lib/qt5/bin
|
|
mv -v ${PKGDESTDIR}/usr/lib/qt5/bin/${f} ${dest}/usr/lib/qt5/bin/
|
|
fi
|
|
if [ -f ${PKGDESTDIR}/usr/bin/${f}-qt5 ] || [ -h ${PKGDESTDIR}/usr/bin/${f}-qt5 ]; then
|
|
mkdir -p ${dest}/usr/bin
|
|
mv -v ${PKGDESTDIR}/usr/bin/${f}-qt5 ${dest}/usr/bin/
|
|
fi
|
|
done
|
|
}
|
|
}
|
|
|
|
qt5-devel_package() {
|
|
depends="zlib-devel openssl-devel libXext-devel libXrender-devel
|
|
fontconfig-devel libglib-devel MesaLib-devel mtdev-devel
|
|
dbus-devel icu-devel cups-devel
|
|
qt5-gui-${version}_${revision}
|
|
qt5-dbus-${version}_${revision}
|
|
qt5-core-${version}_${revision}
|
|
qt5-widgets-${version}_${revision}
|
|
qt5-qmake-${version}_${revision}
|
|
qt5-opengl-${version}_${revision}
|
|
qt5-printsupport-${version}_${revision}
|
|
qt5-concurrent-${version}_${revision}
|
|
qt5-sql-${version}_${revision}
|
|
qt5-test-${version}_${revision}
|
|
qt5-network-${version}_${revision}
|
|
qt5-xml-${version}_${revision}
|
|
qt5-host-tools-${version}_${revision}"
|
|
if [ "$XBPS_TARGET_NO_ATOMIC8" ]; then
|
|
depends+=" libatomic-devel"
|
|
fi
|
|
short_desc+=" - Development files"
|
|
# qt5-enginio-devel is gone
|
|
pkg_install() {
|
|
vmove usr/include
|
|
vmove usr/lib/*.a
|
|
vmove usr/lib/*.prl
|
|
vmove usr/lib/cmake
|
|
vmove usr/lib/pkgconfig
|
|
_cleanup_wrksrc_leak
|
|
}
|
|
}
|
|
|
|
qt5-plugin-odbc_package() {
|
|
short_desc+=" - ODBC plugin"
|
|
pkg_install() {
|
|
vmove usr/lib/qt5/plugins/sqldrivers/libqsqlodbc.so
|
|
}
|
|
}
|
|
|
|
qt5-plugin-pgsql_package() {
|
|
short_desc+=" - PostgreSQL plugin"
|
|
pkg_install() {
|
|
vmove usr/lib/qt5/plugins/sqldrivers/libqsqlpsql.so
|
|
}
|
|
}
|
|
|
|
qt5-plugin-mysql_package() {
|
|
short_desc+=" - MySQL plugin"
|
|
pkg_install() {
|
|
vmove usr/lib/qt5/plugins/sqldrivers/libqsqlmysql.so
|
|
}
|
|
}
|
|
|
|
qt5-plugin-sqlite_package() {
|
|
short_desc+=" - SQLite plugin"
|
|
pkg_install() {
|
|
vmove usr/lib/qt5/plugins/sqldrivers/libqsqlite.so
|
|
}
|
|
}
|
|
|
|
qt5-plugin-tds_package() {
|
|
short_desc+=" - TDS plugin"
|
|
pkg_install() {
|
|
vmove usr/lib/qt5/plugins/sqldrivers/libqsqltds.so
|
|
}
|
|
}
|
|
|
|
qt5-qmake_package() {
|
|
short_desc+=" - Qmake Makefile generator tool"
|
|
depends="qtchooser"
|
|
pkg_install() {
|
|
vmove usr/lib/qt5/bin/qmake
|
|
vmove usr/lib/qt5/mkspecs
|
|
vmove usr/bin/qmake-qt5
|
|
|
|
# Change -isystem to -I to avoid "#include_next <stdlib.h>" errors
|
|
vsed -i ${PKGDESTDIR}/usr/lib/qt5/mkspecs/common/gcc-base.conf \
|
|
-e '/^QMAKE_CFLAGS_ISYSTEM/s;-isystem;-I;'
|
|
find ${PKGDESTDIR} -iname "*.prl" -exec sed -i "{}" \
|
|
-e 's%/usr/lib/lib\([^[:space:]]*\)\.[sa][o]*%-l\1%g' \;
|
|
find ${PKGDESTDIR} -iname "*.pri" -exec sed -i "{}" \
|
|
-e 's%/usr/lib/lib\([^[:space:]]*\)\.[sa][o]*%-l\1%g' \;
|
|
|
|
# Undo changes to mkspecs/common/gcc-base.conf and g++-unix.conf
|
|
if [ "$CROSS_BUILD" ]; then
|
|
vsed -i ${PKGDESTDIR}/usr/lib/qt5/mkspecs/common/gcc-base.conf \
|
|
-e "s|^\(QMAKE_CFLAGS_RELEASE.*\) ${XBPS_CFLAGS}|\1|"
|
|
vsed -i ${PKGDESTDIR}/usr/lib/qt5/mkspecs/common/g++-unix.conf \
|
|
-e "s|^\(QMAKE_LFLAGS_RELEASE.*\) ${XBPS_LDFLAGS}|\1|"
|
|
else
|
|
vsed -i ${PKGDESTDIR}/usr/lib/qt5/mkspecs/common/gcc-base.conf \
|
|
-e "s|^\(QMAKE_CFLAGS_RELEASE.*\) ${CFLAGS}|\1|"
|
|
vsed -i ${PKGDESTDIR}/usr/lib/qt5/mkspecs/common/g++-unix.conf\
|
|
-e "s|^\(QMAKE_LFLAGS_RELEASE.*\) ${LDFLAGS}|\1|"
|
|
fi
|
|
}
|
|
}
|
|
|
|
qt5-xcb-private-headers_package() {
|
|
short_desc+=" - Private headers for Qt5 Xcb"
|
|
depends="qt5-devel"
|
|
pkg_install() {
|
|
for f in ${wrksrc}/qtbase/src/plugins/platforms/xcb/*.h; do
|
|
vinstall $f 644 usr/include/qt5xcb-private
|
|
done
|
|
}
|
|
}
|