foomatic-db-engine:moved into main for pisi 2.0
This commit is contained in:
@@ -0,0 +1,33 @@
|
||||
#!/usr/bin/python
|
||||
# -*- coding: utf-8 -*-
|
||||
#
|
||||
# Licensed under the GNU General Public License, version 3.
|
||||
# See the file http://www.gnu.org/licenses/gpl.txt
|
||||
|
||||
from pisi.actionsapi import get
|
||||
from pisi.actionsapi import autotools
|
||||
from pisi.actionsapi import pisitools
|
||||
from pisi.actionsapi import shelltools
|
||||
from pisi.actionsapi import perlmodules
|
||||
|
||||
def setup():
|
||||
# The LANG vars aren't reset early enough so when sed tries to use [a-zA-Z], it borks
|
||||
shelltools.export("LC_ALL", "C")
|
||||
shelltools.export("LANG", "C")
|
||||
|
||||
autotools.autoconf()
|
||||
autotools.configure()
|
||||
|
||||
def build():
|
||||
autotools.make()
|
||||
|
||||
def install():
|
||||
autotools.rawInstall("DESTDIR=%s" % get.installDIR())
|
||||
|
||||
shelltools.cd("lib")
|
||||
perlmodules.configure()
|
||||
perlmodules.make()
|
||||
perlmodules.install()
|
||||
shelltools.cd("..")
|
||||
|
||||
pisitools.dodoc("ChangeLog", "COPYING", "README", "TODO", "USAGE")
|
||||
@@ -0,0 +1,56 @@
|
||||
case "$1" in
|
||||
configure)
|
||||
# Do the following only if CUPS is running and the needed CUPS tools
|
||||
# are available
|
||||
if which lpstat > /dev/null 2>&1 && \
|
||||
which lpinfo > /dev/null 2>&1 && \
|
||||
which lpadmin > /dev/null 2>&1 && \
|
||||
lpstat -r > /dev/null 2>&1; then
|
||||
# Update the PPD files of all already installed print queues
|
||||
driverregexp='^foomatic:'
|
||||
gennicknameregexp=''
|
||||
[ ! -z "$gennicknameregexp" ] && \
|
||||
gennicknameregexp="; $gennicknameregexp"
|
||||
gennicknameregexp='s/\s*\(recommended\)//'"$gennicknameregexp"
|
||||
tempfiles=
|
||||
trap 'rm -f $tempfiles; exit 0' 0 1 2 13 15
|
||||
tmpfile1=`mktemp -t updateppds.XXXXXX`
|
||||
tempfiles="$tempfiles $tmpfile1"
|
||||
lpinfo -m | grep -E $driverregexp > $tmpfile1
|
||||
cd /etc/cups/ppd
|
||||
for ppd in `ls -1 *.ppd 2>/dev/null`; do
|
||||
queue=${ppd%.ppd}
|
||||
nickname=`grep '\*NickName:' $ppd | cut -d '"' -f 2 | perl -p -e 's/\n$//' | perl -p -e "$gennicknameregexp" | perl -p -e 's/(\W)/\\\\$1/g'`
|
||||
lang=`grep '\*LanguageVersion:' $ppd | cut -d ' ' -f 2 | perl -e 'print lc(<>)' | perl -p -e 's/[\r\n]//gs'`
|
||||
ppdfound="0"
|
||||
englishppduri=""
|
||||
tmpfile2=`mktemp -t updateppds.XXXXXX`
|
||||
tempfiles="$tempfiles $tmpfile2"
|
||||
cat $tmpfile1 | perl -p -e "$gennicknameregexp" | grep -E '^\S+\s+.*'"$nickname"'$' | cut -d ' ' -f 1 > $tmpfile2
|
||||
while read newppduri; do
|
||||
[ "$ppdfound" = "0" ] && lpadmin -p $queue -m $newppduri
|
||||
newlang=`grep '\*LanguageVersion:' $ppd | cut -d ' ' -f 2 | perl -e 'print lc(<>)' | perl -p -e 's/[\r\n]//gs'`
|
||||
[ "$newlang" = "$lang" ] && ppdfound="1"
|
||||
[ "$newlang" = "english" ] && englishppduri="$newppduri"
|
||||
done < $tmpfile2
|
||||
[ "$ppdfound" = "0" ] && [ ! -z "$englishppduri" ] && lpadmin -p $queue -m $englishppduri && ppdfound="1"
|
||||
[ "$ppdfound" = "1" ] && echo PPD for printer $queue updated >&2
|
||||
done
|
||||
fi
|
||||
;;
|
||||
|
||||
abort-upgrade|abort-remove|abort-deconfigure)
|
||||
;;
|
||||
|
||||
*)
|
||||
echo "postinst called with unknown argument \`$1'" >&2
|
||||
exit 1
|
||||
;;
|
||||
esac
|
||||
|
||||
# dh_installdeb will replace this with shell code automatically
|
||||
# generated by other debhelper scripts.
|
||||
|
||||
#DEBHELPER#
|
||||
|
||||
exit 0
|
||||
@@ -0,0 +1,13 @@
|
||||
diff --git a/Makefile.in b/Makefile.in
|
||||
index 3014185..81e090d 100644
|
||||
--- a/Makefile.in
|
||||
+++ b/Makefile.in
|
||||
@@ -42,7 +42,7 @@ LOCAL_LIBDIR=@LOCAL_LIBDIR@
|
||||
FOOMATIC_RIP=@FOOMATIC_RIP@
|
||||
|
||||
# foomatic-rip path for a "make inplace" installation
|
||||
-LOCAL_FOOMATIC_RIP=@LOCAL_FOOMATIC_RIP@
|
||||
+LOCAL_FOOMATIC_RIP=@FOOMATIC_RIP@
|
||||
|
||||
# Locations for installing the components of this package
|
||||
BINDIR=$(bindir)
|
||||
@@ -0,0 +1,15 @@
|
||||
--- foomatic-db-engine-4.0.2/Makefile.in.orig 2009-07-23 11:45:28.487999828 +0200
|
||||
+++ foomatic-db-engine-4.0.2/Makefile.in 2009-07-23 11:45:53.939525006 +0200
|
||||
@@ -231,10 +231,10 @@
|
||||
( cd lib && $(PERL) Makefile.PL verbose INSTALLDIRS=$(PERL_INSTALLDIRS) )
|
||||
|
||||
foomatic-combo-xml: foomatic-combo-xml.c
|
||||
- $(CC) $(CFLAGS) -o foomatic-combo-xml foomatic-combo-xml.c
|
||||
+ $(CC) $(CFLAGS) $(LDFLAGS) -o foomatic-combo-xml foomatic-combo-xml.c
|
||||
|
||||
foomatic-perl-data: foomatic-perl-data.c
|
||||
- $(CC) $(CFLAGS) $(XML_CFLAGS) -o foomatic-perl-data foomatic-perl-data.c $(XML_LIBS)
|
||||
+ $(CC) $(CFLAGS) $(LDFLAGS) -o foomatic-perl-data foomatic-perl-data.c $(XML_CFLAGS) $(XML_LIBS)
|
||||
|
||||
man: lib/Foomatic/Defaults.pm
|
||||
chmod a+rx ./makeMan
|
||||
@@ -0,0 +1,30 @@
|
||||
--- configure.ac.OSmanOS 2011-07-25 12:51:20.000000000 +0300
|
||||
+++ configure.ac 2012-11-20 13:21:36.921307899 +0200
|
||||
@@ -163,27 +163,6 @@
|
||||
fi
|
||||
|
||||
|
||||
-AC_MSG_CHECKING(how to redirect Ghostscript output to fd 3)
|
||||
-if test "$DEVFD3" = "" ; then
|
||||
- v=`( if test -d /dev/fd ; then echo 3 >/dev/fd/3; fi) 3>&1 1>&2`
|
||||
- if test "$v" != "" ; then
|
||||
- DEVFD3=/dev/fd/3
|
||||
- DEVFD0=/dev/fd/0
|
||||
- else
|
||||
- DEVFD3="|$CAT >&3"
|
||||
- DEVFD0=-
|
||||
- fi
|
||||
- if test "$GS" != "GHOSTSCRIPT_NOT_FOUND" -a "$GSCHECK" != "no" ; then
|
||||
- rm -f gs_out
|
||||
- gs -q -dBATCH -dNOPAUSE -dSAFER -dPARANOIDSAFER -sDEVICE=laserjet "-sOutputFile=$DEVFD3" ${srcdir}/gsPrint 3>gs_out
|
||||
- if test "!" -s gs_out ; then
|
||||
- AC_MSG_ERROR("ERROR - gs cannot handle -sOutputFile=$OUT" )
|
||||
- fi
|
||||
- fi
|
||||
-fi
|
||||
-AC_MSG_RESULT(using $DEVFD3)
|
||||
-AC_SUBST(DEVFD3)
|
||||
-AC_SUBST(DEVFD0)
|
||||
|
||||
# Check for Perl
|
||||
AC_PATH_PROGS(PERL,perl,/usr/bin/perl,$BINSEARCHPATH)
|
||||
@@ -0,0 +1,27 @@
|
||||
diff -Nur foomatic-db-engine-3.0-20061031-old/Makefile.in foomatic-db-engine-3.0-20061031/Makefile.in
|
||||
--- foomatic-db-engine-3.0-20061031-old/Makefile.in 2006-11-08 10:33:59.000000000 +0200
|
||||
+++ foomatic-db-engine-3.0-20061031/Makefile.in 2006-11-08 10:38:44.000000000 +0200
|
||||
@@ -42,7 +42,7 @@
|
||||
FOOMATIC_RIP=@FOOMATIC_RIP@
|
||||
|
||||
# foomatic-rip path for a "make inplace" installation
|
||||
-LOCAL_FOOMATIC_RIP=@LOCAL_FOOMATIC_RIP@
|
||||
+LOCAL_FOOMATIC_RIP=@FOOMATIC_RIP@
|
||||
|
||||
# Locations for installing the components of this package
|
||||
BINDIR=$(bindir)
|
||||
@@ -186,10 +186,10 @@
|
||||
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=$(DESTDIR)$(PERLPREFIX) pure_install \
|
||||
- )
|
||||
+# ( cd lib && \
|
||||
+# $(MAKE) PREFIX=$(PERLPREFIX) && \
|
||||
+# $(MAKE) PREFIX=$(DESTDIR)$(PERLPREFIX) pure_install \
|
||||
+# )
|
||||
${SRC}/mkinstalldirs $(DESTDIR)$(BINDIR)
|
||||
${SRC}/mkinstalldirs $(DESTDIR)$(SBINDIR)
|
||||
${SRC}/mkinstalldirs $(DESTDIR)$(ETCDIR)
|
||||
@@ -0,0 +1,87 @@
|
||||
<?xml version="1.0" ?>
|
||||
<!DOCTYPE PISI SYSTEM "http://www.pisilinux.org/projeler/pisi/pisi-spec.dtd">
|
||||
<PISI>
|
||||
<Source>
|
||||
<Name>foomatic-db-engine</Name>
|
||||
<Homepage>http://www.linuxprinting.org/</Homepage>
|
||||
<Packager>
|
||||
<Name>PisiLinux Community</Name>
|
||||
<Email>admins@pisilinux.org</Email>
|
||||
</Packager>
|
||||
<License>GPLv2</License>
|
||||
<IsA>app:console</IsA>
|
||||
<Summary>Foomatic printer database engine</Summary>
|
||||
<Description>foomatic-db-engine is the layer that provides the database engine to Foomatic.</Description>
|
||||
<Archive sha1sum="c3b747113b6a64b998000774e7c2d03ce48654c1" type="targz">http://www.openprinting.org/download/foomatic/foomatic-db-engine-4.0.12.tar.gz</Archive>
|
||||
<BuildDependencies>
|
||||
<Dependency>libxml2-devel</Dependency>
|
||||
<Dependency>cups-devel</Dependency>
|
||||
</BuildDependencies>
|
||||
<Patches>
|
||||
<Patch level="0">foomatic-db-engine-4.0.8-fix-sandbox.patch</Patch>
|
||||
<Patch level="1">4.0.7-perl-module.patch</Patch>
|
||||
<Patch level="1">4.0.7-respect-ldflag.patch</Patch>
|
||||
</Patches>
|
||||
</Source>
|
||||
|
||||
<Package>
|
||||
<Name>foomatic-db-engine</Name>
|
||||
<RuntimeDependencies>
|
||||
<Dependency>libxml2</Dependency>
|
||||
</RuntimeDependencies>
|
||||
<Files>
|
||||
<Path fileType="executable">/usr/bin</Path>
|
||||
<Path fileType="executable">/usr/sbin</Path>
|
||||
<Path fileType="library">/usr/lib</Path>
|
||||
<Path fileType="config">/etc/foomatic</Path>
|
||||
<Path fileType="data">/usr/share/foomatic/templates</Path>
|
||||
<Path fileType="man">/usr/share/man</Path>
|
||||
<Path fileType="doc">/usr/share/doc</Path>
|
||||
</Files>
|
||||
</Package>
|
||||
|
||||
<History>
|
||||
<Update release="6">
|
||||
<Date>2015-10-28</Date>
|
||||
<Version>4.0.12</Version>
|
||||
<Comment>v.bump</Comment>
|
||||
<Name>Ayhan Yalçınsoy</Name>
|
||||
<Email>ayhanyalcinsoy@pisilinux.org</Email>
|
||||
</Update>
|
||||
<Update release="5">
|
||||
<Date>2014-09-13</Date>
|
||||
<Version>4.0.11</Version>
|
||||
<Comment>Rebuild for new perl.</Comment>
|
||||
<Name>Serdar Soytetir</Name>
|
||||
<Email>kaptan@pisilinux.org</Email>
|
||||
</Update>
|
||||
<Update release="4">
|
||||
<Date>2014-06-15</Date>
|
||||
<Version>4.0.11</Version>
|
||||
<Comment>Version bump.</Comment>
|
||||
<Name>Marcin Bojara</Name>
|
||||
<Email>marcin@pisilinux.org</Email>
|
||||
</Update>
|
||||
<Update release="3">
|
||||
<Date>2014-02-05</Date>
|
||||
<Version>4.0.8</Version>
|
||||
<Comment>Depend on cups-filters.</Comment>
|
||||
<Name>PisiLinux Community</Name>
|
||||
<Email>admins@pisilinux.org</Email>
|
||||
</Update>
|
||||
<Update release="2">
|
||||
<Date>2013-12-01</Date>
|
||||
<Version>4.0.8</Version>
|
||||
<Comment>Rebuild for new perl.</Comment>
|
||||
<Name>PisiLinux Community</Name>
|
||||
<Email>admins@pisilinux.org</Email>
|
||||
</Update>
|
||||
<Update release="1">
|
||||
<Date>2012-11-19</Date>
|
||||
<Version>4.0.8</Version>
|
||||
<Comment>First release</Comment>
|
||||
<Name>PisiLinux Community</Name>
|
||||
<Email>admins@pisilinux.org</Email>
|
||||
</Update>
|
||||
</History>
|
||||
</PISI>
|
||||
@@ -0,0 +1,8 @@
|
||||
<?xml version="1.0" ?>
|
||||
<PISI>
|
||||
<Source>
|
||||
<Name>foomatic-db-engine</Name>
|
||||
<Summary xml:lang="tr">Foomatic yazıcı veritabanı motoru</Summary>
|
||||
<Description xml:lang="tr">foomatic-db-engine, Foomatic veritabanı motorunu oluşturan katmandır.</Description>
|
||||
</Source>
|
||||
</PISI>
|
||||
Reference in New Issue
Block a user