1 # Maintainer: Andreas Radke <andyrtr@archlinux.org>
4 pkgname=('foomatic-db' 'foomatic-db-ppds' 'foomatic-db-nonfree' 'foomatic-db-nonfree-ppds')
10 makedepends=('cups' 'perl' 'libxml2' 'enscript' 'perl' 'net-snmp' 'bash' 'git')
11 url="http://www.linuxprinting.org/foomatic.html"
12 options=('!emptydirs')
14 # check https://github.com/OpenPrinting/foomatic-db
15 # for latest commits and development, currently identical to foomatic-4.0 branch
17 source=(foomatic-db::git+https://github.com/OpenPrinting/foomatic-db#commit=b35c73eafe139f5943e07ac1512abbf5a4a4b753 #2022-11-16
18 foomatic-db-nonfree::git+https://github.com/OpenPrinting/foomatic-db-nonfree#commit=6ddae02ac89240c019f8b5026cfe70e30fd2b3db #2015-06-05
28 cp -a foomatic-db foomatic-db-ppds
29 cp -a foomatic-db-nonfree foomatic-db-nonfree-ppds
36 ./configure --prefix=/usr \
38 --disable-ppds-to-cups \
39 --with-drivers=NOOBSOLETES,NOEMPTYCMDLINE
43 pushd foomatic-db-ppds
45 ./configure --prefix=/usr
49 pushd foomatic-db-nonfree
51 ./configure --prefix=/usr
54 # foomatic-db-nonfree-ppds
55 pushd foomatic-db-nonfree-ppds
57 ./configure --prefix=/usr
61 package_foomatic-db() {
63 pkgdesc="Foomatic - The collected knowledge about printers, drivers, and driver options in XML files, used by foomatic-db-engine to generate PPD files."
64 license=('GPL' 'custom')
65 optdepends=('foomatic-db-ppds: PostScript PPD files')
66 replaces=('foomatic-db-foo2zjs') # AUR pkg no more conflicting and dropped, formerly required by foo2zjs-utils
67 conflicts=('foomatic-db-foo2zjs')
68 provides=('foomatic-db-foo2zjs')
70 cd "${srcdir}"/foomatic-db
71 make DESTDIR="${pkgdir}" install
74 install -Dm644 USAGE "${pkgdir}"/usr/share/doc/${pkgname}/USAGE
75 install -Dm644 README "${pkgdir}"/usr/share/doc/${pkgname}/README
76 install -v -Dm644 "${srcdir}"/${pkgname}/COPYING "${pkgdir}"/usr/share/licenses/${pkgname}/COPYING
77 install -Dm644 "${pkgdir}"/usr/share/foomatic/db/source/PPD/Kyocera/ReadMe.htm "${pkgdir}"/usr/share/doc/${pkgname}/Kyocera/ReadMe.htm
78 # remove files from foomatic-db-ppds pkg
79 rm -rf "${pkgdir}"/usr/share/cups/model/foomatic-db-ppds
80 rm -rf "${pkgdir}"/usr/share/foomatic/db/source/PPD
83 package_foomatic-db-ppds() {
85 pkgdesc="Foomatic - PPDs from printer manufacturers"
86 license=('GPL' 'custom')
88 cd "${srcdir}"/foomatic-db-ppds
89 make DESTDIR="${pkgdir}" install
91 # remove files from foomatic-db pkg
92 rm -rf "${pkgdir}"/usr/share/foomatic/db/oldprinterids
93 rm -rf "${pkgdir}"/usr/share/foomatic/db/source/{driver,opt,printer}
94 rm -rf "${pkgdir}"/usr/share/foomatic/xmlschema
95 rm -f "${pkgdir}"/usr/share/foomatic/db/source/PPD/Kyocera/ReadMe.htm
97 install -v -Dm644 "${srcdir}"/${pkgname}/COPYING "${pkgdir}"/usr/share/licenses/${pkgname}/COPYING
100 package_foomatic-db-nonfree() {
102 pkgdesc="Foomatic - database extension consisting of manufacturer-supplied PPD files released under non-free licenses"
104 optdepends=('foomatic-db-nonfree-ppds: nonfree PPD files')
106 cd ${srcdir}/foomatic-db-nonfree
107 make DESTDIR="${pkgdir}" install
108 # remove files from foomatic-db-nonfree-ppds pkg
109 rm -rf "${pkgdir}"/usr/share/foomatic/db/source/PPD
111 install -Dm644 COPYING "${pkgdir}"/usr/share/licenses/${pkgname}/COPYING
114 package_foomatic-db-nonfree-ppds() {
116 pkgdesc="Foomatic - non-free PPDs from printer manufacturers"
119 cd ${srcdir}/foomatic-db-nonfree-ppds
120 make DESTDIR="${pkgdir}" install
121 # remove files from foomatic-db-nonfree pkg
122 rm -rf "${pkgdir}"/usr/share/foomatic/db/source/driver
124 install -Dm644 COPYING "${pkgdir}"/usr/share/licenses/${pkgname}/COPYING