summaryrefslogtreecommitdiff
path: root/x11/qt3-libs
diff options
context:
space:
mode:
authorskrll <skrll@pkgsrc.org>2002-05-29 19:09:55 +0000
committerskrll <skrll@pkgsrc.org>2002-05-29 19:09:55 +0000
commit0654af6a3ceefade5c7bc444bab5d006081d6cf7 (patch)
tree8df4793c06467f22851cfd641d42319c0c58af54 /x11/qt3-libs
parent82104f6d023ae99eacc8d4e5a9ef5023792303cc (diff)
downloadpkgsrc-0654af6a3ceefade5c7bc444bab5d006081d6cf7.tar.gz
Various changes to help with KDE3.
o Enable thread support using pth-syscall and nathanw_sa. The later has problems which are being worked on. o Restructure the build of certain plugins so that qt3-libs comes with jpeg and mng support. o Introduce a BUILDLINK_DEPENDS_METHOD.qt3-tools variable that when set to build means we don't get a full dependency on qt3-tools.
Diffstat (limited to 'x11/qt3-libs')
-rw-r--r--x11/qt3-libs/Makefile17
-rw-r--r--x11/qt3-libs/Makefile.common10
-rw-r--r--x11/qt3-libs/PLIST19
-rw-r--r--x11/qt3-libs/buildlink.mk4
-rw-r--r--x11/qt3-libs/distinfo4
-rw-r--r--x11/qt3-libs/files/qmake.conf13
-rw-r--r--x11/qt3-libs/patches/patch-aa13
-rw-r--r--x11/qt3-libs/patches/patch-ad28
8 files changed, 76 insertions, 32 deletions
diff --git a/x11/qt3-libs/Makefile b/x11/qt3-libs/Makefile
index 5cfe5c1dc22..383eeb45179 100644
--- a/x11/qt3-libs/Makefile
+++ b/x11/qt3-libs/Makefile
@@ -1,15 +1,21 @@
-# $NetBSD: Makefile,v 1.4 2002/05/24 01:15:39 dmcmahill Exp $
+# $NetBSD: Makefile,v 1.5 2002/05/29 19:09:55 skrll Exp $
#
.include "../qt3-libs/Makefile.common"
PKGNAME= qt3-libs-${QTVERSION}
+PKGREVISION= 1
COMMENT= C++ X GUI toolkit
USE_BUILDLINK_ONLY= yes
BUILDLINK_QTDIR= ${WRKSRC}
-ALL_TARGET= sub-src
+MAKE_ENV+= LIBQT="${WRKSRC}/lib/libqt-mt.la"
+
+ALL_TARGET= sub-plugins
+
+USE_PTHREAD= native pth-syscall
+.include "../../mk/bsd.prefs.mk"
UNLIMIT_RESOURCES= datasize
@@ -21,16 +27,21 @@ do-install:
${INSTALL_PROGRAM_DIR} ${QTPREFIX}/bin
${INSTALL_PROGRAM} ${WRKSRC}/bin/moc ${QTPREFIX}/bin
${INSTALL_DATA_DIR} ${QTPREFIX}/lib
- ${LIBTOOL} ${INSTALL_DATA} ${WRKSRC}/lib/libqt.la ${QTPREFIX}/lib
+ ${LIBTOOL} ${INSTALL_DATA} ${WRKSRC}/lib/libqt-mt.la ${QTPREFIX}/lib
${INSTALL_DATA_DIR} ${QTPREFIX}/include
${INSTALL_DATA} ${WRKSRC}/include/*.h ${QTPREFIX}/include
${INSTALL_DATA_DIR} ${QTPREFIX}/include/private
${INSTALL_DATA} ${WRKSRC}/include/private/*.h ${QTPREFIX}/include/private
+ ${INSTALL_DATA_DIR} ${QTPREFIX}/plugins
+ ${INSTALL_DATA_DIR} ${QTPREFIX}/plugins/imageformats
+ ${LIBTOOL} ${INSTALL_DATA} ${WRKSRC}/plugins/imageformats/libqjpeg.la ${QTPREFIX}/plugins/imageformats
+ ${LIBTOOL} ${INSTALL_DATA} ${WRKSRC}/plugins/imageformats/libqmng.la ${QTPREFIX}/plugins/imageformats
.include "../../devel/zlib/buildlink.mk"
.include "../../graphics/jpeg/buildlink.mk"
.include "../../graphics/Mesa/buildlink.mk"
.include "../../graphics/mng/buildlink.mk"
.include "../../graphics/png/buildlink.mk"
+.include "../../mk/pthread.buildlink.mk"
.include "../../mk/x11.buildlink.mk"
.include "../../mk/bsd.pkg.mk"
diff --git a/x11/qt3-libs/Makefile.common b/x11/qt3-libs/Makefile.common
index b2a8a71201b..fb69f91ff8f 100644
--- a/x11/qt3-libs/Makefile.common
+++ b/x11/qt3-libs/Makefile.common
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile.common,v 1.4 2002/05/04 13:30:10 drochner Exp $
+# $NetBSD: Makefile.common,v 1.5 2002/05/29 19:09:55 skrll Exp $
#
DISTNAME= qt-x11-free-${QTVERSION}
CATEGORIES= x11
@@ -12,7 +12,7 @@ HAS_CONFIGURE= yes
USE_X11BASE= yes
USE_GMAKE= yes
USE_LIBTOOL= yes
-CONFIGURE_ARGS+= -shared -sm -no-thread \
+CONFIGURE_ARGS+= -shared -sm -thread \
-system-zlib -system-libpng \
-system-libmng -system-libjpeg
CONFIGURE_ARGS+= -no-xinerama
@@ -26,6 +26,12 @@ CONFIGURE_ENV+= QTDIR="${WRKSRC}"
MAKE_ENV+= QTPREFIX=${QTPREFIX}
MAKE_ENV+= QTDIR="${WRKSRC}"
+#
+# A cheat so that we don't have to set QTDIR at run-time to find the
+# plugins.
+#
+CXXFLAGS+= -DQT_INSTALL_PLUGINS=\\"${QTPREFIX}/plugins\\"
+
DISTINFO_FILE= ${.CURDIR}/../../x11/qt3-libs/distinfo
FILESDIR= ${.CURDIR}/../../x11/qt3-libs/files
PATCHDIR= ${.CURDIR}/../../x11/qt3-libs/patches
diff --git a/x11/qt3-libs/PLIST b/x11/qt3-libs/PLIST
index 6ee9a59cdf2..340b89691ed 100644
--- a/x11/qt3-libs/PLIST
+++ b/x11/qt3-libs/PLIST
@@ -1,4 +1,4 @@
-@comment $NetBSD: PLIST,v 1.3 2002/05/04 13:30:10 drochner Exp $
+@comment $NetBSD: PLIST,v 1.4 2002/05/29 19:09:55 skrll Exp $
qt3/bin/moc
qt3/include/jri.h
qt3/include/jri_md.h
@@ -374,11 +374,18 @@ qt3/include/qwmatrix.h
qt3/include/qworkspace.h
qt3/include/qxml.h
qt3/include/qxt.h
-qt3/lib/libqt.a
-qt3/lib/libqt.la
-qt3/lib/libqt.so
-qt3/lib/libqt.so.3
-qt3/lib/libqt.so.3.0
+qt3/lib/libqt-mt.a
+qt3/lib/libqt-mt.la
+qt3/lib/libqt-mt.so
+qt3/lib/libqt-mt.so.3
+qt3/lib/libqt-mt.so.3.0
+qt3/plugins/imageformats/libqjpeg.a
+qt3/plugins/imageformats/libqjpeg.la
+qt3/plugins/imageformats/libqjpeg.so
+qt3/plugins/imageformats/libqmng.a
+qt3/plugins/imageformats/libqmng.la
+qt3/plugins/imageformats/libqmng.so
+@dirrm qt3/plugins/imageformats
@dirrm qt3/lib
@dirrm qt3/include/private
@dirrm qt3/include
diff --git a/x11/qt3-libs/buildlink.mk b/x11/qt3-libs/buildlink.mk
index ec57636a779..fc0119dd5a7 100644
--- a/x11/qt3-libs/buildlink.mk
+++ b/x11/qt3-libs/buildlink.mk
@@ -17,7 +17,7 @@ QT3_LIBS_BUILDLINK_MK= # defined
.include "../../mk/bsd.buildlink.mk"
-BUILDLINK_DEPENDS.qt3-libs?= qt3-libs>=3.0.2
+BUILDLINK_DEPENDS.qt3-libs?= qt3-libs>=3.0.4nb1
DEPENDS+= ${BUILDLINK_DEPENDS.qt3-libs}:../../x11/qt3-libs
EVAL_PREFIX+= BUILDLINK_PREFIX.qt3-libs=qt3-libs
@@ -25,7 +25,7 @@ BUILDLINK_PREFIX.qt3-libs_DEFAULT= ${X11PREFIX}
BUILDLINK_FILES.qt3-libs= qt3/bin/moc
BUILDLINK_FILES.qt3-libs+= qt3/include/*.h
BUILDLINK_FILES.qt3-libs+= qt3/include/private/*.h
-BUILDLINK_FILES.qt3-libs+= qt3/lib/libqt.*
+BUILDLINK_FILES.qt3-libs+= qt3/lib/libqt-mt.*
REAL_QTDIR= ${BUILDLINK_PREFIX.qt3-libs}/qt3
BUILDLINK_QTDIR= ${BUILDLINK_DIR}/qt3
diff --git a/x11/qt3-libs/distinfo b/x11/qt3-libs/distinfo
index 6ac071c73d8..6a81a7120cc 100644
--- a/x11/qt3-libs/distinfo
+++ b/x11/qt3-libs/distinfo
@@ -1,7 +1,7 @@
-$NetBSD: distinfo,v 1.4 2002/05/04 13:30:10 drochner Exp $
+$NetBSD: distinfo,v 1.5 2002/05/29 19:09:55 skrll Exp $
SHA1 (qt-x11-free-3.0.4.tar.gz) = 1bed903c622009fbbcce8386bb1b48b4202f3dbb
Size (qt-x11-free-3.0.4.tar.gz) = 15198015 bytes
-SHA1 (patch-aa) = 494c78ec6f70fa656584887e289915b41a6b7245
SHA1 (patch-ab) = 8842f4ef5d3464d3a588c20d0ef5b0bb40d48180
SHA1 (patch-ac) = da32dd8596f36238fec30fb7b8a444d36e13ed92
+SHA1 (patch-ad) = 197ba1f217635ad0b25d4709d0be9786ade079cc
diff --git a/x11/qt3-libs/files/qmake.conf b/x11/qt3-libs/files/qmake.conf
index 87a0382c63b..af26c2512e0 100644
--- a/x11/qt3-libs/files/qmake.conf
+++ b/x11/qt3-libs/files/qmake.conf
@@ -1,5 +1,5 @@
#
-# $Id: qmake.conf,v 1.1.1.1 2002/01/07 08:07:59 skrll Exp $
+# $Id: qmake.conf,v 1.2 2002/05/29 19:09:55 skrll Exp $
#
# qmake configuration for netbsd-g++
#
@@ -50,8 +50,11 @@ QMAKE_LINK_SHLIB_CMD = \
$(if $(TARGET0), \
-version-info $(subst $(TARGET0).,,$(TARGET1)):$(subst $(TARGET1).,,$(TARGET2)), \
-module -avoid-version) \
- $(OBJECTS:.o=.lo) $(OBJMOC:.o=.lo) $(LIBS) -rpath $(QTPREFIX)
-QMAKE_LFLAGS = @LDFLAGS@
+ $(OBJECTS:.o=.lo) $(OBJMOC:.o=.lo) $(LIBS) \
+ -rpath $(if $(TARGET0), \
+ $(QTPREFIX)/lib, \
+ $(subst ../../..,$(QTPREFIX)/plugins,$(DESTDIR)))
+QMAKE_LFLAGS = @LDFLAGS@ -L$(QTDIR)/lib
QMAKE_LFLAGS_RELEASE =
QMAKE_LFLAGS_DEBUG =
QMAKE_LFLAGS_SHLIB =
@@ -68,7 +71,9 @@ QMAKE_LIBS =
QMAKE_LIBS_DYNLOAD =
QMAKE_LIBS_X11 = -lXext -lX11 -lm
QMAKE_LIBS_X11SM = -lICE -lSM
-QMAKE_LIBS_QT = -lqt
+QMAKE_LIBS_QT = $(LIBQT)
+QMAKE_LIBS_QT_THREAD = $(LIBQT)
+QMAKE_LIBS_THREAD = -lpthread
QMAKE_LIBS_OPENGL = -lGLU -lGL -lXmu
QMAKE_LIBS_OPENGL_QT = -lGL -lXmu
diff --git a/x11/qt3-libs/patches/patch-aa b/x11/qt3-libs/patches/patch-aa
deleted file mode 100644
index 062011360ef..00000000000
--- a/x11/qt3-libs/patches/patch-aa
+++ /dev/null
@@ -1,13 +0,0 @@
-$NetBSD: patch-aa,v 1.2 2002/05/04 13:30:10 drochner Exp $
-
---- Makefile.orig Mon Mar 18 05:58:44 2002
-+++ Makefile Fri May 3 17:38:21 2002
-@@ -63,7 +63,7 @@
- cd plugins/src && $(MAKE) uninstall
- plugins-install: sub-plugins
- cd plugins/src && $(MAKE) install
--sub-plugins: sub-src .qmake.cache FORCE
-+sub-plugins: .qmake.cache FORCE
- cd plugins/src && $(MAKE)
-
- #tutorials
diff --git a/x11/qt3-libs/patches/patch-ad b/x11/qt3-libs/patches/patch-ad
new file mode 100644
index 00000000000..c00ab0b972f
--- /dev/null
+++ b/x11/qt3-libs/patches/patch-ad
@@ -0,0 +1,28 @@
+$NetBSD: patch-ad,v 1.1 2002/05/29 19:09:56 skrll Exp $
+
+--- src/kernel/qthread_unix.cpp.orig Fri May 24 16:43:12 2002
++++ src/kernel/qthread_unix.cpp
+@@ -87,6 +87,7 @@
+ // helpers
+ #define Q_THREAD_SELF() pthread_self()
+ #define Q_THREAD_EXIT(a) pthread_exit((a))
++#if defined(_POSIX_THREAD_PRIORITY_SCHEDULING)
+ #define Q_THREAD_CREATE(a) pthread_attr_t attr; \
+ pthread_attr_init(&attr); \
+ pthread_attr_setinheritsched(&attr, PTHREAD_INHERIT_SCHED); \
+@@ -94,6 +95,15 @@
+ (a) = pthread_create(&thread_id, &attr, start_thread, \
+ (void *) that); \
+ pthread_attr_destroy(&attr);
++#else
++#define Q_THREAD_CREATE(a) pthread_attr_t attr; \
++ pthread_attr_init(&attr); \
++ pthread_attr_setdetachstate(&attr, PTHREAD_CREATE_DETACHED); \
++ (a) = pthread_create(&thread_id, &attr, start_thread, \
++ (void *) that); \
++ pthread_attr_destroy(&attr);
++#endif
++
+ #endif // Q_OS_SOLARIS
+
+