From owner-svn-ports-head@FreeBSD.ORG Mon May 12 19:11:27 2014 Return-Path: Delivered-To: svn-ports-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 9713C570; Mon, 12 May 2014 19:11:27 +0000 (UTC) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 8438E250E; Mon, 12 May 2014 19:11:27 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.8/8.14.8) with ESMTP id s4CJBRjF003402; Mon, 12 May 2014 19:11:27 GMT (envelope-from rene@svn.freebsd.org) Received: (from rene@localhost) by svn.freebsd.org (8.14.8/8.14.8/Submit) id s4CJBRHJ003400; Mon, 12 May 2014 19:11:27 GMT (envelope-from rene@svn.freebsd.org) Message-Id: <201405121911.s4CJBRHJ003400@svn.freebsd.org> From: Rene Ladan Date: Mon, 12 May 2014 19:11:27 +0000 (UTC) To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r353887 - head/print/cups-pdf X-SVN-Group: ports-head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-ports-head@freebsd.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: SVN commit messages for the ports tree for head List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 12 May 2014 19:11:27 -0000 Author: rene Date: Mon May 12 19:11:26 2014 New Revision: 353887 URL: http://svnweb.freebsd.org/changeset/ports/353887 QAT: https://qat.redports.org/buildarchive/r353887/ Log: - Add stage support [1] - Add option support [1] - Trim COMMENT - Strip binary - Use @sample keyword in pkg-plist - Do not try to remove etc/cups owned by dependency PR: ports/189682 [1] Submitted by: Matthieu Volat Modified: head/print/cups-pdf/Makefile head/print/cups-pdf/pkg-plist Modified: head/print/cups-pdf/Makefile ============================================================================== --- head/print/cups-pdf/Makefile Mon May 12 18:15:08 2014 (r353886) +++ head/print/cups-pdf/Makefile Mon May 12 19:11:26 2014 (r353887) @@ -10,7 +10,7 @@ MASTER_SITES= http://www.cups-pdf.de/src DISTNAME= ${PORTNAME}_${PORTVERSION} MAINTAINER= ports@FreeBSD.org -COMMENT= A virtual printer for CUPS to produce PDF files +COMMENT= Virtual printer for CUPS to produce PDF files LICENSE=GPLv2 LICENSE_FILE=${WRKSRC}/COPYING @@ -21,6 +21,11 @@ WRKSRC= ${WRKDIR}/${PORTNAME}-${PORTVER USE_GHOSTSCRIPT_RUN= yes +OPTIONS_DEFINE= DOCS +OPTIONS_DEFAULT= DOCS + +.include + SUBST_CMD= -e "s,\#GhostScript /usr/bin/gs,GhostScript ${LOCALBASE}/bin/gs," \ -e 's,\#GSTmp /var/tmp,GSTmp /tmp,' \ -e 's,\#Grp lp,Grp daemon,' \ @@ -49,7 +54,6 @@ SUBST_CMD+= -e 's,\#Out /var/spool/cups- SUBST_CMD+= -e "s,\#Log /var/log/cups,Log ${LOG_DIRECTORY}," .endif -NO_STAGE= yes pre-everything:: .if !defined(PDF_VERSION) || !defined(HOME_SUBDIR) || \ !defined(OUTPUT_DIRECTORY) || !defined(LOG_DIRECTORY) @@ -82,23 +86,18 @@ do-build: cd ${WRKSRC}/src; ${CC} ${CFLAGS} -o cups-pdf cups-pdf.c do-install: - ${MKDIR} ${PREFIX}/libexec/cups/backend - ${INSTALL} -o root -g wheel -m 0700 ${WRKSRC}/src/cups-pdf ${PREFIX}/libexec/cups/backend - ${MKDIR} ${PREFIX}/share/cups/model + ${MKDIR} ${STAGEDIR}${PREFIX}/libexec/cups/backend + ${INSTALL} ${WRKSRC}/src/cups-pdf ${STAGEDIR}${PREFIX}/libexec/cups/backend + ${STRIP_CMD} ${STAGEDIR}${PREFIX}/libexec/cups/backend/cups-pdf + ${MKDIR} ${STAGEDIR}${PREFIX}/share/cups/model ${INSTALL_DATA} ${WRKSRC}/extra/CUPS-PDF.ppd \ - ${PREFIX}/share/cups/model/CUPS-PDF.ppd - ${MKDIR} ${PREFIX}/etc/cups - ${INSTALL_DATA} ${WRKSRC}/extra/cups-pdf.conf \ - ${PREFIX}/etc/cups/cups-pdf.conf.sample -.if !defined(NOPORTDOCS) - ${MKDIR} ${DOCSDIR} - ${INSTALL_DATA} ${WRKSRC}/README ${DOCSDIR}/ -.endif + ${STAGEDIR}${PREFIX}/share/cups/model/CUPS-PDF.ppd + ${MKDIR} ${STAGEDIR}${PREFIX}/etc/cups + ${MKDIR} ${STAGEDIR}${DOCSDIR} + ${INSTALL_DATA} ${WRKSRC}/README ${STAGEDIR}${DOCSDIR}/ post-install: - @if [ ! -f ${PREFIX}/etc/cups/cups-pdf.conf ]; then \ - ${CP} -p ${PREFIX}/etc/cups/cups-pdf.conf.sample \ - ${PREFIX}/etc/cups/cups-pdf.conf ; \ - fi + ${INSTALL_DATA} ${WRKSRC}/extra/cups-pdf.conf \ + ${STAGEDIR}${PREFIX}/etc/cups/cups-pdf.conf.sample .include Modified: head/print/cups-pdf/pkg-plist ============================================================================== --- head/print/cups-pdf/pkg-plist Mon May 12 18:15:08 2014 (r353886) +++ head/print/cups-pdf/pkg-plist Mon May 12 19:11:26 2014 (r353887) @@ -1,11 +1,10 @@ +@mode 0700 libexec/cups/backend/cups-pdf +@mode share/cups/model/CUPS-PDF.ppd -@unexec if cmp -s %D/etc/cups/cups-pdf.conf.sample %D/etc/cups/cups-pdf.conf; then rm -f %D/etc/cups/cups-pdf.conf; fi -etc/cups/cups-pdf.conf.sample -@exec if [ ! -f %D/etc/cups/cups-pdf.conf ] ; then cp -p %D/%F %B/cups-pdf.conf; fi +@sample etc/cups/cups-pdf.conf.sample %%PORTDOCS%%%%DOCSDIR%%/README %%PORTDOCS%%@dirrm %%DOCSDIR%% @dirrmtry libexec/cups/backend @dirrmtry libexec/cups @dirrmtry share/cups -@dirrmtry etc/cups