SecBSD's official ports repository
This commit is contained in:
commit
2c0afcbbf3
64331 changed files with 5339189 additions and 0 deletions
85
print/foomatic-db-engine/Makefile
Normal file
85
print/foomatic-db-engine/Makefile
Normal file
|
@ -0,0 +1,85 @@
|
|||
COMMENT= Foomatic PPD generator
|
||||
|
||||
DISTNAME= foomatic-db-engine-4.0.13
|
||||
CATEGORIES= print
|
||||
REVISION= 4
|
||||
|
||||
HOMEPAGE= http://www.linux-foundation.org/en/OpenPrinting/Database/Foomatic
|
||||
|
||||
MAINTAINER= Antoine Jacoutot <ajacoutot@openbsd.org>
|
||||
|
||||
# GPLv2
|
||||
PERMIT_PACKAGE= Yes
|
||||
|
||||
WANTLIB += c iconv m lzma pthread xml2 z
|
||||
|
||||
MASTER_SITES= https://www.openprinting.org/download/foomatic/
|
||||
|
||||
LIB_DEPENDS= converters/libiconv \
|
||||
textproc/libxml
|
||||
RUN_DEPENDS= databases/p5-DBI \
|
||||
curl-*|wget-*:net/curl
|
||||
|
||||
# Cannot read file /usr/local/share/foomatic/db/oldprinterids!
|
||||
RUN_DEPENDS += print/foomatic-db
|
||||
|
||||
USE_GMAKE= Yes
|
||||
NO_TEST= Yes
|
||||
|
||||
CONFIGURE_STYLE= gnu
|
||||
CONFIGURE_ARGS= --disable-gscheck
|
||||
CONFIGURE_ENV= CPPFLAGS="-I${LOCALBASE}/include -I${LOCALBASE}/include/libxml2" \
|
||||
LDFLAGS="-L${LOCALBASE}/lib" \
|
||||
LIBDIR="${LOCALBASE}/share/foomatic" \
|
||||
FOOMATIC_RIP="${LOCALBASE}/libexec/cups/filter/foomatic-rip" \
|
||||
GS="${LOCALBASE}/bin/gs" \
|
||||
A2PS="${LOCALBASE}/bin/a2ps" \
|
||||
GS="${LOCALBASE}/bin/gs" \
|
||||
WGET="${LOCALBASE}/bin/wget" \
|
||||
CURL="${LOCALBASE}/bin/curl" \
|
||||
SMBCLIENT="${LOCALBASE}/bin/smbclient" \
|
||||
DEVFD3="|/bin/cat >&3" \
|
||||
DEVFD0="-" \
|
||||
LPD_SPOOL="/var/spool/output" \
|
||||
LPD_LOG="/var/log/lpd-errs" \
|
||||
LPD_BIN="/usr/sbin/lpd" \
|
||||
LPD_LPR="/usr/bin/lpr" \
|
||||
LPD_LPQ="/usr/bin/lpq" \
|
||||
LPD_LPRM="/usr/bin/lprm" \
|
||||
LPD_LPC="/usr/sbin/lpc" \
|
||||
LPRNG_CHECKPC="${LOCALBASE}/sbin/checkpc" \
|
||||
CUPS_ETC="${SYSCONFDIR}/cups" \
|
||||
CUPS_ADMIN="${LOCALBASE}/sbin/lpadmin" \
|
||||
CUPS_LPSTAT="${LOCALBASE}/bin/lpstat" \
|
||||
CUPS_PPDS="${LOCALBASE}/share/cups/model" \
|
||||
CUPS_FILTERS="${LOCALBASE}/libexec/cups/filter" \
|
||||
CUPS_BACKENDS="${LOCALBASE}/libexec/cups/backend" \
|
||||
CUPS_CONF="${SYSCONFDIR}/cups/printers.conf" \
|
||||
CUPS_LPR="${LOCALBASE}/bin/lpr" \
|
||||
CUPS_LPQ="${LOCALBASE}/bin/lpq" \
|
||||
CUPS_LPRM="${LOCALBASE}/bin/lprm" \
|
||||
CUPS_LPC="${LOCALBASE}/sbin/lpc" \
|
||||
CUPS_LP="${LOCALBASE}/bin/lp" \
|
||||
CUPS_CANCEL="${LOCALBASE}/bin/cancel" \
|
||||
CUPS_ENABLE="${LOCALBASE}/sbin/cupsenable" \
|
||||
CUPS_DISABLE="${LOCALBASE}/sbin/cupsdisable" \
|
||||
CUPS_ACCEPT="${LOCALBASE}/sbin/cupsaccept" \
|
||||
CUPS_REJECT="${LOCALBASE}/sbin/cupsreject" \
|
||||
CUPS_LPMOVE="${LOCALBASE}/sbin/lpmove" \
|
||||
CUPS_LPOPTIONS="${LOCALBASE}/bin/lpoptions" \
|
||||
CUPS_LPINFO="${LOCALBASE}/sbin/lpinfo" \
|
||||
CUPS_PCONF="${SYSCONFDIR}/cups/printers.conf" \
|
||||
PERLPREFIX="${LOCALBASE}" \
|
||||
PRINTCAP="/etc/printcap"
|
||||
|
||||
pre-configure:
|
||||
${SUBST_CMD} ${WRKSRC}/foomatic-combo-xml.c \
|
||||
${WRKSRC}/Makefile.in ${WRKSRC}/configure
|
||||
|
||||
# make CUPS generate Foomatic PPDs on demand (see patch-Makefile_in)
|
||||
post-install:
|
||||
${INSTALL_DATA_DIR} ${PREFIX}/libexec/cups/driver
|
||||
ln -sf ${TRUEPREFIX}/bin/foomatic-ppdfile \
|
||||
${WRKINST}/${LOCALBASE}/libexec/cups/driver/foomatic
|
||||
|
||||
.include <bsd.port.mk>
|
2
print/foomatic-db-engine/distinfo
Normal file
2
print/foomatic-db-engine/distinfo
Normal file
|
@ -0,0 +1,2 @@
|
|||
SHA256 (foomatic-db-engine-4.0.13.tar.gz) = tciQJ6omln0ubbYuKvfbDEA50kgNT78kdqbdz2CaX68=
|
||||
SIZE (foomatic-db-engine-4.0.13.tar.gz) = 360631
|
39
print/foomatic-db-engine/patches/patch-Makefile_in
Normal file
39
print/foomatic-db-engine/patches/patch-Makefile_in
Normal file
|
@ -0,0 +1,39 @@
|
|||
--- Makefile.in.orig Fri Feb 18 13:30:22 2011
|
||||
+++ Makefile.in Fri Apr 15 20:45:20 2011
|
||||
@@ -187,13 +187,9 @@ check-config:
|
||||
install-bin: check-config lib/Makefile
|
||||
# This is the only way to get the Perl-generated Makefile using
|
||||
# $(DESTDIR) properly
|
||||
- ( cd lib && \
|
||||
- $(MAKE) PREFIX=$(PERLPREFIX) && \
|
||||
- $(MAKE) PREFIX=$(PERLPREFIX) DESTDIR=$(DESTDIR) pure_install \
|
||||
- )
|
||||
+ cd lib && $(MAKE) PREFIX=$(PERLPREFIX) pure_install
|
||||
${SRC}/mkinstalldirs $(DESTDIR)$(BINDIR)
|
||||
${SRC}/mkinstalldirs $(DESTDIR)$(SBINDIR)
|
||||
- ${SRC}/mkinstalldirs $(DESTDIR)$(ETCDIR)
|
||||
${SRC}/mkinstalldirs $(DESTDIR)$(LIBDIR)/templates
|
||||
${INSTALL} -m 755 $(BINFILES) $(DESTDIR)$(BINDIR)
|
||||
${INSTALL} -m 755 $(SBINFILES) $(DESTDIR)$(SBINDIR)
|
||||
@@ -204,13 +200,6 @@ install-bin: check-config lib/Makefile
|
||||
# Link to allow foomatic-ppdfile be called under the old name
|
||||
# foomatic-datafile
|
||||
ln -sf foomatic-ppdfile $(DESTDIR)$(BINDIR)/foomatic-datafile
|
||||
-# Link foomatic-ppdfile to the CUPS 1.2 PPD generator directory,
|
||||
-# so that the cups-driverd automatically generates Foomatic PPDs
|
||||
-# on demand (/usr/lib/cups/driver).
|
||||
- if [ -d $(LIB_CUPS) ]; then \
|
||||
- ${SRC}/mkinstalldirs $(DESTDIR)$(CUPS_DRIVER); \
|
||||
- ln -sf $(BINDIR)/foomatic-ppdfile $(DESTDIR)$(CUPS_DRIVER)/foomatic; \
|
||||
- fi
|
||||
|
||||
install-man: check-config
|
||||
${SRC}/mkinstalldirs $(DESTDIR)$(MANDIR)
|
||||
@@ -226,6 +215,7 @@ build: defaults lib/Makefile foomatic-combo-xml foomat
|
||||
$(PERL) -p -i -e "s=use lib '.*lib/';\n==s" $$m; \
|
||||
done
|
||||
chmod a+rx $(AC_OUTPUT_FILES) mkinstalldirs
|
||||
+ cd lib && $(MAKE) PREFIX=$(PERLPREFIX)
|
||||
|
||||
lib/Makefile: lib/Makefile.PL
|
||||
( cd lib && $(PERL) Makefile.PL verbose INSTALLDIRS=$(PERL_INSTALLDIRS) )
|
68
print/foomatic-db-engine/patches/patch-configure
Normal file
68
print/foomatic-db-engine/patches/patch-configure
Normal file
|
@ -0,0 +1,68 @@
|
|||
Index: configure
|
||||
--- configure.orig
|
||||
+++ configure
|
||||
@@ -3717,15 +3717,15 @@ LIBS="$save_LIBS"
|
||||
|
||||
# Checks for programs/directories which are used by Foomtic
|
||||
|
||||
-SPOOLSEARCHPATH=/var/spool:/usr/spool/:/usr/local/spool:/usr/local/var/spool:/var/local/spool:/var/local
|
||||
-LOGSEARCHPATH=/var/log:/usr/log:/usr/local/log:/usr/local/var/log:/var/local/log:/var/local
|
||||
-SYSCONFSEARCHPATH=/etc:/usr/etc:/usr/local/etc:/var/etc
|
||||
-SBINSEARCHPATH=/usr/sbin:/sbin:/usr/local/sbin:/etc/sbin
|
||||
-BINSEARCHPATH=/usr/bin:/bin:/usr/local/bin
|
||||
-DATASEARCHPATH=/usr/share:/usr/local/share:$libdir:/usr/local/lib:/opt
|
||||
-LIBSEARCHPATH=$libdir:/lib:/usr/local/lib:/usr/local/libexec:/opt
|
||||
-PTALPIPESSEARCHPATH=/var/run:/var:/var/ptal:/usr/var/run:/usr/var:/usr/var/ptal:/usr/local/var/run:/usr/local/var:/usr/local/var/ptal:/dev:/dev/ptal
|
||||
-MTINKPIPESSEARCHPATH=/var:/var/run:/usr/var/:/usr/var/run:/usr/local/var:/usr/local/var/run:/dev
|
||||
+SPOOLSEARCHPATH=/var/spool
|
||||
+LOGSEARCHPATH=/var/log
|
||||
+SYSCONFSEARCHPATH=${SYSCONFDIR}
|
||||
+SBINSEARCHPATH=/usr/sbin:/sbin:${LOCALBASE}/sbin:/etc/sbin
|
||||
+BINSEARCHPATH=/usr/bin:/bin:${LOCALBASE}/bin
|
||||
+DATASEARCHPATH=/usr/share:${LOCALBASE}/share:/usr/lib:${LOCALBASE}/lib
|
||||
+LIBSEARCHPATH=/usr/lib:/lib:${LOCALBASE}/lib:${LOCALBASE}/libexec
|
||||
+PTALPIPESSEARCHPATH=/var/run
|
||||
+MTINKPIPESSEARCHPATH=/var/run
|
||||
|
||||
# There is a bug in some versions of autoconf that causes
|
||||
# bad expansion of paths in the AC_PATH_* macros. This is very annoying
|
||||
@@ -4210,7 +4210,7 @@ fi
|
||||
|
||||
|
||||
# Check for bourne shell
|
||||
-for ac_prog in bash sh
|
||||
+for ac_prog in sh
|
||||
do
|
||||
# Extract the first word of "$ac_prog", so it can be a program name with args.
|
||||
set dummy $ac_prog; ac_word=$2
|
||||
@@ -5668,8 +5668,8 @@ fi
|
||||
done
|
||||
test -n "$CUPS_LPINFO" || CUPS_LPINFO="/usr/sbin/lpinfo"
|
||||
|
||||
-
|
||||
# Paths for PDQ
|
||||
+if [ x"$with_pdq" = x"yes" ]; then
|
||||
for ac_dir in pdq
|
||||
do
|
||||
# Extract the first word of "$ac_dir", so it can be a program name with args.
|
||||
@@ -5804,9 +5804,11 @@ fi
|
||||
test -n "$PDQ_PRINT" && break
|
||||
done
|
||||
test -n "$PDQ_PRINT" || PDQ_PRINT="/usr/bin/pdq"
|
||||
+fi # with_pdq = yes
|
||||
|
||||
|
||||
# Paths for PPR
|
||||
+if [ x"$with_ppr" = x"yes" ]; then
|
||||
for ac_prog in ppr/bin/pprd
|
||||
do
|
||||
# Extract the first word of "$ac_prog", so it can be a program name with args.
|
||||
@@ -6119,7 +6121,7 @@ fi
|
||||
test -n "$PPR_PPOP" && break
|
||||
done
|
||||
test -n "$PPR_PPOP" || PPR_PPOP="/usr/bin/ppop"
|
||||
-
|
||||
+fi # with_ppr = yes
|
||||
|
||||
|
||||
# Other paths
|
11
print/foomatic-db-engine/patches/patch-foomatic-combo-xml_c
Normal file
11
print/foomatic-db-engine/patches/patch-foomatic-combo-xml_c
Normal file
|
@ -0,0 +1,11 @@
|
|||
--- foomatic-combo-xml.c.orig Fri Feb 18 13:30:22 2011
|
||||
+++ foomatic-combo-xml.c Fri Apr 15 20:45:20 2011
|
||||
@@ -2225,7 +2225,7 @@ main(int argc, /* I - Number of command-line argu
|
||||
/* Set libdir to the default if empty */
|
||||
|
||||
if (libdir == NULL)
|
||||
- libdir = "/usr/share/foomatic";
|
||||
+ libdir = "${LOCALBASE}/share/foomatic";
|
||||
|
||||
/* Load translation table for old printer IDs */
|
||||
sprintf(oldidfilename, "%s/db/oldprinterids",
|
11
print/foomatic-db-engine/patches/patch-foomatic-kitload_in
Normal file
11
print/foomatic-db-engine/patches/patch-foomatic-kitload_in
Normal file
|
@ -0,0 +1,11 @@
|
|||
--- foomatic-kitload.in.orig Thu Oct 10 18:16:12 2002
|
||||
+++ foomatic-kitload.in Mon Jun 21 23:55:22 2004
|
||||
@@ -54,7 +54,7 @@ $ENV{'LC_ALL'} = "C";
|
||||
$ENV{'LANG'} = "C";
|
||||
|
||||
# Copy the files
|
||||
-my $retval = system("( cd $dir ; tar cf - --exclude CVS . ) | tar xv${dontoverwrite}Cf $destdir$libdir/db/source - 2> $destdir$libdir/kitload2.log | tee $destdir$libdir/kitload.log");
|
||||
+my $retval = system("( cd $dir ; find . \! -path \*CVS\* | pax -rwdv$dontoverwrite $destdir$libdir/db/source ) 2>&1 | tee $destdir$libdir/kitload.log 2> $destdir$libdir/kitload2.log");
|
||||
#$retval = $retval / 256;
|
||||
#if ($retval) {
|
||||
# die "Error copying files to $destdir$libdir/db/source: $?";
|
28
print/foomatic-db-engine/patches/patch-lib_Foomatic_DB_pm
Normal file
28
print/foomatic-db-engine/patches/patch-lib_Foomatic_DB_pm
Normal file
|
@ -0,0 +1,28 @@
|
|||
From 75de02d9065b6280482d7cd011e9462badb19f83 Mon Sep 17 00:00:00 2001
|
||||
From: Andreas Gruenbacher <agruenba@redhat.com>
|
||||
Date: Thu, 30 Jan 2020 23:08:23 +0100
|
||||
Subject: [PATCH] Recognize fractional numbers in PageSize
|
||||
|
||||
Index: lib/Foomatic/DB.pm
|
||||
--- lib/Foomatic/DB.pm.orig
|
||||
+++ lib/Foomatic/DB.pm
|
||||
@@ -4032,7 +4032,7 @@ sub getppd ( $ $ $ ) {
|
||||
# option.
|
||||
my $size = $v->{'driverval'};
|
||||
if ($size =~ /([\d\.]+)x([\d\.]+)([a-z]+)\b/) {
|
||||
- # 2 positive integers separated by
|
||||
+ # 2 positive numbers separated by
|
||||
# an 'x' with a unit
|
||||
my $w = $1;
|
||||
my $h = $2;
|
||||
@@ -4050,8 +4050,8 @@ sub getppd ( $ $ $ ) {
|
||||
$w = sprintf("%.2f", $w) if $w =~ /\./;
|
||||
$h = sprintf("%.2f", $h) if $h =~ /\./;
|
||||
$size = "$w $h";
|
||||
- } elsif (($size =~ /(\d+)[x\s]+(\d+)/) ||
|
||||
- # 2 positive integers separated by
|
||||
+ } elsif (($size =~ /([\d\.]+)[x\s]+([\d\.]+)/) ||
|
||||
+ # 2 positive numbers separated by
|
||||
# whitespace or an 'x'
|
||||
($size =~ /\-dDEVICEWIDTHPOINTS\=(\d+)\s+\-dDEVICEHEIGHTPOINTS\=(\d+)/)) {
|
||||
# "-dDEVICEWIDTHPOINTS=..."/"-dDEVICEHEIGHTPOINTS=..."
|
3
print/foomatic-db-engine/pkg/DESCR
Normal file
3
print/foomatic-db-engine/pkg/DESCR
Normal file
|
@ -0,0 +1,3 @@
|
|||
Foomatic's database engine generates PPD files from the data in
|
||||
Foomatic's XML database. It also contains scripts to directly generate
|
||||
print queues and handle jobs.
|
44
print/foomatic-db-engine/pkg/PLIST
Normal file
44
print/foomatic-db-engine/pkg/PLIST
Normal file
|
@ -0,0 +1,44 @@
|
|||
@bin bin/foomatic-combo-xml
|
||||
bin/foomatic-compiledb
|
||||
bin/foomatic-configure
|
||||
bin/foomatic-datafile
|
||||
@bin bin/foomatic-perl-data
|
||||
bin/foomatic-ppd-options
|
||||
bin/foomatic-ppd-to-xml
|
||||
bin/foomatic-ppdfile
|
||||
bin/foomatic-printjob
|
||||
bin/foomatic-searchprinter
|
||||
libdata/perl5/site_perl/Foomatic/
|
||||
libdata/perl5/site_perl/Foomatic/DB.pm
|
||||
libdata/perl5/site_perl/Foomatic/Defaults.pm
|
||||
libdata/perl5/site_perl/Foomatic/PPD.pm
|
||||
libdata/perl5/site_perl/Foomatic/UIElem.pm
|
||||
libexec/cups/
|
||||
libexec/cups/driver/
|
||||
libexec/cups/driver/foomatic
|
||||
@man man/man1/foomatic-combo-xml.1
|
||||
@man man/man1/foomatic-compiledb.1
|
||||
@man man/man1/foomatic-configure.1
|
||||
@man man/man1/foomatic-perl-data.1
|
||||
@man man/man1/foomatic-ppd-options.1
|
||||
@man man/man1/foomatic-ppdfile.1
|
||||
@man man/man1/foomatic-printjob.1
|
||||
@man man/man8/foomatic-addpjloptions.8
|
||||
@man man/man8/foomatic-getpjloptions.8
|
||||
@man man/man8/foomatic-kitload.8
|
||||
@man man/man8/foomatic-preferred-driver.8
|
||||
sbin/foomatic-addpjloptions
|
||||
sbin/foomatic-cleanupdrivers
|
||||
sbin/foomatic-extract-text
|
||||
sbin/foomatic-fix-xml
|
||||
sbin/foomatic-getpjloptions
|
||||
sbin/foomatic-kitload
|
||||
sbin/foomatic-nonumericalids
|
||||
sbin/foomatic-preferred-driver
|
||||
sbin/foomatic-printermap-to-gutenprint-xml
|
||||
sbin/foomatic-replaceoldprinterids
|
||||
share/doc/pkg-readmes/${PKGSTEM}
|
||||
share/foomatic/templates/
|
||||
share/foomatic/templates/pjl_enum_choice.xml
|
||||
share/foomatic/templates/pjl_enum_option.xml
|
||||
share/foomatic/templates/pjl_num_option.xml
|
25
print/foomatic-db-engine/pkg/README
Normal file
25
print/foomatic-db-engine/pkg/README
Normal file
|
@ -0,0 +1,25 @@
|
|||
+-----------------------------------------------------------------------
|
||||
| Running ${PKGSTEM} on OpenBSD
|
||||
+-----------------------------------------------------------------------
|
||||
|
||||
When using the Foomatic framework, printers are driven by a PPD (Printer
|
||||
Postscript Description) file which, unless already provided in a
|
||||
particular package, can be generated using the foomatic-ppdfile(1)
|
||||
command.
|
||||
Drivers availability depends on which Foomatic DB package are installed
|
||||
on the system:
|
||||
e.g. foomatic-db, hpijs, foo2zjs, gutenprint...
|
||||
|
||||
PPD generation example for a Samsung ML-2850D
|
||||
=============================================
|
||||
$ foomatic-ppdfile -P 2850
|
||||
Samsung ML-2850D Id='Samsung-ML-2850D' Driver='Postscript' CompatibleDrivers='Postscript pxlmono '
|
||||
$ foomatic-ppdfile -p 'Samsung-ML-2850D' -d 'Postscript' > samsung-ml2850d.ppd
|
||||
|
||||
"samsung-ml2850d.ppd" can then be used as an input filter with CUPS or
|
||||
for direct printing using foomatic-rip(1) from the cups-filters package.
|
||||
|
||||
Printers using CUPS native drivers (drv) or for which only schema definitions
|
||||
(xml) but no ppd exist will not be detected by foomatic-ppdfile(1) and must
|
||||
be installed using the CUPS tools, the CUPS web interface or native utilities
|
||||
(e.g. cups-genppd(8) from gutenprint).
|
Loading…
Add table
Add a link
Reference in a new issue