Also fixes multiples issues:
- broken plugins:
- `fax_marvell.so file is not present or symbolic link is missing`
- `lj.so library file doesn't have user/group execute permission.`
- `bb_escl.so file is not present or symbolic link is missing`
- multiple error during configuration phase which prevented `*.ppd`
generation:
- `ppdc: Unable to find include file "<font.defs>"`
- patched configure time `perl` script
- patched use of `file`
- some potentially problematic filter and services:
- patched reference to ghost script and fonts dir in filter.
- patched usb configuration service.
- patch scripts so that they refer to valid location.
Add some options:
- `withStaticPPDInstall`: Install `*.ppd` files along with `*.drv`.
When true, configure outputs: `checking for cups ppd install... yes`.
We cannot rely on wrapPythonPrograms to wrap the installed executables because
they are symlinks (which it ignores). Instead, we have to emulate it to make
the wrappers ourselves.
* hplip: introduce nettools dependency
Some HP printers (notably a HP MFP M477fnw) need to run `hostname` as part of
the printing process. This executable is provided by the "nettools" package.
* hplip: prepend nettools to PATH
A full wrap isn't needed as these scripts are only run from within
hplip's own environment, and unwanted because they are imported
as Python modules.
Also fix a reference to /etc in $out/etc/hp/hplip.conf, though I've no
idea whether it is actually used.
Something changed in the generic fixupPhase magic exposing a bug
in the previous fix (wrapPythonPrograms where I should have used
wrapPythonProgramsIn).
Also move buildInputs and friends to a more conventional spot.
None of the installed tools like hp-align or hp-toolbox could
work, because they tried to import wrapped Python scripts (i.e.
shell code) as Python modules. Fix this by:
- Substituting `dbus` for the defective `pythonDBus`.
- No longer blindly wrapping all python files, but replacing
the original symlinks in $out/bin with wrapper scripts.
These wrappers then `exec` the unmodified Python scripts in
$out/share/hplip directly, instead of the .<name>-wrapped
copy that wrapPythonProgramsIn creates. The latter are simply
removed.
Sure, it's a bit ugly. It's also 2015 and I couldn't use my
printer :-/