mirror of
https://git.FreeBSD.org/ports.git
synced 2024-12-22 04:17:44 +00:00
print/cups-pdf: Update to 3.0.1
Changelog: https://www.cups-pdf.de/changelog.shtml - Sort variables & improve style. - Prefix some local variables with an underscore. - Change the way PDF versions are handled (although the whole mechanism of changing a configuration file via custom port variables should probably be deprecated).
This commit is contained in:
parent
ce701cda42
commit
a1234f77d7
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=527186
@ -2,8 +2,7 @@
|
||||
# $FreeBSD$
|
||||
|
||||
PORTNAME= cups-pdf
|
||||
PORTVERSION= 2.6.1
|
||||
PORTREVISION= 4
|
||||
DISTVERSION= 3.0.1
|
||||
CATEGORIES= print
|
||||
MASTER_SITES= http://www.cups-pdf.de/src/ \
|
||||
http://www.physik.uni-wuerzburg.de/~vrbehr/cups-pdf/src/
|
||||
@ -15,42 +14,43 @@ COMMENT= Virtual printer for CUPS to produce PDF files
|
||||
LICENSE= GPLv2
|
||||
LICENSE_FILE= ${WRKSRC}/COPYING
|
||||
|
||||
LIB_DEPENDS= libcups.so:print/cups
|
||||
RUN_DEPENDS= ${LOCALBASE}/sbin/cupsd:print/cups
|
||||
|
||||
USES= ghostscript:run localbase
|
||||
|
||||
LIBS+= -lcups
|
||||
|
||||
ETCDIR= ${PREFIX}/etc/cups
|
||||
|
||||
WRKSRC= ${WRKDIR}/${PORTNAME}-${PORTVERSION}
|
||||
|
||||
USES= ghostscript:run
|
||||
|
||||
OPTIONS_DEFINE= DOCS
|
||||
|
||||
SUBST_CMD= -e "s,\#GhostScript /usr/bin/gs,GhostScript ${LOCALBASE}/bin/gs," \
|
||||
_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,' \
|
||||
-e 's,\#Spool /var/spool/cups-pdf/SPOOL,Spool /var/spool/cups-pdf,'
|
||||
|
||||
_PDF_VERSIONS= 1.2 1.3 1.4 1.5
|
||||
|
||||
.include <bsd.port.options.mk>
|
||||
|
||||
.ifdef(PDF_VERSION)
|
||||
.if ${PDF_VERSION} == 1.2
|
||||
.elif ${PDF_VERSION} == 1.3
|
||||
.elif ${PDF_VERSION} == 1.4
|
||||
.elif ${PDF_VERSION} == 1.5
|
||||
.else
|
||||
.if "${_PDF_VERSIONS:M${PDF_VERSION}}" == ""
|
||||
BROKEN= Unsupported PDF-Version selected: ${PDF_VERSION}
|
||||
.endif
|
||||
SUBST_CMD+= -e "s,\#PDFVer 1.4,PDFVer ${PDF_VERSION},"
|
||||
_SUBST_CMD+= -e "s,\#PDFVer 1.4,PDFVer ${PDF_VERSION},"
|
||||
.endif
|
||||
|
||||
.ifdef(HOME_SUBDIR)
|
||||
SUBST_CMD+= -e 's,\#Out /var/spool/cups-pdf/$${USER},Out $${HOME}/${HOME_SUBDIR},'
|
||||
.else
|
||||
.ifdef(OUTPUT_DIRECTORY)
|
||||
SUBST_CMD+= -e 's,\#Out /var/spool/cups-pdf/$${USER},Out ${OUTPUT_DIRECTORY},'
|
||||
.endif
|
||||
_SUBST_CMD+= -e 's,\#Out /var/spool/cups-pdf/$${USER},Out $${HOME}/${HOME_SUBDIR},'
|
||||
.elifdef(OUTPUT_DIRECTORY)
|
||||
_SUBST_CMD+= -e 's,\#Out /var/spool/cups-pdf/$${USER},Out ${OUTPUT_DIRECTORY},'
|
||||
.endif
|
||||
|
||||
.ifdef(LOG_DIRECTORY)
|
||||
SUBST_CMD+= -e "s,\#Log /var/log/cups,Log ${LOG_DIRECTORY},"
|
||||
_SUBST_CMD+= -e "s,\#Log /var/log/cups,Log ${LOG_DIRECTORY},"
|
||||
.endif
|
||||
|
||||
pre-everything::
|
||||
@ -61,7 +61,7 @@ pre-everything::
|
||||
@${ECHO_MSG} ""
|
||||
.endif
|
||||
.if !defined(PDF_VERSION)
|
||||
@${ECHO_MSG} "PDF_VERSION=1.2|1.3|1.4|1.5 PDF-version of PDF-files produced"
|
||||
@${ECHO_MSG} "PDF_VERSION=${_PDF_VERSIONS:S/ /|/Wg} PDF-version of PDF-files produced"
|
||||
.endif
|
||||
.if !defined(HOME_SUBDIR)
|
||||
@${ECHO_MSG} "HOME_SUBDIR=<subdir> Place produced PDF-files in the"
|
||||
@ -76,25 +76,28 @@ pre-everything::
|
||||
.endif
|
||||
|
||||
post-configure:
|
||||
@${REINPLACE_CMD} ${SUBST_CMD} ${WRKSRC}/extra/cups-pdf.conf
|
||||
@${REINPLACE_CMD} ${_SUBST_CMD} ${WRKSRC}/extra/cups-pdf.conf
|
||||
@${REINPLACE_CMD} -e \
|
||||
's,CPCONFIG "/etc/cups/cups-pdf.conf",CPCONFIG "${PREFIX}/etc/cups/cups-pdf.conf",' \
|
||||
's,CPCONFIG "/etc/cups/cups-pdf.conf",CPCONFIG "${ETCDIR}/cups-pdf.conf",' \
|
||||
${WRKSRC}/src/cups-pdf.h
|
||||
|
||||
do-build:
|
||||
cd ${WRKSRC}/src && ${CC} ${CFLAGS} ${LDFLAGS} -o cups-pdf cups-pdf.c
|
||||
(cd ${WRKSRC}/src && \
|
||||
${CC} ${CFLAGS} ${LDFLAGS} ${LIBS} -o cups-pdf cups-pdf.c)
|
||||
|
||||
do-install:
|
||||
@${MKDIR} ${STAGEDIR}${PREFIX}/libexec/cups/backend
|
||||
${INSTALL_PROGRAM} ${WRKSRC}/src/cups-pdf ${STAGEDIR}${PREFIX}/libexec/cups/backend
|
||||
${INSTALL_PROGRAM} ${WRKSRC}/src/cups-pdf \
|
||||
${STAGEDIR}${PREFIX}/libexec/cups/backend/
|
||||
@${MKDIR} ${STAGEDIR}${PREFIX}/share/cups/model
|
||||
${INSTALL_DATA} ${WRKSRC}/extra/CUPS-PDF.ppd \
|
||||
${STAGEDIR}${PREFIX}/share/cups/model/CUPS-PDF.ppd
|
||||
@${MKDIR} ${STAGEDIR}${PREFIX}/etc/cups
|
||||
${INSTALL_DATA} ${WRKSRC}/extra/CUPS-PDF_opt.ppd \
|
||||
${WRKSRC}/extra/CUPS-PDF_noopt.ppd \
|
||||
${STAGEDIR}${PREFIX}/share/cups/model/
|
||||
@${MKDIR} ${STAGEDIR}${ETCDIR}
|
||||
${INSTALL_DATA} ${WRKSRC}/extra/cups-pdf.conf \
|
||||
${STAGEDIR}${PREFIX}/etc/cups/cups-pdf.conf.sample
|
||||
${STAGEDIR}${ETCDIR}/cups-pdf.conf.sample
|
||||
|
||||
do-install-DOCS-on:
|
||||
post-install-DOCS-on:
|
||||
@${MKDIR} ${STAGEDIR}${DOCSDIR}
|
||||
${INSTALL_DATA} ${WRKSRC}/README ${STAGEDIR}${DOCSDIR}/
|
||||
|
||||
|
@ -1,2 +1,3 @@
|
||||
SHA256 (cups-pdf_2.6.1.tar.gz) = 04e17eb563dceea048e1a435edcbcf52faa5288f85e8390cd64d702edb6745f1
|
||||
SIZE (cups-pdf_2.6.1.tar.gz) = 33315
|
||||
TIMESTAMP = 1582725313
|
||||
SHA256 (cups-pdf_3.0.1.tar.gz) = 738669edff7f1469fe5e411202d87f93ba25b45f332a623fb607d49c59aa9531
|
||||
SIZE (cups-pdf_3.0.1.tar.gz) = 29754
|
||||
|
@ -1,6 +1,7 @@
|
||||
@sample %%ETCDIR%%/cups-pdf.conf.sample
|
||||
@mode 0700
|
||||
libexec/cups/backend/cups-pdf
|
||||
@mode
|
||||
share/cups/model/CUPS-PDF.ppd
|
||||
@sample etc/cups/cups-pdf.conf.sample
|
||||
share/cups/model/CUPS-PDF_opt.ppd
|
||||
share/cups/model/CUPS-PDF_noopt.ppd
|
||||
%%PORTDOCS%%%%DOCSDIR%%/README
|
||||
|
Loading…
Reference in New Issue
Block a user