Reorganize stuff.

- stop supporting !mt, since it has worked for a long time.
- mt becomes a pseudo_flavor for compat purposes.
- merge base back into the main module.
- link mt names to not mt names.
- finish recreating a full QTDIR structure for compatibility as well.
This commit is contained in:
espie 2004-10-30 09:12:35 +00:00
parent 997b0c0113
commit fa73104d38
17 changed files with 1537 additions and 1637 deletions

View File

@ -1,4 +1,4 @@
# $OpenBSD: Makefile,v 1.41 2004/10/27 19:57:16 espie Exp $
# $OpenBSD: Makefile,v 1.42 2004/10/30 09:12:35 espie Exp $
# $FreeBSD: Makefile,v 1.33 1999/02/27 03:09:57 andreas Exp $
COMMENT= "C++ X11 GUI toolkit"
@ -6,13 +6,11 @@ COMMENT-examples= "examples and tutorial for qt3"
COMMENT-html= "off-line html documentation for qt3"
COMMENT-postgresql= "PostgresSQL plugin for qt3"
COMMENT-mysql= "MySQL plugin for qt3"
COMMENT-base= "include and docs for qt3"
PKGNAME= qt3-${VERSION}p2
PKGNAME= qt3-${VERSION}p3
PKGNAME-mysql= qt3-mysql-${VERSION}
PKGNAME-postgresql= qt3-postgresql-${VERSION}
PKGNAME-examples= qt3-examples-${VERSION}
FULLPKGNAME-base= qt3-base-${VERSION}
FULLPKGNAME-html= qt3-html-${VERSION}
VERSION= 3.3
@ -24,11 +22,10 @@ HOMEPAGE= http://www.trolltech.com/qt/
MAINTAINER= Marc Espie <espie@openbsd.org>
FLAVORS=mt debug
FLAVORS=debug
PSEUDO_FLAVORS= no_mysql no_postgresql no_examples
FLAVOR?=mt
COMPAT=Yes
PSEUDO_FLAVORS= no_mysql no_postgresql no_examples mt
FLAVOR?=
# GPL/QPL
PERMIT_PACKAGE_CDROM= Yes
@ -36,8 +33,6 @@ PERMIT_PACKAGE_FTP= Yes
PERMIT_DISTFILES_CDROM= Yes
PERMIT_DISTFILES_FTP= Yes
PKG_ARGS=-Dcompat=1
USE_X11= Yes
MAKE_ENV= QTDIR="${WRKDIST}" EXTRA_SAMPLES="${EXTRA_SAMPLES}" \
SYS_CXX="${CXX}" SYS_CXXFLAGS="${CXXFLAGS}" \
@ -60,7 +55,7 @@ CONFIGURE_ARGS= -qt-gif -system-libmng -system-libpng -system-libjpeg -system-zl
-L${WRKSRC}/lib \
-L${LOCALBASE}/lib
MULTI_PACKAGES+=-base -html
MULTI_PACKAGES+=-html
.if ${FLAVOR:L:Mdebug}
CONFIGURE_ARGS+=-debug
@ -69,14 +64,10 @@ PKGDEBUG=-debug
PKGDEBUG=
.endif
.if ${FLAVOR:L:Mmt}
FULLPKGNAME= qt3-mt-${VERSION}p2${PKGDEBUG}
FULLPKGNAME= qt3-mt-${VERSION}p3${PKGDEBUG}
CONFIGURE_ARGS+=-thread
.else
CONFIGURE_ARGS+=-no-thread
.endif
.if ${FLAVOR:L:Mmt} && !${FLAVOR:L:Mdebug} && !${FLAVOR:L:Mno_examples}
.if !${FLAVOR:L:Mdebug} && !${FLAVOR:L:Mno_examples}
MULTI_PACKAGES+= -examples
.else
ALL_TARGET=sub-src sub-tools
@ -100,9 +91,6 @@ e:=$e,no_mysql
.if ${FLAVOR:L:Mno_postgresql}
e:=$e,no_postgresql
.endif
.if ${FLAVOR:L:Mmt}
e:=$e,mt
.endif
.if !empty(FLAVOR:L:Mno_mysql)
CONFIGURE_ARGS+=-no-sql-mysql
@ -129,17 +117,13 @@ CONFIGURE_ARGS+= -I${LOCALBASE}/include/postgresql \
-I${LOCALBASE}/include -plugin-sql-psql
.endif
.if defined(PACKAGING) && ${SUBPACKAGE} != "-html" && ${SUBPACKAGE} != "-base"
RUN_DEPENDS+=::x11/qt3,-base
.endif
.if !defined(PACKAGING) || ${SUBPACKAGE} != "-html" && ${SUBPACKAGE} != "-base"
.if !defined(PACKAGING) || ${SUBPACKAGE} != "-html"
LIB_DEPENDS+= png.2::graphics/png \
mng.1::graphics/libmng
.endif
.if defined(PACKAGING) && ${SUBPACKAGE} != "-html" && ${SUBPACKAGE} != "" && ${SUBPACKAGE} != "-base"
LIB_DEPENDS+= qt${MT_SUFX}.3::x11/qt3$e
.if defined(PACKAGING) && ${SUBPACKAGE} != "-html" && ${SUBPACKAGE} != ""
LIB_DEPENDS+= qt-mt.3::x11/qt3$e
.endif
.if defined(PACKAGING) && ${SUBPACKAGE} == "-html"
@ -153,11 +137,11 @@ QT_MANDIR= ${QT_LIBDIR}/man
QT_EXAMPLES= ${QT_LIBDIR}/examples
QT_TUTORIAL= ${QT_LIBDIR}/tutorial
QT_DOC= ${PREFIX}/share/doc/qt3
QT_PLUGINSDIR= ${QT_LIBDIR}/plugins${MT_SUFX}
QT_BINDIR= ${QT_LIBDIR}/bin${MT_SUFX}
QT_PLUGINSDIR= ${QT_LIBDIR}/plugins
QT_BINDIR= ${QT_LIBDIR}/bin
# for manpages in MESSAGE
SUBST_VARS= VERSION QT_LIBDIR QT_DOC MT_SUFX
SUBST_VARS= QT_LIBDIR QT_DOC
DOCS= FAQ LICENSE.GPL README README-QT.TXT \
changes-3*
@ -168,16 +152,10 @@ NO_REGRESS= Yes
PROGRAMS3=designer findtr moc qt20fix qtrename140 uic
PROGRAMS=assistant linguist lrelease lupdate qm2ts qmake qtconfig
LIBRARIES=qt${MT_SUFX}.so.3.33 qui${MT_SUFX}.so.1.0 \
LIBRARIES=qt-mt.so.3.33 qui.so.1.0 \
editor.a designercore.a qassistantclient.a
.if ${FLAVOR:L:Mmt}
MT_SUFX=-mt
.else
MT_SUFX=
.endif
.if ${FLAVOR:L:Mmt} && !${FLAVOR:L:Mdebug}
.if !${FLAVOR:L:Mdebug}
post-configure:
@cd ${WRKSRC} && cp -R examples examples-src
@find ${WRKSRC}/examples-src -name '*.orig' |xargs rm
@ -249,11 +227,11 @@ do-install:
.endfor
.for p in ${PROGRAMS3}
${INSTALL_PROGRAM} ${WRKBUILD}/bin/$p ${QT_BINDIR}/$p
@ln -sf ${TRUEPREFIX}/lib/qt3/bin${MT_SUFX}/$p ${PREFIX}/bin/$p3${MT_SUFX}
@ln -sf ${TRUEPREFIX}/lib/qt3/bin/$p ${PREFIX}/bin/$p3
.endfor
.for p in ${PROGRAMS}
${INSTALL_PROGRAM} ${WRKBUILD}/bin/$p ${QT_BINDIR}/$p
@ln -sf ${TRUEPREFIX}/lib/qt3/bin${MT_SUFX}/$p ${PREFIX}/bin/$p${MT_SUFX}
@ln -sf ${TRUEPREFIX}/lib/qt3/bin/$p ${PREFIX}/bin/$p
.endfor
# plugins
${INSTALL_DATA_DIR} ${QT_PLUGINSDIR}/designer \
@ -274,16 +252,19 @@ do-install:
${QT_PLUGINSDIR}/designer
${INSTALL_DATA} ${WRKBUILD}/plugins/designer/librcplugin.so \
${QT_PLUGINSDIR}/designer
.if ${COMPAT:L} == "yes" && ${FLAVOR:L:Mmt}
# compatibility transition
.for p in ${PROGRAMS}
cd ${PREFIX}/bin && ln -sf $p${MT_SUFX} $p
cd ${PREFIX}/bin && ln -sf $p $p-mt
. endfor
.for p in ${PROGRAMS3}
cd ${PREFIX}/bin && ln -sf $p3${MT_SUFX} $p3
cd ${PREFIX}/bin && ln -sf $p3 $p3-mt
.endfor
cd ${PREFIX}/lib && ln -sf libqui${MT_SUFX}.so.1.0 libqui.so.1.0
cd ${PREFIX}/lib/qt3 && ln -sf libqui${MT_SUFX}.so.1.0 libqui.so.1.0
.endif
cd ${PREFIX}/lib/qt3 && ln -sf bin${MT_SUFX} bin
cd ${PREFIX}/lib && ln -sf libqui.so.1.0 libqui-mt.so.1.0
cd ${PREFIX}/lib/qt3 && ln -sf libqui.so.1.0 libqui-mt.so.1.0
# links for qtdir
cd ${PREFIX}/lib/qt3 && ln -sf . lib
cd ${PREFIX}/lib/qt3 && ln -sf ../../include/X11/qt3 include
# fix for qmake
${INSTALL_DATA} ${WRKBUILD}/.qmake.cache ${PREFIX}/lib/qt3
.include <bsd.port.mk>

View File

@ -1,13 +0,0 @@
$OpenBSD: patch-tools_designer_app_app_pro,v 1.3 2004/07/22 23:03:09 brad Exp $
--- tools/designer/app/app.pro.orig 2004-01-16 17:51:08.000000000 -0700
+++ tools/designer/app/app.pro 2004-06-19 19:37:35.000000000 -0600
@@ -6,7 +6,8 @@ DESTDIR = $$QT_BUILD_TREE/bin
SOURCES += main.cpp
INCLUDEPATH += ../designer
-LIBS += -ldesignercore -lqui -lqassistantclient -L$$QT_BUILD_TREE/lib
+thread:LIBS += -ldesignercore -lqui-mt -lqassistantclient -L$$QT_BUILD_TREE/lib
+!thread:LIBS += -ldesignercore -lqui -lqassistantclient -L$$QT_BUILD_TREE/lib
win32 {
RC_FILE = designer.rc
win32-g++ {

View File

@ -1,13 +0,0 @@
$OpenBSD: patch-tools_designer_designer_designer_pro,v 1.5 2004/07/22 23:03:09 brad Exp $
--- tools/designer/designer/designer.pro.orig 2004-03-31 00:21:33.000000000 -0700
+++ tools/designer/designer/designer.pro 2004-06-19 19:37:35.000000000 -0600
@@ -419,7 +419,8 @@ table {
}
INCLUDEPATH += ../shared ../uilib
-LIBS += -L$$QT_BUILD_TREE/lib -lqui
+thread:LIBS += -L$$QT_BUILD_TREE/lib -lqui-mt
+!thread:LIBS += -L$$QT_BUILD_TREE/lib -lqui
hpux-acc* {
LIBS += $$QT_BUILD_TREE/lib/libqassistantclient.a

View File

@ -1,13 +0,0 @@
$OpenBSD: patch-tools_designer_examples_receiver1_receiver_pro,v 1.3 2004/07/22 23:03:09 brad Exp $
--- tools/designer/examples/receiver1/receiver.pro.orig 2003-10-31 07:36:28.000000000 -0700
+++ tools/designer/examples/receiver1/receiver.pro 2004-06-19 19:37:35.000000000 -0600
@@ -4,7 +4,8 @@ TARGET = receiver
CONFIG += qt warn_on release
INCLUDEPATH += $$QT_SOURCE_TREE/tools/designer/uilib
-LIBS += -lqui
+thread:LIBS += -lqui-mt
+!thread:LIBS += -lqui
SOURCES += main.cpp
IMAGEFILE = images.cpp
FORMS = mainform.ui

View File

@ -1,13 +0,0 @@
$OpenBSD: patch-tools_designer_examples_receiver2_receiver_pro,v 1.3 2004/07/22 23:03:09 brad Exp $
--- tools/designer/examples/receiver2/receiver.pro.orig Fri Oct 31 07:36:28 2003
+++ tools/designer/examples/receiver2/receiver.pro Sat Jun 19 19:33:29 2004
@@ -4,7 +4,8 @@ TARGET = receiver
CONFIG += qt warn_on release
INCLUDEPATH += $$QT_SOURCE_TREE/tools/designer/uilib
-LIBS += -lqui
+thread:LIBS += -lqui-mt
+!thread:LIBS += -lqui
SOURCES += main.cpp receiver.cpp
HEADERS += receiver.h
FORMS = mainform.ui

View File

@ -1,11 +0,0 @@
$OpenBSD: patch-tools_designer_uilib_test_test_pro,v 1.2 2004/01/08 01:23:57 brad Exp $
--- tools/designer/uilib/test/test.pro.orig 2003-05-15 03:42:30.000000000 -0400
+++ tools/designer/uilib/test/test.pro 2003-11-11 18:22:55.000000000 -0500
@@ -3,5 +3,6 @@ CONFIG += qt warn_on release
HEADERS =
SOURCES = main.cpp
TARGET = test
-LIBS += -L$$QT_BUILD_TREE/lib -lqui
+thread:LIBS += -L$$QT_BUILD_TREE/lib -lqui-mt
+!thread:LIBS += -L$$QT_BUILD_TREE/lib -lqui

View File

@ -1,14 +0,0 @@
$OpenBSD: patch-tools_designer_uilib_uilib_pro,v 1.2 2004/01/08 01:23:57 brad Exp $
--- tools/designer/uilib/uilib.pro.orig 2003-05-13 03:08:54.000000000 -0400
+++ tools/designer/uilib/uilib.pro 2003-11-11 18:24:19.000000000 -0500
@@ -15,7 +15,9 @@ sql:HEADERS += ../designer/database2.
DEFINES += QT_INTERNAL_XML
!win32-borland:DEFINES += Q_TEMPLATE_EXTERN=extern
include( ../../../src/qt_professional.pri )
-TARGET = qui
+thread:TARGET = qui-mt
+!thread:TARGET = qui
+
INCLUDEPATH += ../shared
DESTDIR = ../../../lib
VERSION = 1.0.0

View File

@ -13,17 +13,17 @@ should note that qt3's installation conforms to OpenBSD habits, not
TrollTech's recommendations.
Accordingly:
- libs are separated from includes.
- moc is installed as ${PREFIX}/bin/moc3${MT_SUFX}, in order not to conflict
- moc is installed as ${PREFIX}/bin/moc3, in order not to conflict
with other qt versions.
- uic is installed as ${PREFIX}/bin/uic3${MT_SUFX}
- uic is installed as ${PREFIX}/bin/uic3
Generally, it's just a question of invoking
env MOC=moc3${MT_SUFX} UIC=uic3${MT_SUFX} configure --with-qt-includes=${PREFIX}/include/X11/qt3
env MOC=moc3 UIC=uic3 configure --with-qt-includes=${PREFIX}/include/X11/qt3
--with-qt-libraries=${PREFIX}/lib/qt3
Or to force MOC/UIC in your make/gmake invocation:
make MOC=moc3${MT_SUFX} UIC=uic3${MT_SUFX}
make MOC=moc3 UIC=uic3
will override the Makefile contents.
Warning: the qt3 library also appears under ${PREFIX}/lib, but you

View File

@ -1 +0,0 @@
This is the common include/documentation package for both qt and qt-mt

View File

@ -1,17 +0,0 @@
@comment $OpenBSD: PFRAG.compat,v 1.2 2004/10/27 19:57:16 espie Exp $
@conflict qt3
bin/assistant
bin/designer3
bin/findtr3
bin/linguist
bin/lrelease
bin/lupdate
bin/moc3
bin/qm2ts
bin/qmake
bin/qt20fix3
bin/qtconfig
bin/qtrename1403
bin/uic3
lib/qt3/bin
%%SHARED%%

View File

@ -1,9 +1,11 @@
@comment $OpenBSD: PFRAG.shared,v 1.14 2004/09/15 19:25:12 espie Exp $
@lib lib/libqt${MT_SUFX}.so.${VERSION}3
@lib lib/libqui${MT_SUFX}.so.1.0
@lib lib/qt3/libqt${MT_SUFX}.so.${VERSION}3
@lib lib/qt3/libqui${MT_SUFX}.so.1.0
lib/qt3/plugins${MT_SUFX}/designer/libcppeditor.so
lib/qt3/plugins${MT_SUFX}/designer/libdlgplugin.so
lib/qt3/plugins${MT_SUFX}/designer/librcplugin.so
lib/qt3/plugins${MT_SUFX}/designer/libwizards.so
@comment $OpenBSD: PFRAG.shared,v 1.15 2004/10/30 09:12:35 espie Exp $
@lib lib/libqt-mt.so.3.33
@lib lib/libqui-mt.so.1.0
@lib lib/libqui.so.1.0
@lib lib/qt3/libqt-mt.so.3.33
@lib lib/qt3/libqui-mt.so.1.0
@lib lib/qt3/libqui.so.1.0
lib/qt3/plugins/designer/libcppeditor.so
lib/qt3/plugins/designer/libdlgplugin.so
lib/qt3/plugins/designer/librcplugin.so
lib/qt3/plugins/designer/libwizards.so

View File

@ -1,3 +0,0 @@
@comment $OpenBSD: PFRAG.shared-compat,v 1.1 2004/10/26 22:59:24 espie Exp $
@lib lib/libqui.so.1.0
@lib lib/qt3/libqui.so.1.0

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -1,2 +1,2 @@
@comment $OpenBSD: PLIST-mysql,v 1.3 2004/01/22 21:03:59 espie Exp $
lib/qt3/plugins${MT_SUFX}/sqldrivers/libqsqlmysql.so
@comment $OpenBSD: PLIST-mysql,v 1.4 2004/10/30 09:12:35 espie Exp $
lib/qt3/plugins/sqldrivers/libqsqlmysql.so

View File

@ -1,2 +1,2 @@
@comment $OpenBSD: PLIST-postgresql,v 1.3 2004/01/22 21:03:59 espie Exp $
lib/qt3/plugins${MT_SUFX}/sqldrivers/libqsqlpsql.so
@comment $OpenBSD: PLIST-postgresql,v 1.4 2004/10/30 09:12:35 espie Exp $
lib/qt3/plugins/sqldrivers/libqsqlpsql.so

View File

@ -1,4 +1,4 @@
# $OpenBSD: qt3.port.mk,v 1.1 2004/08/03 09:18:39 espie Exp $
# $OpenBSD: qt3.port.mk,v 1.2 2004/10/30 09:12:35 espie Exp $
MODULES+= gcc3
MODGCC3_ARCHES+=sparc64
@ -9,7 +9,7 @@ MODGCC3_LANGS+= c++
MODQT_LIBDIR= ${LOCALBASE}/lib/qt3
MODQT_INCDIR= ${LOCALBASE}/include/X11/qt3
MODQT_OVERRIDE_UIC?=Yes
MODQT_MT?=No
MODQT_MT?=Yes
MODQT_CONFIGURE_ARGS= --with-qt-includes=${MODQT_INCDIR} \
--with-qt-libraries=${MODQT_LIBDIR}
_MODQT_SETUP= MOC=${MODQT_MOC} \
@ -19,16 +19,14 @@ _MODQT_SETUP= MOC=${MODQT_MOC} \
_MODQT_SETUP+= UIC=${MODQT_UIC}
.endif
.if ${MODQT_MT:L} == "yes"
LIB_DEPENDS+=lib/qt3/qt-mt.3::x11/qt3,mt
# includes are now handled by a subpackage
LIB_DEPENDS+=lib/qt3/qt-mt.3::x11/qt3
# may be needed to find plugins
MODQT_MOC= ${LOCALBASE}/bin/moc3-mt
MODQT_UIC= ${LOCALBASE}/bin/uic3-mt
.else
LIB_DEPENDS+=lib/qt3/qt.3::x11/qt3
MODQT_MOC= ${LOCALBASE}/bin/moc3
MODQT_UIC= ${LOCALBASE}/bin/uic3
MODQT_QTDIR= ${LOCALBASE}/lib/qt3
.if ${MODQT_MT:L} != "yes"
ERRORS+="Fatal: support QTMT only"
.endif
CONFIGURE_ENV+= ${_MODQT_SETUP}