openbsd-ports/print/hplip/patches/patch-check_py
2012-06-26 06:17:11 +00:00

49 lines
2.4 KiB
Plaintext

$OpenBSD: patch-check_py,v 1.7 2012/06/26 06:17:11 ajacoutot Exp $
--- check.py.orig Mon Jun 18 12:44:13 2012
+++ check.py Tue Jun 26 07:24:00 2012
@@ -114,9 +114,9 @@ def get_comment(package, Inst_status, installed_ver):
comment = "Python Programming is not supported if version is lessthan 2.2"
elif package == 'hpaio':
if Inst_status == 'OK':
- comment = "'hpaio found in /etc/sane.d/dll.conf'"
+ comment = "'hpaio found in ${SYSCONFDIR}/sane.d/dll.conf'"
else:
- comment = "'hpaio not found in /etc/sane.d/dll.conf. hpaio needs to be added in this file.'"
+ comment = "'hpaio not found in ${SYSCONFDIR}/sane.d/dll.conf. hpaio needs to be added in this file.'"
elif package == 'cupsext' or package == 'pcardext' or package == 'hpmudext':
if Inst_status != 'OK':
comment = "'Not Found or Failed to load, Please reinstall HPLIP'"
@@ -506,9 +506,9 @@ try:
log.info()
- log.info(log.bold("Current contents of '/etc/hp/hplip.conf' file:"))
+ log.info(log.bold("Current contents of '${SYSCONFDIR}/hp/hplip.conf' file:"))
try:
- output = file('/etc/hp/hplip.conf', 'r').read()
+ output = file('${SYSCONFDIR}/hp/hplip.conf', 'r').read()
except (IOError, OSError), e:
log.error("Could not access file: %s. Check HPLIP installation." % e.strerror)
num_errors += 1
@@ -516,9 +516,9 @@ try:
log.info(output)
log.info()
- log.info(log.bold("Current contents of '/var/lib/hp/hplip.state' file:"))
+ log.info(log.bold("Current contents of '/var/db/hp/hplip.state' file:"))
try:
- output = file(os.path.expanduser('/var/lib/hp/hplip.state'), 'r').read()
+ output = file(os.path.expanduser('/var/db/hp/hplip.state'), 'r').read()
except (IOError, OSError), e:
log.info("Plugins are not installed. Could not access file: %s" % e.strerror)
else:
@@ -716,7 +716,7 @@ try:
#log.info("Installed in HPLIP?: %s" % x)
log.info("Device URI: %s" % device_uri)
- ppd = os.path.join('/etc/cups/ppd', printer_name + '.ppd')
+ ppd = os.path.join('${SYSCONFDIR}/cups/ppd', printer_name + '.ppd')
if os.path.exists(ppd):
log.info("PPD: %s" % ppd)