Skip to content

Instantly share code, notes, and snippets.

@funilrys
Last active May 18, 2020 14:51
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save funilrys/bdd8889c7dd873597627737bb80c1faf to your computer and use it in GitHub Desktop.
Save funilrys/bdd8889c7dd873597627737bb80c1faf to your computer and use it in GitHub Desktop.
cnijfilter2-bin
post_install() {
_cups_path1=/usr/share/ppd
_cups_path2=/usr/share/cups/model
if [ -x /sbin/ldconfig ]; then
/sbin/ldconfig
fi
# make symbolic link for ppd
if [ ! -d ${_cups_path2} ]; then
mkdir ${_cups_path2}
fi
ln -fs ${_cups_path1}/* ${_cups_path2}
systemctl restart org.cups.cupsd.service
echo "Successfully installed. Visit http://localhost:631/ to configure printers using CUPS."
}
post_upgrade() {
post_install
}
upstreamName=cnijfilter2
pkgname=${upstreamName}-bin
pkgver=5.90
pkgrel=0
pkgdesc="Binaries for canon printers. Tested for Pixma MX492"
arch=('x86_64')
url="https://www.usa.canon.com"
license=('GNU General Public License v2')
depends=('cups' 'ghostscript')
options=('!emptydirs' '!strip')
install=$pkgname.install
source=("cnijfilter2-${pkgver}_amd64.deb::https://gdlp01.c-wss.com/gds/2/0100010482/01/$upstreamName-$pkgver-1-deb.tar.gz")
md5sums=('368cf7466336eb77d4f8661e01be5da3')
package() {
msg2 "Extracting the common debian archive."
ar vx "cnijfilter2-${pkgver}-1-deb/packages/cnijfilter2_${pkgver}-1_amd64.deb"
msg2 "Extracting the data.tar.gz component of the debian archive."
tar xzvf data.tar.gz -C "$pkgdir/"
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment