2003-01-22 14:54:55 +01:00
|
|
|
# New ports collection makefile for: cups
|
|
|
|
# Date created: 2003-01-22
|
|
|
|
# Whom: Alan Eldridge <alane@geeksrus.net>
|
2001-01-07 01:52:07 +01:00
|
|
|
#
|
|
|
|
# $FreeBSD$
|
|
|
|
#
|
|
|
|
|
2006-12-06 10:39:28 +01:00
|
|
|
PORTNAME= cups
|
2010-04-07 21:49:46 +02:00
|
|
|
PORTVERSION= 1.4.3
|
2006-12-06 10:39:28 +01:00
|
|
|
DISTVERSIONSUFFIX= -source
|
2010-04-07 21:49:46 +02:00
|
|
|
PORTREVISION= 0
|
2003-01-22 14:54:55 +01:00
|
|
|
CATEGORIES= print
|
2008-09-07 11:33:24 +02:00
|
|
|
MASTER_SITES= EASYSW/${PORTNAME}/${DISTVERSION}
|
2009-05-07 12:04:18 +02:00
|
|
|
PKGNAMESUFFIX= ${CUPS_SUFFIX}${PKGNAMESUFFIX2}
|
2002-07-02 12:08:17 +02:00
|
|
|
|
2006-12-10 15:05:59 +01:00
|
|
|
MAINTAINER= dinoex@FreeBSD.org
|
2009-05-17 17:48:39 +02:00
|
|
|
COMMENT= Common UNIX Printing System: ${COMMENT2}
|
2006-12-06 10:39:28 +01:00
|
|
|
|
2006-08-06 11:13:36 +02:00
|
|
|
CONFLICTS= LPRng-[0-9]*
|
|
|
|
|
2006-06-22 22:16:06 +02:00
|
|
|
USE_BZIP2= yes
|
|
|
|
USE_GMAKE= yes
|
|
|
|
GNU_CONFIGURE= yes
|
2006-12-22 09:51:28 +01:00
|
|
|
CFLAGS+= ${PTHREAD_CFLAGS}
|
2006-12-06 10:39:28 +01:00
|
|
|
CPPFLAGS= -I${LOCALBASE}/include
|
|
|
|
LDFLAGS= -L${LOCALBASE}/lib
|
2008-10-15 09:46:23 +02:00
|
|
|
DSOFLAGS= -Wl,-rpath,${PREFIX}/lib -L${PREFIX}/lib ${LDFLAGS}
|
2006-12-06 10:39:28 +01:00
|
|
|
CONFIGURE_ENV= CPPFLAGS="${CPPFLAGS}" LDFLAGS="${LDFLAGS}" DSOFLAGS="${DSOFLAGS}"
|
|
|
|
CONFIGURE_ARGS+= --localstatedir=/var \
|
|
|
|
--disable-slp \
|
2007-09-28 14:05:15 +02:00
|
|
|
--disable-gssapi \
|
2006-12-06 10:39:28 +01:00
|
|
|
--with-cups-user=${CUPSOWN} \
|
|
|
|
--with-cups-group=${CUPSGRP} \
|
|
|
|
--with-system-groups=${CUPSSYSGRP} \
|
|
|
|
--with-docdir=${DOCSDIR} \
|
2007-09-28 14:05:15 +02:00
|
|
|
--with-icondir=${PREFIX}/share/icons \
|
2008-01-14 10:17:51 +01:00
|
|
|
--with-menudir=${DESKTOPDIR} \
|
2009-12-01 20:23:45 +01:00
|
|
|
--with-domainsocket=${CUPS_SOCKET} \
|
|
|
|
--enable-ssl
|
2003-02-07 05:50:53 +01:00
|
|
|
|
2009-05-07 12:04:18 +02:00
|
|
|
OPTIONS?= GNUTLS "Build with GNUTLS library" on \
|
2006-06-22 22:16:06 +02:00
|
|
|
PHP "Build PHP support" off \
|
|
|
|
PYTHON "Build PYTHON support" off \
|
2008-01-23 17:00:56 +01:00
|
|
|
LIBPAPER "Build with libpaper support" off \
|
|
|
|
DNSSD "Build with DNS_SD (avahi) support" off \
|
2008-01-29 16:44:36 +01:00
|
|
|
PAM "Build with PAM support" off \
|
2008-03-28 16:40:03 +01:00
|
|
|
LDAP "Build with LDAP support" off \
|
2008-04-11 06:59:09 +02:00
|
|
|
DBUS "Build with DBUS support" off \
|
2009-12-05 06:57:21 +01:00
|
|
|
LIBUSB "Build with USB support" off \
|
2010-01-15 17:06:39 +01:00
|
|
|
GHOSTSCRIPT "Build pdftops with GHOSTSCRIPT" on \
|
|
|
|
XPDF "Build pdftops with XPDF" off \
|
2009-02-14 19:31:24 +01:00
|
|
|
XDG_OPEN "Build with XDG_OPEN as browser" off
|
2006-06-22 22:16:06 +02:00
|
|
|
|
|
|
|
CUPS_ETCDIR= ${PREFIX}/etc/cups
|
|
|
|
CUPS_SPOOLDIR= /var/spool/cups
|
|
|
|
CUPS_SOCKET?= /var/run/cups.sock
|
2006-12-06 10:39:28 +01:00
|
|
|
WRKSRC= ${WRKDIR}/${PORTNAME}-${DISTVERSION}
|
2006-06-22 22:16:06 +02:00
|
|
|
|
|
|
|
# file, dir ownership
|
|
|
|
CUPSGRP= cups
|
|
|
|
CUPSOWN= cups
|
|
|
|
CUPSSYSGRP= wheel
|
|
|
|
|
2006-12-06 10:39:28 +01:00
|
|
|
.include <bsd.port.pre.mk>
|
2006-06-22 22:16:06 +02:00
|
|
|
|
2009-05-07 12:04:18 +02:00
|
|
|
.if defined(CUPS_CLIENT)
|
|
|
|
CUPS_SUFFIX= -client
|
2009-05-18 09:11:38 +02:00
|
|
|
COMMENT2= Library cups
|
2009-05-07 15:59:11 +02:00
|
|
|
INSTALL_WRKSRC= ${WRKSRC}/cups
|
2009-05-16 10:52:36 +02:00
|
|
|
PLIST= ${MASTERDIR}/pkg-plist.client
|
|
|
|
USE_LDCONFIG= yes
|
2009-05-16 16:09:03 +02:00
|
|
|
PKGMESSAGE= ${NONEXISTENT}
|
2009-05-18 09:11:38 +02:00
|
|
|
DESCR= ${MASTERDIR}/pkg-descr.client
|
2009-05-16 10:52:36 +02:00
|
|
|
.elif defined(CUPS_IMAGE)
|
|
|
|
CUPS_SUFFIX= -image
|
2009-05-16 12:04:10 +02:00
|
|
|
LIB_DEPENDS+= cups.2:${PORTSDIR}/${PKGCATEGORY}/cups-client \
|
2010-02-05 12:46:55 +01:00
|
|
|
jpeg.11:${PORTSDIR}/graphics/jpeg \
|
2010-03-28 08:47:48 +02:00
|
|
|
png.6:${PORTSDIR}/graphics/png \
|
2009-05-16 12:04:10 +02:00
|
|
|
tiff.4:${PORTSDIR}/graphics/tiff
|
2009-05-18 09:11:38 +02:00
|
|
|
COMMENT2= Library cupsimage
|
2009-05-16 10:52:36 +02:00
|
|
|
CONFIGURE_ARGS+= --disable-pdftops
|
|
|
|
INSTALL_WRKSRC= ${WRKSRC}/filter
|
|
|
|
PLIST= ${MASTERDIR}/pkg-plist.image
|
|
|
|
USE_LDCONFIG= yes
|
2009-05-16 16:09:03 +02:00
|
|
|
PKGMESSAGE= ${NONEXISTENT}
|
2009-05-18 09:11:38 +02:00
|
|
|
DESCR= ${MASTERDIR}/pkg-descr.image
|
2009-05-07 12:04:18 +02:00
|
|
|
.else
|
2010-02-11 13:52:37 +01:00
|
|
|
CONFLICTS+= cupsddk-*
|
2009-05-07 12:04:18 +02:00
|
|
|
CUPS_SUFFIX= -base
|
2009-05-16 12:04:10 +02:00
|
|
|
LIB_DEPENDS+= cups.2:${PORTSDIR}/${PKGCATEGORY}/cups-client \
|
|
|
|
cupsimage.2:${PORTSDIR}/${PKGCATEGORY}/cups-image
|
2009-05-08 05:48:01 +02:00
|
|
|
# force build if old cups is installed.
|
|
|
|
BUILD_DEPENDS+= ${LOCALBASE}/lib/libcups.a:${PORTSDIR}/${PKGCATEGORY}/cups-client
|
2009-05-17 17:48:39 +02:00
|
|
|
COMMENT2= Server
|
2009-05-16 10:52:36 +02:00
|
|
|
USE_RC_SUBR= cupsd
|
2009-12-25 19:09:29 +01:00
|
|
|
.if ${ARCH} == "ia64"
|
|
|
|
BROKEN= stack-protector not supported on ia64
|
|
|
|
.endif
|
2009-05-07 12:04:18 +02:00
|
|
|
.endif
|
|
|
|
|
2007-06-12 16:14:35 +02:00
|
|
|
.if defined(CUPS_OVERWRITE_BASE)
|
|
|
|
PLIST_SUB+= OVERWRITE=""
|
2009-12-08 10:57:19 +01:00
|
|
|
CONFIGURE_ARGS+= --with-printcap=/etc/printcap
|
2007-06-12 16:14:35 +02:00
|
|
|
.else
|
|
|
|
PLIST_SUB+= OVERWRITE="@comment "
|
2009-12-08 10:57:19 +01:00
|
|
|
CONFIGURE_ARGS+= --with-printcap=${PREFIX}/etc/printcap
|
2007-06-12 16:14:35 +02:00
|
|
|
.endif
|
|
|
|
|
2006-06-22 22:16:06 +02:00
|
|
|
.if !defined(WITHOUT_GNUTLS)
|
2009-12-01 20:23:45 +01:00
|
|
|
CONFIGURE_ARGS+= --disable-openssl --enable-gnutls
|
|
|
|
CONFIGURE_ENV+= PKGCONFIG="${LOCALBASE}/bin/pkg-config"
|
2009-08-16 20:04:40 +02:00
|
|
|
LIB_DEPENDS+= gnutls-openssl.40:${PORTSDIR}/security/gnutls
|
2009-12-01 20:23:45 +01:00
|
|
|
BUILD_DEPENDS+= pkg-config:${PORTSDIR}/devel/pkg-config
|
2006-12-06 10:39:28 +01:00
|
|
|
.else
|
|
|
|
CONFIGURE_ARGS+= --disable-gnutls --enable-openssl
|
2007-02-20 07:29:38 +01:00
|
|
|
.include "${PORTSDIR}/Mk/bsd.openssl.mk"
|
2006-06-22 22:16:06 +02:00
|
|
|
.endif
|
|
|
|
|
2009-05-16 12:04:10 +02:00
|
|
|
.if !defined(CUPS_CLIENT) && !defined(CUPS_IMAGE) && defined(WITH_PHP)
|
2006-06-22 22:16:06 +02:00
|
|
|
CONFIGURE_ARGS+= --with-php
|
2006-08-06 11:13:36 +02:00
|
|
|
USE_PHP= yes
|
2007-03-06 07:54:19 +01:00
|
|
|
USE_PHP_BUILD= yes
|
2006-08-06 11:13:36 +02:00
|
|
|
PLIST_SUB+= PHP=""
|
2006-06-24 10:14:19 +02:00
|
|
|
.else
|
|
|
|
CONFIGURE_ARGS+= --without-php
|
2006-08-06 11:13:36 +02:00
|
|
|
PLIST_SUB+= PHP="@comment "
|
2006-06-22 22:16:06 +02:00
|
|
|
.endif
|
|
|
|
|
2010-01-15 17:06:39 +01:00
|
|
|
.if !defined(CUPS_CLIENT) && !defined(CUPS_IMAGE) && !defined(WITHOUT_GHOSTSCRIPT)
|
|
|
|
.if defined(WITH_XPDF)
|
|
|
|
IGNORE= "Pick ghostscript or xpdf, not both"
|
|
|
|
.endif
|
2009-05-16 12:04:10 +02:00
|
|
|
USE_GHOSTSCRIPT= yes
|
2010-01-15 17:06:39 +01:00
|
|
|
CONFIGURE_ARGS+= --enable-pdftops --with-pdftops=${LOCALBASE}/bin/gs
|
|
|
|
PLIST_SUB+= WITH_PDFTOPS=""
|
|
|
|
.elif !defined(CUPS_CLIENT) && !defined(CUPS_IMAGE) && defined(WITH_XPDF)
|
|
|
|
BUILD_DEPENDS+= pdftops:${PORTSDIR}/graphics/xpdf
|
|
|
|
RUN_DEPENDS+= pdftops:${PORTSDIR}/graphics/xpdf
|
|
|
|
CONFIGURE_ARGS+= --enable-pdftops --with-pdftops=${LOCALBASE}/bin/pdftops
|
|
|
|
PLIST_SUB+= WITH_PDFTOPS=""
|
2009-05-16 12:04:10 +02:00
|
|
|
.else
|
2010-01-15 17:06:39 +01:00
|
|
|
PLIST_SUB+= WITH_PDFTOPS="@comment "
|
2009-05-16 12:04:10 +02:00
|
|
|
.endif
|
|
|
|
|
|
|
|
.if !defined(CUPS_CLIENT) && !defined(CUPS_IMAGE) && defined(WITH_PYTHON)
|
2006-06-22 22:16:06 +02:00
|
|
|
CONFIGURE_ARGS+= --with-python
|
|
|
|
USE_PYTHON= yes
|
2006-08-06 11:13:36 +02:00
|
|
|
.include "${PORTSDIR}/Mk/bsd.python.mk"
|
2006-06-22 22:16:06 +02:00
|
|
|
.endif
|
|
|
|
|
2009-05-16 12:04:10 +02:00
|
|
|
.if !defined(CUPS_CLIENT) && !defined(CUPS_IMAGE) && defined(WITH_LIBPAPER)
|
2006-06-22 22:16:06 +02:00
|
|
|
CONFIGURE_ARGS+= --enable-libpaper
|
|
|
|
LIB_DEPENDS+= paper.2:${PORTSDIR}/print/libpaper
|
|
|
|
.endif
|
|
|
|
|
2009-05-16 12:04:10 +02:00
|
|
|
.if !defined(CUPS_CLIENT) && !defined(CUPS_IMAGE) && defined(WITH_DNSSD)
|
2008-01-20 16:29:57 +01:00
|
|
|
CONFIGURE_ARGS+= --enable-dnssd \
|
|
|
|
--with-dnssd-libs=${LOCALBASE}/lib/ \
|
|
|
|
--with-dnssd-includes=${LOCALBASE}/include/avahi-compat-libdns_sd/
|
|
|
|
LIB_DEPENDS+= dns_sd:${PORTSDIR}/net/avahi-libdns
|
2008-02-02 15:31:39 +01:00
|
|
|
.else
|
|
|
|
CONFIGURE_ARGS+= --disable-dnssd
|
2008-01-20 16:29:57 +01:00
|
|
|
.endif
|
|
|
|
|
2009-05-16 12:04:10 +02:00
|
|
|
.if !defined(CUPS_CLIENT) && !defined(CUPS_IMAGE) && defined(WITH_PAM)
|
2008-01-23 17:00:56 +01:00
|
|
|
CONFIGURE_ARGS+= --enable-pam
|
|
|
|
PLIST_SUB+= WITH_PAMD=""
|
|
|
|
.else
|
|
|
|
CONFIGURE_ARGS+= --disable-pam
|
|
|
|
PLIST_SUB+= WITH_PAMD="@comment "
|
|
|
|
.endif
|
|
|
|
|
2009-05-16 12:04:10 +02:00
|
|
|
.if !defined(CUPS_CLIENT) && !defined(CUPS_IMAGE) && defined(WITH_LDAP)
|
2008-01-29 16:44:36 +01:00
|
|
|
USE_OPENLDAP= yes
|
|
|
|
CONFIGURE_ARGS+= --enable-ldap
|
|
|
|
.else
|
|
|
|
CONFIGURE_ARGS+= --disable-ldap
|
|
|
|
.endif
|
|
|
|
|
2009-05-16 12:04:10 +02:00
|
|
|
.if !defined(CUPS_CLIENT) && !defined(CUPS_IMAGE) && defined(WITH_DBUS)
|
2008-03-28 16:40:03 +01:00
|
|
|
LIB_DEPENDS+= dbus-1.3:${PORTSDIR}/devel/dbus
|
|
|
|
CONFIGURE_ARGS+= --enable-dbus
|
2010-04-07 21:49:46 +02:00
|
|
|
PLIST_SUB+= WITH_DBUS=""
|
2008-03-28 16:40:03 +01:00
|
|
|
.else
|
|
|
|
CONFIGURE_ARGS+= --disable-dbus
|
2010-04-07 21:49:46 +02:00
|
|
|
PLIST_SUB+= WITH_DBUS="@comment "
|
2008-03-28 16:40:03 +01:00
|
|
|
.endif
|
|
|
|
|
2009-05-16 12:04:10 +02:00
|
|
|
.if !defined(CUPS_CLIENT) && !defined(CUPS_IMAGE) && defined(WITH_XDG_OPEN)
|
2009-02-03 13:58:33 +01:00
|
|
|
RUN_DEPENDS+= xdg-open:${PORTSDIR}/devel/xdg-utils
|
|
|
|
.endif
|
|
|
|
|
2009-12-08 09:20:56 +01:00
|
|
|
.if !defined(CUPS_CLIENT) && !defined(CUPS_IMAGE) && defined(WITH_LIBUSB) && ${OSVERSION}>800062
|
|
|
|
CPPFLAGS+= -I/usr/include
|
|
|
|
LDFLAGS+= -L/usr/lib
|
|
|
|
.elif !defined(CUPS_CLIENT) && !defined(CUPS_IMAGE) && defined(WITH_LIBUSB) && ${OSVERSION}<800063
|
2009-12-05 06:57:21 +01:00
|
|
|
LIB_DEPENDS+= usb:${PORTSDIR}/devel/libusb
|
2009-12-08 09:20:56 +01:00
|
|
|
.else
|
|
|
|
CONFIGURE_ARGS+= --disable-libusb
|
2009-12-05 06:57:21 +01:00
|
|
|
.endif
|
|
|
|
|
2009-05-07 15:59:11 +02:00
|
|
|
.if defined(CUPS_CLIENT)
|
|
|
|
MAN1= cups-config.1
|
2009-05-16 10:52:36 +02:00
|
|
|
.elif defined(CUPS_IMAGE)
|
2009-05-07 15:59:11 +02:00
|
|
|
.else
|
2009-05-07 12:04:18 +02:00
|
|
|
MAN1= cancel.1 \
|
|
|
|
cupstestdsc.1 \
|
|
|
|
cupstestppd.1 \
|
|
|
|
lp.1 \
|
|
|
|
lpoptions.1 \
|
|
|
|
lppasswd.1 \
|
|
|
|
lpq.1 \
|
|
|
|
lprm.1 \
|
|
|
|
lpr.1 \
|
2009-11-28 22:54:18 +01:00
|
|
|
lpstat.1 \
|
|
|
|
ppdc.1 \
|
|
|
|
ppdhtml.1 \
|
|
|
|
ppdi.1 \
|
|
|
|
ppdmerge.1 \
|
|
|
|
ppdpo.1
|
2009-05-07 12:04:18 +02:00
|
|
|
MAN5= classes.conf.5 \
|
|
|
|
client.conf.5 \
|
|
|
|
cups-snmp.conf.5 \
|
|
|
|
cupsd.conf.5 \
|
|
|
|
mailto.conf.5 \
|
|
|
|
mime.convs.5 \
|
|
|
|
mime.types.5 \
|
2009-11-28 22:54:18 +01:00
|
|
|
ppdcfile.5 \
|
2009-05-07 12:04:18 +02:00
|
|
|
printers.conf.5 \
|
|
|
|
subscriptions.conf.5
|
|
|
|
MAN7= backend.7 \
|
2009-11-28 22:54:18 +01:00
|
|
|
drv.7 \
|
|
|
|
filter.7 \
|
|
|
|
notifier.7
|
2009-05-07 12:04:18 +02:00
|
|
|
MAN8= accept.8 \
|
2009-11-28 22:54:18 +01:00
|
|
|
cupsaccept.8 \
|
2009-05-07 12:04:18 +02:00
|
|
|
cupsaddsmb.8 \
|
|
|
|
cupsctl.8 \
|
|
|
|
cupsd.8 \
|
|
|
|
cupsenable.8 \
|
|
|
|
cupsfilter.8 \
|
2009-11-28 22:54:18 +01:00
|
|
|
cups-deviced.8 \
|
|
|
|
cups-driverd.8 \
|
|
|
|
cups-lpd.8 \
|
|
|
|
cups-polld.8 \
|
2009-05-07 12:04:18 +02:00
|
|
|
lpadmin.8 \
|
|
|
|
lpinfo.8 \
|
|
|
|
lpmove.8 \
|
|
|
|
lpc.8
|
|
|
|
|
|
|
|
MLINKS= accept.8 reject.8 \
|
2009-11-28 22:54:18 +01:00
|
|
|
cupsaccept.8 cupsreject.8 \
|
2009-05-07 12:04:18 +02:00
|
|
|
cupsenable.8 cupsdisable.8
|
|
|
|
.endif
|
2006-06-22 22:16:06 +02:00
|
|
|
|
|
|
|
pre-configure::
|
|
|
|
@${ECHO_MSG} Configuring CUPS with options:
|
|
|
|
@${ECHO_MSG} ${CONFIGURE_ARGS} | fmt
|
2003-07-21 16:28:32 +02:00
|
|
|
|
|
|
|
post-patch:
|
2009-11-30 05:09:09 +01:00
|
|
|
.if (${OSVERSION} >= 700000) || defined(WITH_PIEAMD64)
|
|
|
|
.if ${ARCH} == "amd64" || defined(WITH_PIEAMD64)
|
|
|
|
@${REINPLACE_CMD} -e 's|@PIEFLAGS@||' ${WRKSRC}/Makedefs.in
|
|
|
|
.endif
|
|
|
|
.endif
|
2008-04-11 06:59:09 +02:00
|
|
|
.if defined(WITH_XDG_OPEN)
|
2009-11-29 15:55:33 +01:00
|
|
|
@${REINPLACE_CMD} -e 's|htmlview|xdg-open|' ${WRKSRC}/desktop/cups.desktop.in
|
2008-04-11 06:59:09 +02:00
|
|
|
.endif
|
2006-12-06 10:39:28 +01:00
|
|
|
@${REINPLACE_CMD} -e '/SILENT/d' ${WRKSRC}/Makedefs.in
|
2009-06-25 16:48:57 +02:00
|
|
|
@${REINPLACE_CMD} -e 's|/etc/cups|${LOCALBASE}/etc/cups|g' ${WRKSRC}/man/*.man*
|
2009-11-29 15:55:33 +01:00
|
|
|
@${REINPLACE_CMD} -e 's|-lpthreads.*;|${PTHREAD_LIBS};|g' \
|
2008-01-23 17:00:56 +01:00
|
|
|
-e 's|/private/etc/pam.d|${LOCALBASE}/etc/pam.d|' \
|
2010-03-28 13:52:05 +02:00
|
|
|
-e 's|-D_LARGEFILE64_SOURCE||g' \
|
2006-12-22 09:51:28 +01:00
|
|
|
${WRKSRC}/${CONFIGURE_SCRIPT}
|
2009-05-07 12:04:18 +02:00
|
|
|
.if defined(CUPS_CLIENT)
|
|
|
|
@${REINPLACE_CMD} \
|
2009-11-29 15:55:33 +01:00
|
|
|
-e 's|cups filter |cups |' \
|
|
|
|
-e 's|backend berkeley cgi-bin driver locale man monitor||' \
|
|
|
|
-e 's|notifier ppdc scheduler systemv test ||' \
|
2009-05-07 12:04:18 +02:00
|
|
|
-e 's|$$.PHPDIR. ||' \
|
|
|
|
-e 's|conf data doc $$.FONTS.ppd templates||' \
|
2009-05-16 12:04:10 +02:00
|
|
|
-e 's|/usr/share|${PREFIX}/share|g' \
|
2009-05-07 12:04:18 +02:00
|
|
|
${WRKSRC}/Makefile
|
2009-05-16 10:52:36 +02:00
|
|
|
.elif defined(CUPS_IMAGE)
|
|
|
|
@${REINPLACE_CMD} \
|
2009-11-29 15:55:33 +01:00
|
|
|
-e 's|cups filter |filter |' \
|
|
|
|
-e 's|backend berkeley cgi-bin driver locale man monitor||' \
|
|
|
|
-e 's|notifier ppdc scheduler systemv test ||' \
|
2009-05-16 10:52:36 +02:00
|
|
|
-e 's|$$.PHPDIR. ||' \
|
|
|
|
-e 's|conf data doc $$.FONTS.ppd templates||' \
|
2009-05-16 12:04:10 +02:00
|
|
|
-e 's|/usr/share|${PREFIX}/share|g' \
|
2009-05-16 10:52:36 +02:00
|
|
|
${WRKSRC}/Makefile
|
2009-05-07 15:59:11 +02:00
|
|
|
.else
|
2009-05-07 12:04:18 +02:00
|
|
|
@${REINPLACE_CMD} \
|
2009-11-29 17:25:35 +01:00
|
|
|
-e 's|cups filter backend|backend|' \
|
2009-05-07 17:38:15 +02:00
|
|
|
-e 's|$$.INSTALL_SCRIPT. cups-config|echo skip: cups-config|' \
|
2009-05-16 12:04:10 +02:00
|
|
|
-e 's|/usr/share|${PREFIX}/share|g' \
|
|
|
|
-e 's|installhdrs$$||' \
|
2009-05-07 15:59:11 +02:00
|
|
|
${WRKSRC}/Makefile
|
|
|
|
@${REINPLACE_CMD} \
|
|
|
|
-e 's|cups-config.$$.MAN1EXT. ||' \
|
|
|
|
${WRKSRC}/man/Makefile
|
|
|
|
.endif
|
|
|
|
|
|
|
|
.if !defined(CUPS_CLIENT)
|
|
|
|
pre-build:
|
|
|
|
${CP} -p ${LOCALBASE}/lib/libcups.a ${WRKSRC}/cups/
|
|
|
|
${CP} -p ${LOCALBASE}/lib/libcups.so ${WRKSRC}/cups/
|
|
|
|
${CP} -p ${LOCALBASE}/lib/libcups.so.2 ${WRKSRC}/cups/
|
2009-05-16 12:04:10 +02:00
|
|
|
.if !defined(CUPS_IMAGE)
|
|
|
|
${CP} -p ${LOCALBASE}/lib/libcupsimage.so ${WRKSRC}/filter/
|
|
|
|
${CP} -p ${LOCALBASE}/lib/libcupsimage.so.2 ${WRKSRC}/filter/
|
|
|
|
.endif
|
2009-05-07 12:04:18 +02:00
|
|
|
.endif
|
2003-07-21 16:28:32 +02:00
|
|
|
|
2009-11-28 22:54:18 +01:00
|
|
|
.if defined(CUPS_IMAGE)
|
|
|
|
post-install:
|
|
|
|
${INSTALL_DATA} ${WRKSRC}/cups/raster.h ${PREFIX}/include/cups/
|
|
|
|
.endif
|
|
|
|
|
2009-05-16 10:52:36 +02:00
|
|
|
.if !defined(CUPS_CLIENT) && !defined(CUPS_IMAGE)
|
2009-05-16 12:04:10 +02:00
|
|
|
post-build:
|
|
|
|
cd ${WRKSRC}/filter && ${MAKE} pdftops
|
|
|
|
|
2007-09-28 14:05:15 +02:00
|
|
|
pre-su-install:
|
2006-12-06 10:39:28 +01:00
|
|
|
@${INSTALL} -d ${DESKTOPDIR}/
|
2007-06-08 15:57:13 +02:00
|
|
|
if ! pw groupshow ${CUPSGRP}; then pw groupadd ${CUPSGRP} -g 193; fi
|
|
|
|
if ! pw usershow ${CUPSOWN}; then pw useradd ${CUPSOWN} -g ${CUPSGRP} -u 193 \
|
|
|
|
-h - -d ${NONEXISTENT} -s /usr/sbin/nologin -c "CUPS Owner"; fi
|
2007-06-12 16:14:35 +02:00
|
|
|
.if defined(CUPS_OVERWRITE_BASE)
|
2007-09-30 06:17:39 +02:00
|
|
|
if test -e /usr/bin/lp; then ${CHMOD} -h 0 /usr/bin/lp; fi
|
|
|
|
if test -e /usr/bin/lpq; then ${CHMOD} -h 0 /usr/bin/lpq; fi
|
|
|
|
if test -e /usr/bin/lpr; then ${CHMOD} -h 0 /usr/bin/lpr; fi
|
|
|
|
if test -e /usr/bin/lprm; then ${CHMOD} -h 0 /usr/bin/lprm; fi
|
|
|
|
if test -e /usr/sbin/lpc; then ${CHMOD} -h 0 /usr/sbin/lpc; fi
|
2007-06-12 16:14:35 +02:00
|
|
|
.endif
|
2003-01-23 23:16:07 +01:00
|
|
|
|
2001-01-10 18:07:59 +01:00
|
|
|
post-install:
|
2010-01-15 17:06:39 +01:00
|
|
|
.if !defined(WITHOUT_GHOSTSCRIPT) || defined(WITH_XPDF)
|
2009-05-16 12:04:10 +02:00
|
|
|
${INSTALL_PROGRAM} ${WRKSRC}/filter/pdftops ${PREFIX}/libexec/cups/filter/
|
|
|
|
.endif
|
2006-12-06 10:39:28 +01:00
|
|
|
${INSTALL} -d ${CUPS_ETCDIR}/
|
2007-09-28 14:05:15 +02:00
|
|
|
${CP} -p ${WRKSRC}/conf/snmp.conf ${WRKSRC}/conf/snmp.conf.N
|
|
|
|
.for f in cupsd.conf mime.convs mime.types snmp.conf
|
2003-07-21 16:28:32 +02:00
|
|
|
${INSTALL_DATA} ${WRKSRC}/conf/${f} ${CUPS_ETCDIR}/${f}.N
|
2006-12-06 10:39:28 +01:00
|
|
|
cd ${CUPS_ETCDIR}/; if test ! -f ${f}; then ${CP} -p ${f}.N ${f}; fi
|
|
|
|
.endfor
|
2008-01-17 10:48:55 +01:00
|
|
|
${MKDIR} ${EXAMPLESDIR}
|
|
|
|
${INSTALL_DATA} ${FILESDIR}/lpt-cupsd.conf ${EXAMPLESDIR}/
|
2006-12-06 10:39:28 +01:00
|
|
|
${INSTALL} -d ${CUPS_SPOOLDIR}/tmp/
|
|
|
|
${CHOWN} -R ${CUPSOWN}:${CUPSGRP} ${CUPS_SPOOLDIR}/
|
|
|
|
${CHMOD} -R g+w ${CUPS_SPOOLDIR}/
|
2007-03-25 10:50:50 +02:00
|
|
|
${INSTALL} -d /var/cache/cups/
|
|
|
|
${CHOWN} root:${CUPSGRP} /var/cache/cups/
|
2009-05-07 12:04:18 +02:00
|
|
|
.endif
|
|
|
|
|
2009-05-16 12:04:10 +02:00
|
|
|
.if defined(CUPS_CLIENT)
|
2009-05-07 15:59:11 +02:00
|
|
|
post-install:
|
|
|
|
${INSTALL_SCRIPT} ${WRKSRC}/cups-config ${PREFIX}/bin/
|
|
|
|
${INSTALL_DATA} ${WRKSRC}/cups/libcups.a ${PREFIX}/lib/
|
|
|
|
${INSTALL_MAN} ${WRKSRC}/man/cups-config.man ${PREFIX}/man/man1/cups-config.1
|
2009-05-07 12:04:18 +02:00
|
|
|
.endif
|
2003-02-02 23:21:07 +01:00
|
|
|
|
2006-08-06 11:13:36 +02:00
|
|
|
.include <bsd.port.post.mk>
|