From d150a5f3e462fa7fe194a805a4aa0076f4d03ab9 Mon Sep 17 00:00:00 2001 From: Deposite Pirate Date: Sun, 16 Sep 2018 18:48:36 +0200 Subject: Add ports. --- print/hplip/hplip-3.13.5-cups161fix.patch.xz | Bin 0 -> 2632 bytes print/hplip/hplip-3.13.5-desktopfile.patch.xz | Bin 0 -> 552 bytes print/hplip/hplip-3.13.5-libnotify.patch.xz | Bin 0 -> 352 bytes print/hplip/hplip-3.13.5-typo.patch.xz | Bin 0 -> 396 bytes print/hplip/hplip.build | 123 ++++++++++++++++++++++++++ 5 files changed, 123 insertions(+) create mode 100644 print/hplip/hplip-3.13.5-cups161fix.patch.xz create mode 100644 print/hplip/hplip-3.13.5-desktopfile.patch.xz create mode 100644 print/hplip/hplip-3.13.5-libnotify.patch.xz create mode 100644 print/hplip/hplip-3.13.5-typo.patch.xz create mode 100755 print/hplip/hplip.build (limited to 'print/hplip') diff --git a/print/hplip/hplip-3.13.5-cups161fix.patch.xz b/print/hplip/hplip-3.13.5-cups161fix.patch.xz new file mode 100644 index 0000000..63dbc24 Binary files /dev/null and b/print/hplip/hplip-3.13.5-cups161fix.patch.xz differ diff --git a/print/hplip/hplip-3.13.5-desktopfile.patch.xz b/print/hplip/hplip-3.13.5-desktopfile.patch.xz new file mode 100644 index 0000000..87292ce Binary files /dev/null and b/print/hplip/hplip-3.13.5-desktopfile.patch.xz differ diff --git a/print/hplip/hplip-3.13.5-libnotify.patch.xz b/print/hplip/hplip-3.13.5-libnotify.patch.xz new file mode 100644 index 0000000..b72df06 Binary files /dev/null and b/print/hplip/hplip-3.13.5-libnotify.patch.xz differ diff --git a/print/hplip/hplip-3.13.5-typo.patch.xz b/print/hplip/hplip-3.13.5-typo.patch.xz new file mode 100644 index 0000000..8b28786 Binary files /dev/null and b/print/hplip/hplip-3.13.5-typo.patch.xz differ diff --git a/print/hplip/hplip.build b/print/hplip/hplip.build new file mode 100755 index 0000000..37ffcfa --- /dev/null +++ b/print/hplip/hplip.build @@ -0,0 +1,123 @@ +#!/bin/bash +# +# Maintainer: Deposite Pirate + +source /usr/src/ports/Build/build.sh + +NAME=hplip +VERSION=3.13.5 +BUILD=1 +DEPENDS=('ghostscript >= 9.06-1' 'snmp >= 5.7.2-1' 'dbus >= 1.6.8-1') +OPTDEPENDS=('usb >= 1.0.15-1' 'cups >= 1.6.2-1' 'python >= 2.7.4-1') + +# Description + +cat > ${PKG}/install/slack-desc <> ${PKG}/install/doinst.sh </dev/null 2>&1 +fi +EOF + +# Sources + +SRCNAME[0]=${NAME} +SRCVERS[0]=${VERSION} +SRCPACK[0]=${URL[sf]}/${SRCNAME[0]}/${SRCNAME[0]}/${SRCVERS[0]}/${SRCNAME[0]}-${SRCVERS[0]}.tar.gz +SRCCOPY[0]="GPL2 BSD3 MIT" + +build0() +{ +find . -type f -exec sed -i 's~^#.*env python~#!/usr/bin/env python2~' {} + +find . -name "*.py" -exec sed -i '1s|#!/usr/bin/python|#!/usr/bin/python2|' {} + +sed -i 's|python ./print.py|python2 ./print.py|' scan.py +sed -i 's|python ./testpage.py|python2 ./testpage.py|' setup.py +sed -i 's|python ./setup.py|python2 ./setup.py|' ui4/devmgr5.py ui4/nodevicesdialog.py +sed -i 's|python %HOME%|python2 %HOME%|' base/utils.py +sed -i 's|python ./plugin.py|python2 ./plugin.py|' base/pkit.py +# https://bugs.archlinux.org/task/30085 - hack found in Gentoo +# Use system foomatic-rip for hpijs driver instead of foomatic-rip-hplip +# The hpcups driver does not use foomatic-rip +( + cd ppd/hpijs + for file in *.ppd.gz; do + rm -f ${file}.temp + gunzip -c ${file} | sed 's|foomatic-rip-hplip|foomatic-rip|g' | gzip > ${file}.temp + mv ${file}.temp ${file} + done +) +#LIBS="-Wl,--as-needed $(pkg-config libusb --libs)" +export PYTHON=python2 +sed -i 's|/usr/lib/systemd/system|/usr/share/systemd/system|g' Makefile.{am,in} +CFLAGS="${FLAGS}" CXXFLAGS="${FLAGS}" \ +./configure \ + --build="${ARCH}-slackware-linux" \ + --host="${ARCH}-slackware-linux" \ + --disable-dependency-tracking \ + --enable-static=no \ + --enable-shared=yes \ + --prefix=/usr \ + --mandir="${SYS_DIR[man]}" \ + --sysconfdir="${SYS_DIR[etc]}" \ + --libdir="${SYS_DIR[lib]}" \ + --localstatedir="${SYS_DIR[var]}" \ + --docdir="${SYS_DIR[html]}/${SRCNAME[0]}" \ + --with-docdir="${SYS_DIR[html]}/${SRCNAME[0]}" \ + --with-cupsbackenddir="${SYS_DIR[lib]}/exec/cups/backend" \ + --with-cupsfilterdir="${SYS_DIR[lib]}/exec/cups/filter" \ + --with-hpppddir="${SYS_DIR[share]}/cups/model/HP" \ + --with-drvdir="${SYS_DIR[share]}/cups/drv/hp" \ + --disable-foomatic-rip-hplip-install \ + --enable-foomatic-ppd-install \ + --enable-foomatic-drv-install \ + --enable-hpcups-install \ + --enable-new-hpcups \ + --enable-pp-build \ + --enable-cups-ppd-install \ + --enable-cups-drv-install \ + --enable-hpijs-install \ + --enable-network-build=yes \ + --enable-shadow-build \ + --disable-scan-build \ + --enable-gui-build \ + --enable-fax-build \ + --enable-qt4 \ + --enable-policykit \ + --enable-udev-acl-rules +#FIXME: --enable-scan-build when we have sane +#FIXME: PAM +make ${JOBS} +make install DESTDIR="${PKG}" rulesdir="${SYS_DIR[udevrules]}" +mv \ + ${PKG}${SYS_DIR[etc]}/cron.daily/hplip_cron \ + ${PKG}${SYS_DIR[etc]}/cron.daily/hplip +# Log dir should not be world writeable +chmod 775 \ + ${PKG}${SYS_DIR[var]}/log/{hp,hp/tmp} +rm -rf \ + ${PKG}${SYS_DIR[etc]}/{sane.d,xdg} \ + ${PKG}${SYS_DIR[share]}/hal +} -- cgit v1.2.3-70-g09d2