summaryrefslogtreecommitdiff
path: root/print
diff options
context:
space:
mode:
authorDmitry Marakasov <amdmi3@FreeBSD.org>2015-09-22 23:59:05 +0000
committerDmitry Marakasov <amdmi3@FreeBSD.org>2015-09-22 23:59:05 +0000
commit6ebfaa4eed5726d9f4d73cd62f93969741c9b6d3 (patch)
tree6df2480a2e024c441a178da3ae2bc87006fcae38 /print
parent- Switch to options helpers (diff)
- Make GTK2 support optional
- Fix module directory handling - Strip libraries - Minor fixes PR: 196321, 200017, 202324 Submitted by: mazhe@alkumuna.eu, yuri@rawbw.com, amdmi3@FreeBSD.org, cmt@burggraben.net (maintainer) Approved by: cmt@burggraben.net (maintainer)
Notes
Notes: svn path=/head/; revision=397598
Diffstat (limited to 'print')
-rw-r--r--print/gimp-gutenprint/Makefile4
-rw-r--r--print/gutenprint-base/Makefile38
-rw-r--r--print/gutenprint-base/pkg-plist18
-rw-r--r--print/gutenprint-cups/pkg-plist1
4 files changed, 35 insertions, 26 deletions
diff --git a/print/gimp-gutenprint/Makefile b/print/gimp-gutenprint/Makefile
index d7c02d0dde26..0d0c2fd77874 100644
--- a/print/gimp-gutenprint/Makefile
+++ b/print/gimp-gutenprint/Makefile
@@ -2,7 +2,7 @@
# $FreeBSD$
# $MCom: ports/print/gimp-gutenprint/Makefile,v 1.5 2007/10/24 21:05:40 ahze Exp $
-PORTREVISION= 2
+PORTREVISION= 3
PORTEPOCH= 0
PKGNAMEPREFIX= gimp-
PKGNAMESUFFIX= # empty
@@ -15,6 +15,6 @@ LICENSE= GPLv2
MASTERDIR= ${.CURDIR}/../../print/gutenprint-base
GUT_SLAVE= gimp
-PLIST= ${.CURDIR}/pkg-plist
+PLIST= ${.CURDIR}/pkg-plist
.include "${MASTERDIR}/Makefile"
diff --git a/print/gutenprint-base/Makefile b/print/gutenprint-base/Makefile
index 7fd6e068e70d..ffbfe1c0419f 100644
--- a/print/gutenprint-base/Makefile
+++ b/print/gutenprint-base/Makefile
@@ -4,6 +4,7 @@
PORTNAME?= gutenprint
PORTVERSION= 5.2.10
+PORTREVISION= 1
CATEGORIES= print
MASTER_SITES= SF/gimp-print/gutenprint-5.2/${PORTVERSION}
PKGNAMESUFFIX?= -base
@@ -15,33 +16,39 @@ LICENSE= GPLv2
CONFLICTS= gimp-print-[0-9]*
+.if !defined(GUT_SLAVE)
+OPTIONS_DEFINE= GTK2
+OPTIONS_DEFAULT=GTK2
+OPTIONS_SUB= yes
+.endif
+
+GTK2_CONFIGURE_ENABLE= libgutenprintui2
+GTK2_LIB_DEPENDS= libgtk-x11-2.0.so:${PORTSDIR}/x11-toolkits/gtk20
+
+.include <bsd.port.options.mk>
+
USES= gettext gmake libtool pathfix pkgconfig tar:bzip2
-USE_GNOME= gtk20
GNU_CONFIGURE= yes
-CONFIGURE_ARGS=--with-gimp=no --with-gimp2=no
+CONFIGURE_ARGS+=--without-gimp --without-gimp2
USE_LDCONFIG= yes
CPPFLAGS+= -I${LOCALBASE}/include -I${PREFIX}/include
LDFLAGS+= -L${LOCALBASE}/lib -L${PREFIX}/lib
+INSTALL_TARGET= install-strip
.include <bsd.port.pre.mk>
.if ${SLAVE_PORT}=="yes"
-LIB_DEPENDS+= libgutenprintui2.so:${PORTSDIR}/print/gutenprint-base
+LIB_DEPENDS+= libgutenprint.so:${PORTSDIR}/print/gutenprint-base
PKG_CONFIG?= ${LOCALBASE}/bin/pkg-config
GUTENPRINTUI2_LIBS=`${PKG_CONFIG} --libs gutenprintui2`
-.else
-MAN1+= escputil.1
.endif
.if defined(GUT_SLAVE) && ${GUT_SLAVE}=="gimp"
-LIB_DEPENDS+= libgimp-2.0.so:${PORTSDIR}/graphics/gimp-app \
- libgutenprint.so:${PORTSDIR}/print/gutenprint-base
-CONFIGURE_ARGS=--with-gimp2=yes # Override CONFIGURE_ARGS
+LIB_DEPENDS+= libgimp-2.0.so:${PORTSDIR}/graphics/gimp-app
+CONFIGURE_ARGS+=--with-gimp2=yes # Override CONFIGURE_ARGS
BUILD_WRKSRC= ${WRKSRC}/src/gimp2
INSTALL_WRKSRC= ${WRKSRC}/src/gimp2
-.else
-CONFIGURE_ARGS+=--without-gimp2
.endif
.if defined(GUT_SLAVE) && ${GUT_SLAVE}=="cups"
@@ -97,16 +104,19 @@ post-patch:
@${REINPLACE_CMD} -e 's|= $$(pkglibdir)|= ${PREFIX}/libexec/cups|' \
${WRKSRC}/src/cups/Makefile.in
+pre-configure:
+.if defined(GUT_SLAVE) && (${GUT_SLAVE}=="gimp")
+ @test -f ${LOCALBASE}/lib/libgutenprintui2.so || (printf "\nprint/gutenprint-base must be rebuilt with GTK2 support\n\n" && exit 1)
+.endif
+
pre-build:
.if defined(GUT_SLAVE) && (${GUT_SLAVE}=="foomatic" || ${GUT_SLAVE}=="cups")
@(cd ${WRKSRC}/src/xml && ${MAKE})
.endif
pre-install:
- @${MKDIR} ${STAGEDIR}${LOCALBASE}/lib/gutenprint/5.2/modules
-.if defined(GUT_SLAVE) && ${GUT_SLAVE}=="cups"
- @${REINPLACE_CMD} -e 's|/usr/bin/perl|${LOCALBASE}/bin/perl|' \
- ${WRKSRC}/src/cups/cups-genppdupdate
+.if !defined(GUT_SLAVE)
+ @${MKDIR} ${STAGEDIR}${PREFIX}/lib/gutenprint/5.2/modules
.endif
post-install:
diff --git a/print/gutenprint-base/pkg-plist b/print/gutenprint-base/pkg-plist
index 527489e144a1..175c50352c43 100644
--- a/print/gutenprint-base/pkg-plist
+++ b/print/gutenprint-base/pkg-plist
@@ -23,20 +23,20 @@ include/gutenprint/util.h
include/gutenprint/vars.h
include/gutenprint/weave.h
include/gutenprint/xml.h
-include/gutenprintui2/curve.h
-include/gutenprintui2/gammacurve.h
-include/gutenprintui2/gutenprintui.h
-include/gutenprintui2/typebuiltins.h
+%%GTK2%%include/gutenprintui2/curve.h
+%%GTK2%%include/gutenprintui2/gammacurve.h
+%%GTK2%%include/gutenprintui2/gutenprintui.h
+%%GTK2%%include/gutenprintui2/typebuiltins.h
lib/libgutenprint.so.2
lib/libgutenprint.so.2.3.0
-lib/libgutenprintui2.so.1.0.0
+%%GTK2%%lib/libgutenprintui2.so.1.0.0
lib/libgutenprint.a
lib/libgutenprint.so
-lib/libgutenprintui2.a
-lib/libgutenprintui2.so
-lib/libgutenprintui2.so.1
+%%GTK2%%lib/libgutenprintui2.a
+%%GTK2%%lib/libgutenprintui2.so
+%%GTK2%%lib/libgutenprintui2.so.1
libdata/pkgconfig/gutenprint.pc
-libdata/pkgconfig/gutenprintui2.pc
+%%GTK2%%libdata/pkgconfig/gutenprintui2.pc
man/man1/escputil.1.gz
%%DATADIR%%/5.2/xml/dither-matrix-1x1.xml
%%DATADIR%%/5.2/xml/dither-matrix-2x1.xml
diff --git a/print/gutenprint-cups/pkg-plist b/print/gutenprint-cups/pkg-plist
index d576af467fb7..42790dc245a7 100644
--- a/print/gutenprint-cups/pkg-plist
+++ b/print/gutenprint-cups/pkg-plist
@@ -2378,4 +2378,3 @@ share/locale/uk/gutenprint_uk.po
share/locale/vi/gutenprint_vi.po
share/locale/zh_CN/gutenprint_zh_CN.po
share/locale/zh_TW/gutenprint_zh_TW.po
-@dir lib/gutenprint/5.2/modules