summaryrefslogtreecommitdiff
path: root/Mk/Uses/qt-dist.mk
diff options
context:
space:
mode:
authorTobias C. Berner <tcberner@FreeBSD.org>2022-08-22 13:30:01 +0200
committerTobias C. Berner <tcberner@FreeBSD.org>2022-08-22 13:52:45 +0200
commitd33dfbef9f9f8317bc753217a757a433265c4bd4 (patch)
tree98535501709084268a5e3e7ac022b49868d12f11 /Mk/Uses/qt-dist.mk
parentqt6: fix build on i386 (diff)
qt6: do not install empty cmake & pkgconfig directories in Qt-prefix
Diffstat (limited to 'Mk/Uses/qt-dist.mk')
-rw-r--r--Mk/Uses/qt-dist.mk17
1 files changed, 13 insertions, 4 deletions
diff --git a/Mk/Uses/qt-dist.mk b/Mk/Uses/qt-dist.mk
index 7a8ed434bf0b..a963233bf159 100644
--- a/Mk/Uses/qt-dist.mk
+++ b/Mk/Uses/qt-dist.mk
@@ -64,7 +64,6 @@ LICENSE?= LGPL21
DESCR?= ${PORTSDIR}/devel/${_QT_RELNAME}/pkg-descr
. endif
-
# Stage support.
_QT5_DESTDIRNAME= INSTALL_ROOT
_QT6_DESTDIRNAME= DESTDIR
@@ -286,12 +285,11 @@ PLIST_SUB+= SHORTVER=${_QT_VERSION:R} \
FULLVER=${_QT_VERSION:C/-.*//}
# Handle additional PLIST directories, which should only be used for Qt-dist ports.
-. for dir in CMAKE ETC
-# Export QT_CMAKEDIR and QT_ETCDIR.
+. for dir in ETC
+# Export QT_ETCDIR.
PLIST_SUB+= QT_${dir}DIR="${QT_${dir}DIR_REL}"
. endfor
-
. if ${_QT_VER:M5}
. if ${_QT_DIST} == "base"
# qtbase requires some tools to be symlinked to the build directory.
@@ -376,6 +374,7 @@ _QMAKE= ${CONFIGURE_WRKSRC}/bin/qmake
. endif
. endif
+
pre-configure: qt5-pre-configure
qt5-pre-configure:
# Qt 5.3.2 introduced a check in mkspecs/features/create_cmake.prf that
@@ -492,6 +491,16 @@ qt-post-install:
. endif # ${QT_CONFIG:N-*}
. endif # M5
+. if ${_QT_VER:M6}
+post-stage: qt6-post-stage
+# Clean-up of empty directories, as we install
+# * cmake to ${LOCALBASE}/lib/cmake not ${QT_LIBDIR}/cmake.
+# * pkgconfig to ${LOCALBASE}/libexec/pkgconfig not ${QT_LIBDIR}/pkgconfig
+qt6-post-stage:
+ ${RM} -r ${STAGEDIR}${QT_LIBDIR}/cmake
+ ${RM} -r ${STAGEDIR}${QT_LIBDIR}/pkgconfig
+. endif
+
qt-create-kde-distfile:
${SH} ${PORTSDIR}/devel/${_QT_RELNAME}/files/create_kde-qt_release.sh \
${_QT_DIST} \