2005-12-29 08:43:40 -05:00
|
|
|
# $OpenBSD: Makefile,v 1.50 2005/12/29 13:43:40 espie Exp $
|
2000-06-22 19:53:43 -04:00
|
|
|
# $FreeBSD: Makefile,v 1.33 1999/02/27 03:09:57 andreas Exp $
|
2003-04-10 14:08:56 -04:00
|
|
|
COMMENT= "C++ X11 GUI toolkit"
|
|
|
|
COMMENT-examples= "examples and tutorial for qt2"
|
|
|
|
COMMENT-html= "off-line html documentation for qt2"
|
2000-06-22 19:53:43 -04:00
|
|
|
|
2001-12-22 09:09:18 -05:00
|
|
|
VERSION= 3.2
|
2000-10-08 02:02:00 -04:00
|
|
|
DISTNAME= qt-2.${VERSION}
|
2000-06-22 19:53:43 -04:00
|
|
|
CATEGORIES= x11
|
2005-12-29 08:43:40 -05:00
|
|
|
PKGNAME= qt2-${VERSION}p0
|
|
|
|
PKGNAME-examples= qt2-examples-${VERSION}p0
|
|
|
|
PKGNAME-html= qt2-html-${VERSION}p0
|
|
|
|
SHARED_LIBS= qt 2.32
|
|
|
|
|
2002-10-29 14:48:57 -05:00
|
|
|
|
2000-06-22 19:53:43 -04:00
|
|
|
MASTER_SITES= ftp://ftp.troll.no/qt/source/
|
2000-10-08 02:02:00 -04:00
|
|
|
DISTFILES= qt-x11-2.${VERSION}.tar.gz
|
2000-06-23 05:53:52 -04:00
|
|
|
|
2000-06-22 19:53:43 -04:00
|
|
|
HOMEPAGE= http://www.trolltech.com/qt/
|
2000-06-23 05:53:52 -04:00
|
|
|
|
2000-09-22 11:02:34 -04:00
|
|
|
MAINTAINER= Marc Espie <espie@openbsd.org>
|
2000-06-22 19:53:43 -04:00
|
|
|
|
2003-10-08 13:13:14 -04:00
|
|
|
# QPL/GPL
|
2000-09-22 11:02:34 -04:00
|
|
|
PERMIT_PACKAGE_CDROM= Yes
|
|
|
|
PERMIT_PACKAGE_FTP= Yes
|
|
|
|
PERMIT_DISTFILES_CDROM= Yes
|
|
|
|
PERMIT_DISTFILES_FTP= Yes
|
2004-12-19 09:01:17 -05:00
|
|
|
myWANTLIB= GL GLU X11 Xext Xmu c m stdc++ z
|
2000-09-22 11:02:34 -04:00
|
|
|
|
2001-03-21 18:56:50 -05:00
|
|
|
#CXXFLAGS+= -g
|
|
|
|
|
2000-09-22 11:02:34 -04:00
|
|
|
USE_X11= Yes
|
|
|
|
USE_GMAKE= Yes
|
2001-03-21 18:56:50 -05:00
|
|
|
MAKE_ENV= QTDIR="${WRKDIST}" EXTRA_SAMPLES="${EXTRA_SAMPLES}" \
|
2003-04-10 12:58:19 -04:00
|
|
|
SYS_CXX="${CXX}" SYS_CXXFLAGS="${CXXFLAGS} -I${X11BASE}/include/freetype2" \
|
2001-03-21 18:56:50 -05:00
|
|
|
LD_LIBRARY_PATH="${WRKDIST}/lib"
|
2005-12-29 08:43:40 -05:00
|
|
|
MAKE_FLAGS= DESIGNER_SUBDIR=dummy LIBqt_VERSION=$(LIBqt_VERSION)
|
|
|
|
FAKE_FLAGS= $(MAKE_FLAGS) DESTDIR=$(WRKINST)
|
|
|
|
|
2000-09-22 11:02:34 -04:00
|
|
|
CONFIGURE_STYLE= simple
|
2001-02-20 08:55:52 -05:00
|
|
|
CONFIGURE_ARGS= -gif -system-libmng -system-libpng -system-jpeg \
|
2001-03-21 18:56:50 -05:00
|
|
|
-system-zlib -no-thread -sm -no-g++-exceptions \
|
2002-09-11 13:42:01 -04:00
|
|
|
-v
|
2001-03-21 18:56:50 -05:00
|
|
|
#CONFIGURE_ARGS+=-static -debug
|
2001-04-17 12:56:37 -04:00
|
|
|
#CONFIGURE_ARGS+=-debug
|
2001-03-21 18:56:50 -05:00
|
|
|
|
2002-09-11 13:42:01 -04:00
|
|
|
CONFIGURE_ENV= QTDIR="${WRKSRC}" MODULES="${QTMODULES}"
|
2000-09-22 11:02:34 -04:00
|
|
|
|
|
|
|
MULTI_PACKAGES= -examples -html
|
2000-06-22 19:53:43 -04:00
|
|
|
SUBPACKAGE?=
|
2000-09-22 11:02:34 -04:00
|
|
|
|
2001-08-27 04:58:28 -04:00
|
|
|
QTMODULES= tools kernel widgets dialogs \
|
2000-09-22 11:02:34 -04:00
|
|
|
iconview workspace network canvas table xml
|
|
|
|
EXTRA_SAMPLES=
|
2001-03-21 18:56:50 -05:00
|
|
|
|
2001-08-27 04:58:28 -04:00
|
|
|
QTMODULES+= opengl
|
2001-04-17 12:56:37 -04:00
|
|
|
EXTRA_SAMPLES+=box gear glpixmap overlay overlay_x11 sharedbox
|
|
|
|
|
2004-12-19 09:01:17 -05:00
|
|
|
.if ${SUBPACKAGE} != "-examples"
|
|
|
|
myWANTLIB+= lcms ICE Xft SM jpeg
|
|
|
|
.endif
|
|
|
|
.if !defined(PACKAGING) || ${SUBPACKAGE} == "-examples"
|
|
|
|
myWANTLIB+= pthread
|
|
|
|
.endif
|
2001-03-21 18:56:50 -05:00
|
|
|
|
|
|
|
LIB_DEPENDS=
|
|
|
|
|
2001-05-05 16:24:25 -04:00
|
|
|
.if !defined(PACKAGING) || ${SUBPACKAGE} != "-html"
|
2001-12-22 09:09:18 -05:00
|
|
|
LIB_DEPENDS+= png::graphics/png \
|
|
|
|
mng::graphics/libmng
|
2004-12-19 09:01:17 -05:00
|
|
|
WANTLIB= ${myWANTLIB}
|
2001-04-17 12:56:37 -04:00
|
|
|
.endif
|
2004-02-04 02:39:18 -05:00
|
|
|
.if defined(PACKAGING)
|
|
|
|
. if ${SUBPACKAGE} == "-examples"
|
2005-11-19 07:42:45 -05:00
|
|
|
LIB_DEPENDS= lib/qt2/qt.2.::x11/qt2
|
2004-02-04 02:39:18 -05:00
|
|
|
. elif ${SUBPACKAGE} == "-html"
|
|
|
|
PKG_ARCH= *
|
|
|
|
. endif
|
2000-06-22 19:53:43 -04:00
|
|
|
.endif
|
|
|
|
|
|
|
|
QT_INCDIR= ${PREFIX}/include/X11/qt2
|
2000-09-22 16:50:19 -04:00
|
|
|
TRUEDIR= ${TRUEPREFIX}/lib/qt2
|
2000-06-22 19:53:43 -04:00
|
|
|
QT_LIBDIR= ${PREFIX}/lib/qt2
|
2000-06-23 05:53:52 -04:00
|
|
|
QT_MANDIR= ${QT_LIBDIR}/man
|
2000-06-22 19:53:43 -04:00
|
|
|
QT_EXAMPLES= ${QT_LIBDIR}/examples
|
|
|
|
QT_TUTORIAL= ${QT_LIBDIR}/tutorial
|
|
|
|
QT_DOC= ${PREFIX}/share/doc/qt2
|
|
|
|
|
|
|
|
# for manpages in MESSAGE
|
2000-12-17 12:48:52 -05:00
|
|
|
SUBST_VARS= VERSION QT_LIBDIR QT_DOC
|
2000-06-22 19:53:43 -04:00
|
|
|
|
2000-10-08 02:02:00 -04:00
|
|
|
DOCS= ANNOUNCE FAQ LICENSE.GPL README README.QT \
|
2000-11-25 09:30:23 -05:00
|
|
|
changes-2*
|
2000-06-22 19:53:43 -04:00
|
|
|
|
2001-11-11 08:57:32 -05:00
|
|
|
VMEM_WARNING= Yes
|
2002-10-29 14:48:57 -05:00
|
|
|
NO_REGRESS= Yes
|
2001-11-11 08:57:32 -05:00
|
|
|
|
2000-06-22 19:53:43 -04:00
|
|
|
post-patch:
|
2000-07-13 17:26:45 -04:00
|
|
|
@cd ${WRKSRC}/configs; for i in openbsd-*; do \
|
2000-06-23 10:17:40 -04:00
|
|
|
mv -f $$i $$i.bak && \
|
|
|
|
sed -e s,/usr/local,${LOCALBASE}, \
|
|
|
|
-e s,/usr/X11R6,${X11BASE}, <$$i.bak >$$i; \
|
|
|
|
done
|
|
|
|
|
|
|
|
post-configure:
|
2000-07-13 17:26:45 -04:00
|
|
|
@cd ${WRKSRC} && cp -R examples examples-src
|
2005-09-24 03:48:41 -04:00
|
|
|
@find ${WRKSRC}/examples-src -name '*.orig' |xargs -r rm
|
2000-07-13 17:26:45 -04:00
|
|
|
@cd ${WRKSRC} && cp -R tutorial tutorial-src
|
2005-09-24 03:48:41 -04:00
|
|
|
@find ${WRKSRC}/tutorial-src -name '*.orig' |xargs -r rm
|
2000-06-22 19:53:43 -04:00
|
|
|
|
|
|
|
do-install:
|
2000-09-22 11:02:34 -04:00
|
|
|
${INSTALL_DATA_DIR} ${QT_INCDIR}
|
2001-03-21 18:56:50 -05:00
|
|
|
${INSTALL_MAN_DIR} ${QT_MANDIR}/man1
|
|
|
|
${INSTALL_MAN_DIR} ${QT_MANDIR}/man3
|
2000-09-22 11:02:34 -04:00
|
|
|
${INSTALL_DATA_DIR} ${QT_LIBDIR}/bin
|
|
|
|
${INSTALL_DATA_DIR} ${QT_EXAMPLES}
|
|
|
|
${INSTALL_DATA_DIR} ${QT_TUTORIAL}
|
|
|
|
${INSTALL_DATA_DIR} ${QT_DOC}/html
|
|
|
|
@if [ -f ${WRKBUILD}/lib/libqt.a ]; then \
|
|
|
|
${INSTALL_DATA} ${WRKBUILD}/lib/libqt.a ${PREFIX}/lib/qt2; \
|
|
|
|
fi
|
2005-12-29 08:43:40 -05:00
|
|
|
@if [ -f ${WRKBUILD}/lib/libqt.so.$(LIBqt_VERSION) ]; then \
|
|
|
|
${INSTALL_DATA} ${WRKBUILD}/lib/libqt.so.$(LIBqt_VERSION) ${PREFIX}/lib/qt2; \
|
|
|
|
ln -sf qt2/libqt.so.$(LIBqt_VERSION) ${PREFIX}/lib/libqt.so.$(LIBqt_VERSION); \
|
2000-09-22 11:02:34 -04:00
|
|
|
fi
|
2000-06-22 19:53:43 -04:00
|
|
|
${INSTALL_PROGRAM} ${WRKBUILD}/bin/moc ${QT_LIBDIR}/bin
|
2001-03-21 19:42:14 -05:00
|
|
|
${INSTALL_MAN} ${WRKSRC}/src/moc/moc.1 ${QT_MANDIR}/man1/moc2.1
|
2000-07-13 17:26:45 -04:00
|
|
|
@ln -sf ${TRUEPREFIX}/lib/qt2/bin/moc ${PREFIX}/bin/moc2
|
2000-06-23 10:17:40 -04:00
|
|
|
${INSTALL_SCRIPT} ${WRKBUILD}/bin/findtr ${PREFIX}/bin
|
|
|
|
${INSTALL_SCRIPT} ${WRKBUILD}/bin/qt20fix ${PREFIX}/bin
|
|
|
|
${INSTALL_SCRIPT} ${WRKBUILD}/bin/qtrename140 ${PREFIX}/bin
|
2000-06-22 19:53:43 -04:00
|
|
|
# avoid installing broken links
|
2000-07-13 17:26:45 -04:00
|
|
|
@rm -f ${WRKSRC}/include/qt_{mac,windows}.h
|
2000-06-23 05:53:52 -04:00
|
|
|
${INSTALL_DATA} ${WRKSRC}/include/* ${QT_INCDIR}
|
2000-06-22 19:53:43 -04:00
|
|
|
@for i in ${WRKSRC}/doc/man/man3/*; do \
|
|
|
|
j=$${i%qt}; \
|
|
|
|
sed -e 's,\.3qt,\.3,g' <$$i >$$j && \
|
2000-06-23 05:53:52 -04:00
|
|
|
${INSTALL_MAN} $$j ${QT_MANDIR}/man3; \
|
2000-06-22 19:53:43 -04:00
|
|
|
done
|
2000-06-23 10:17:40 -04:00
|
|
|
cp -R ${WRKSRC}/examples-src/* ${QT_EXAMPLES}
|
2000-06-22 19:53:43 -04:00
|
|
|
@cd ${WRKSRC}/examples; for i in *; do \
|
|
|
|
if [ -x $$i/$$i ]; then \
|
2000-06-23 10:17:40 -04:00
|
|
|
${INSTALL_PROGRAM} $$i/$$i ${QT_EXAMPLES}/$$i; \
|
2000-06-22 19:53:43 -04:00
|
|
|
fi; done
|
2000-09-22 16:50:19 -04:00
|
|
|
@if [ -x ${WRKSRC}/examples/overlay_x11/overlayrubber ]; then \
|
|
|
|
${INSTALL_PROGRAM} ${WRKSRC}/examples/overlay_x11/overlayrubber \
|
|
|
|
${QT_EXAMPLES}/overlay_x11/overlayrubber; \
|
|
|
|
fi
|
2000-06-23 10:17:40 -04:00
|
|
|
cp -R ${WRKSRC}/tutorial-src/* ${QT_TUTORIAL}
|
2000-06-22 19:53:43 -04:00
|
|
|
@cd ${WRKSRC}/tutorial; for i in *; do \
|
|
|
|
if [ -x $$i/$$i ]; then \
|
2000-06-23 10:17:40 -04:00
|
|
|
${INSTALL_PROGRAM} $$i/$$i ${QT_TUTORIAL}/$$i; \
|
2000-06-22 19:53:43 -04:00
|
|
|
fi; done
|
2000-09-22 11:02:34 -04:00
|
|
|
cd ${WRKSRC}; ${INSTALL_DATA} ${DOCS} ${QT_DOC}
|
2000-06-22 19:53:43 -04:00
|
|
|
cp -R ${WRKSRC}/doc/html/* ${QT_DOC}/html
|
2005-03-06 09:17:45 -05:00
|
|
|
${INSTALL_DATA_DIR} ${QT_LIBDIR}/doc
|
|
|
|
ln -s ${TRUEPREFIX}/share/doc/qt2/html ${QT_LIBDIR}/doc/html
|
2000-06-22 19:53:43 -04:00
|
|
|
|
2001-03-21 18:56:50 -05:00
|
|
|
.include <bsd.port.mk>
|
2001-10-08 19:20:50 -04:00
|
|
|
|
2004-04-06 23:19:23 -04:00
|
|
|
.if ${MACHINE_ARCH} == "alpha"
|
2001-10-08 19:20:50 -04:00
|
|
|
CXXFLAGS:= ${CXXFLAGS:N-O*}
|
|
|
|
.endif
|