New port: misc/qt5-doc

This port builds and installs the Qt5 API documentation for use
with IDEs such as qtcreator or kdevelop in qch file format and HTML
file format.

Limitations: The port is made for Qt 5.5.1 and excludes the
documentation for qtwebkit, qtwebkit-examples and qtwebengine. The
reasons are, webkit is deprecated and should not be used for further
development, it will not be part of the Qt 5.6.x sources by default
and only provided on FreeBSD for backwards compatibility with ports.
API documentation may be later added to the qt5-webkit port (as
well for qtwebkit-examples). The qtwebengine hasn't been ported to
FreeBSD yet, so no documenation can be generated either.

The build process uses the full qt source tarball and uses configure
with the respective platform (freebsd-g++ or freebsd-clang). During
configure, the qmake tool is compiled that generates the Makefiles
for doc creation. While the qt5-qmake could also be used, it currently
generates the documentation without the correct links and replaces
them with text, which makes the API documentation useless with
respect to the workflow. The compiling of qmake has been accepted
for now as a minor drawback of the port.

PR:		209861
Submitted by:	Ralf Nolden <nolden@kde.org> (kde)
This commit is contained in:
Kurt Jaeger 2016-05-31 18:02:42 +00:00
parent 1046f6f6c8
commit 97b7725f31
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=416213
4 changed files with 11638 additions and 0 deletions

View file

@ -393,6 +393,7 @@
SUBDIR += qt4-l10n
SUBDIR += qt4-qtconfig
SUBDIR += qt4-qtdemo
SUBDIR += qt5-doc
SUBDIR += qt5-examples
SUBDIR += qt5-l10n
SUBDIR += qt5ct

69
misc/qt5-doc/Makefile Normal file
View file

@ -0,0 +1,69 @@
# Created by: Ralf Nolden <nolden@kde.org>
# $FreeBSD$
PORTNAME= doc
DISTVERSION= ${QT5_VERSION}
CATEGORIES= misc
MASTER_SITES= QT/${QT5_BRANCH}/qt/${QT5_VERSION:R}/${QT5_VERSION}/${QT5_SUBDIR}
PKGNAMEPREFIX= qt5-
DISTNAME= qt-everywhere-opensource-src-${QT5_VERSION}
DIST_SUBDIR= KDE/Qt/${QT5_VERSION}
MAINTAINER= kde@FreeBSD.org
COMMENT= Qt 5 documentation
NO_ARCH= yes
USE_QT5= help_build qdoc_build sql_build sql-sqlite3_build \
buildtools_build qmake_build
USES= compiler:c++11-lib python:build tar:xz
HAS_CONFIGURE= yes
CONFIGURE_OUTSOURCE= yes
QT_NONSTANDARD= yes
CONFIGURE_ARGS= -opensource -confirm-license -developer-build -nomake tests
.include <bsd.port.pre.mk>
# If we are on a system without gcc make qmake use the internal freebsd-clang
# mkspec.
.if ${COMPILER_TYPE:Mclang}
CONFIGURE_ARGS+= -platform unsupported/freebsd-clang
.endif
EXTRACT_AFTER_ARGS?= ${DISTNAME:S,$,/qtwebkit,:S,^,--exclude ,} \
${DISTNAME:S,$,/qtwebkit-examples,:S,^,--exclude ,} \
${DISTNAME:S,$,/qtwebengine,:S,^,--exclude ,}
DOCSDIR= ${PREFIX}/share/doc/qt5
MAKE_JOBS_UNSAFE= YES
ALL_TARGET= docs
DESCR= ${.CURDIR:H:H}/devel/qt5/pkg-descr
post-extract:
${MKDIR} ${BUILD_WRKSRC}/qtbase/bin
${LN} -sf ${MOC} ${BUILD_WRKSRC}/qtbase/bin/moc
${LN} -sf ${UIC} ${BUILD_WRKSRC}/qtbase/bin/uic
${LN} -sf ${RCC} ${BUILD_WRKSRC}/qtbase/bin/rcc
${LN} -sf ${QT_BINDIR}/qdoc ${BUILD_WRKSRC}/qtbase/bin/qdoc
${LN} -sf ${QT_BINDIR}/qhelpgenerator ${BUILD_WRKSRC}/qtbase/bin/qhelpgenerator
post-patch:
# qtdeclarative.pro wants to run python, replace that with PYTHON_CMD
${REINPLACE_CMD} '/py_out/s#python#${PYTHON_CMD}#g' \
${WRKSRC}/qtdeclarative/qtdeclarative.pro
# Make mkspecs/freebsd-g++ use the correct gcc for the build.
.if ${COMPILER_TYPE:Mgcc}
${REINPLACE_CMD} -e 's#gcc#${CC}#g' \
-e 's#g++#${CXX}#g' \
${PATCH_WRKSRC}/qtbase/mkspecs/common/g++-base.conf
.endif
do-install:
${MKDIR} ${STAGEDIR}${DOCSDIR} && \
cd ${BUILD_WRKSRC}/qtbase/doc && \
${COPYTREE_SHARE} \* ${STAGEDIR}${DOCSDIR}
.include <bsd.port.post.mk>

3
misc/qt5-doc/distinfo Normal file
View file

@ -0,0 +1,3 @@
TIMESTAMP = 1464515376
SHA256 (KDE/Qt/5.5.1/qt-everywhere-opensource-src-5.5.1.tar.xz) = 6f028e63d4992be2b4a5526f2ef3bfa2fe28c5c757554b11d9e8d86189652518
SIZE (KDE/Qt/5.5.1/qt-everywhere-opensource-src-5.5.1.tar.xz) = 320459924

11565
misc/qt5-doc/pkg-plist Normal file

File diff suppressed because it is too large Load diff