diff options
author | will <will@FreeBSD.org> | 2000-09-17 09:57:06 +0800 |
---|---|---|
committer | will <will@FreeBSD.org> | 2000-09-17 09:57:06 +0800 |
commit | 77776411254643aaba7a51f100c7c6cde1209efb (patch) | |
tree | 935d66e5d29325e5464f8c304257fe3c562fa309 /x11-toolkits/qt33 | |
parent | 7651a20c9f5297294871ea33e4bf87a21bd4ac31 (diff) | |
download | freebsd-ports-gnome-77776411254643aaba7a51f100c7c6cde1209efb.tar.gz freebsd-ports-gnome-77776411254643aaba7a51f100c7c6cde1209efb.tar.zst freebsd-ports-gnome-77776411254643aaba7a51f100c7c6cde1209efb.zip |
Add WANT_STATIC option, basically it adds support for compiling a static
library, useful for things like libh. Bump PORTREVISION accordingly.
Submitted by: nra
Diffstat (limited to 'x11-toolkits/qt33')
-rw-r--r-- | x11-toolkits/qt33/Makefile | 23 | ||||
-rw-r--r-- | x11-toolkits/qt33/files/patch-af | 20 |
2 files changed, 41 insertions, 2 deletions
diff --git a/x11-toolkits/qt33/Makefile b/x11-toolkits/qt33/Makefile index 37da249651f1..e8d600075aca 100644 --- a/x11-toolkits/qt33/Makefile +++ b/x11-toolkits/qt33/Makefile @@ -7,6 +7,7 @@ PORTNAME= qt PORTVERSION= 2.2.0 +PORTREVISION= 1 CATEGORIES= x11-toolkits MASTER_SITES= ftp://ftp.trolltech.com/qt/source/ DISTNAME= qt-x11-2.2.0 @@ -28,7 +29,7 @@ CONFIGURE_ARGS= -system-zlib -system-libpng -system-jpeg -sm \ CONFIGURE_ENV= QTDIR=${WRKSRC} MAKE_ENV= QTDIR=${WRKSRC} LD_LIBRARY_PATH=${WRKSRC}/lib -CONFIG= ${WRKSRC}/configs/freebsd-g++-shared +CONFIG= ${WRKSRC}/configs/freebsd-g++-${STATIC} .if defined(QT_GIF_AVAILABLE) || defined(HAVE_UNISYS_LICENSE) CONFIGURE_ARGS+=-gif @@ -39,8 +40,17 @@ RESTRICTED= "Requires a license from UNISYS" .include "${.CURDIR}/files/manpages" .endif +.if defined(WANT_STATIC) +STATIC=static +CONFIGURE_ARGS+=-static +.else +STATIC=shared +INSTALLS_SHLIB=yes +.endif + pre-fetch: .if exists(${X11BASE}/lib/libqt2.so.3) +.if !defined(WANT_STATIC) @${ECHO} "An older version of QT2 is installed. To avoid clobbering" @${ECHO} "that installation, deinstall it and then install this port." @${ECHO} "Note that this port contains beta-quality source code and" @@ -48,6 +58,7 @@ pre-fetch: @${ECHO} "KDE2 snapshot 20000829A and later." @${FALSE} .endif +.endif pre-configure: @${CP} ${CONFIG} ${CONFIG}.new @@ -62,7 +73,7 @@ pre-configure: ${PERL} -pi -e "s@-L../lib@-L${WRKSRC}/lib@g" ${WRKSRC}/tools/designer/uic/Makefile.in post-configure: - @(cd ${WRKSRC} ; ${GMAKE} symlinks) + @(cd ${WRKSRC} && ${SETENV} ${MAKE_ENV} ${GMAKE} symlinks) do-install: ${MKDIR} ${PREFIX}/include/qt2 @@ -92,4 +103,12 @@ do-install: ${INSTALL_MAN} doc/man/man3/q* ${PREFIX}/man/man3 ) .endif +.if defined(WANT_STATIC) +post-install: + @${PERL} -pi -e 's/libqt2\.so/libqt2.a/' ${TMPPLIST} + @${PERL} -pi -e 's/.*libqt2\.a\.\d\n//' ${TMPPLIST} + @${PERL} -pi -e 's/libqutil\.so/libqutil.a/' ${TMPPLIST} + @${PERL} -pi -e 's/.*libqutil\.a\.\d\n//' ${TMPPLIST} +.endif + .include <bsd.port.mk> diff --git a/x11-toolkits/qt33/files/patch-af b/x11-toolkits/qt33/files/patch-af new file mode 100644 index 000000000000..b231b8d9f0be --- /dev/null +++ b/x11-toolkits/qt33/files/patch-af @@ -0,0 +1,20 @@ +--- configs/freebsd-g++-static Sat Sep 16 14:47:56 2000 ++++ configs/freebsd-g++-static.new Sat Sep 16 14:48:06 2000 +@@ -21,7 +21,7 @@ + SYSCONF_LIBS_X11 = -lXext -lX11 -lm + # Qt, Qt+OpenGL + SYSCONF_LFLAGS_QT = -L$(QTDIR)/lib +-SYSCONF_LIBS_QT = -lqt$(QT_THREAD_SUFFIX) ++SYSCONF_LIBS_QT = -lqt2$(QT_THREAD_SUFFIX) + SYSCONF_LIBS_QT_OPENGL = + # OpenGL + SYSCONF_LFLAGS_OPENGL = -L/usr/X11R6/lib +@@ -44,7 +44,7 @@ + SYSCONF_LIBS_THREAD = + + # Meta-object compiler +-SYSCONF_MOC = $(QTDIR)/bin/moc ++SYSCONF_MOC = $(QTDIR)/bin/moc2 + + # UI compiler + SYSCONF_UIC = $(QTDIR)/bin/uic |