patch-check_py 3.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061
  1. $OpenBSD: patch-check_py,v 1.18 2016/05/05 08:25:31 ajacoutot Exp $
  2. --- check.py.orig Wed May 4 07:23:31 2016
  3. +++ check.py Thu May 5 10:02:31 2016
  4. @@ -139,9 +139,9 @@ def get_comment(package, Inst_status, installed_ver):
  5. comment = "Python Programming is not supported if version is lessthan 2.2"
  6. elif package == 'hpaio':
  7. if Inst_status == 'OK':
  8. - comment = "'hpaio found in /etc/sane.d/dll.conf'"
  9. + comment = "'hpaio found in ${SYSCONFDIR}/sane.d/dll.conf'"
  10. else:
  11. - comment = "'hpaio not found in /etc/sane.d/dll.conf. hpaio needs to be added in this file.'"
  12. + comment = "'hpaio not found in ${SYSCONFDIR}/sane.d/dll.conf. hpaio needs to be added in this file.'"
  13. elif package == 'cupsext' or package == 'pcardext' or package == 'hpmudext':
  14. if Inst_status != 'OK':
  15. comment = "'Not Found or Failed to load, Please reinstall HPLIP'"
  16. @@ -308,9 +308,9 @@ class DependenciesCheck(object):
  17. %(self.core.distro, self.core.distro_version, self.core.distro, supported_distro_vrs)))
  18. tui.header("SYSTEM INFO")
  19. - Sts, Kernel_info =utils.run("uname -r -v -o")
  20. + Sts, Kernel_info =utils.run("uname -r -v -s")
  21. Sts, Host_info =utils.run("uname -n")
  22. - Sts, Proc_info =utils.run("uname -r -v -o")
  23. + Sts, Proc_info =utils.run("uname -r -v -s")
  24. log.info(" Kernel: %s Host: %s Proc: %s Distribution: %s %s"\
  25. %(Kernel_info,Host_info,Proc_info,self.core.distro, self.core.distro_version))
  26. log.info(" Bitness: %s bit\n"%utils.getBitness())
  27. @@ -326,9 +326,9 @@ class DependenciesCheck(object):
  28. log.warn("HPLIP-Installation: Auto installation is not supported for %s distro %s version " %(self.core.distro, self.core.distro_version))
  29. log.info()
  30. - log.info(log.bold("Current contents of '/etc/hp/hplip.conf' file:"))
  31. + log.info(log.bold("Current contents of '${SYSCONFDIR}/hp/hplip.conf' file:"))
  32. try:
  33. - output = open('/etc/hp/hplip.conf', 'r').read()
  34. + output = open('${SYSCONFDIR}/hp/hplip.conf', 'r').read()
  35. except (IOError, OSError) as e:
  36. log.error("Could not access file: %s. Check HPLIP installation." % e.strerror)
  37. self.num_errors += 1
  38. @@ -336,9 +336,9 @@ class DependenciesCheck(object):
  39. log.info(output)
  40. log.info()
  41. - log.info(log.bold("Current contents of '/var/lib/hp/hplip.state' file:"))
  42. + log.info(log.bold("Current contents of '/var/db/hp/hplip.state' file:"))
  43. try:
  44. - output = open(os.path.expanduser('/var/lib/hp/hplip.state'), 'r').read()
  45. + output = open(os.path.expanduser('/var/db/hp/hplip.state'), 'r').read()
  46. except (IOError, OSError) as e:
  47. log.info("Plugins are not installed. Could not access file: %s" % e.strerror)
  48. else:
  49. @@ -502,7 +502,7 @@ class DependenciesCheck(object):
  50. #log.info("Installed in HPLIP?: %s" % x)
  51. log.info("Device URI: %s" % device_uri)
  52. - ppd = os.path.join('/etc/cups/ppd', printer_name + '.ppd')
  53. + ppd = os.path.join('${SYSCONFDIR}/cups/ppd', printer_name + '.ppd')
  54. if os.path.exists(ppd):
  55. log.info("PPD: %s" % ppd)