unofficial mirror of bug-guix@gnu.org 
 help / color / mirror / code / Atom feed
From: Efraim Flashner <efraim@flashner.co.il>
To: "Ludovic Courtès" <ludo@gnu.org>
Cc: 33300@debbugs.gnu.org
Subject: bug#33300: hplip 3.18.9 contains non-free binary blobs
Date: Wed, 7 Nov 2018 14:48:58 +0200	[thread overview]
Message-ID: <20181107124858.GE1206@macbook41> (raw)
In-Reply-To: <87sh0dur48.fsf@gnu.org>

[-- Attachment #1: Type: text/plain, Size: 4378 bytes --]

On Wed, Nov 07, 2018 at 11:19:35AM +0100, Ludovic Courtès wrote:
> Hello,
> 
> The tarball of hplip 3.18.9 contains several .so files that it installs
> as-is:
> 
> --8<---------------cut here---------------start------------->8---
> ludo@ribbon ~/src/guix$ (cd /tmp; tar xf $(guix build -S hplip))
> ludo@ribbon ~/src/guix$ find /tmp/hplip-3.18.9 -name \*.so
> /tmp/hplip-3.18.9/prnt/plugins/hbpl1-arm32.so
> /tmp/hplip-3.18.9/prnt/plugins/hbpl1-x86_64.so
> /tmp/hplip-3.18.9/prnt/plugins/lj-x86_32.so
> /tmp/hplip-3.18.9/prnt/plugins/hbpl1-arm64.so
> /tmp/hplip-3.18.9/prnt/plugins/hbpl1-x86_32.so
> /tmp/hplip-3.18.9/prnt/plugins/lj-arm64.so
> /tmp/hplip-3.18.9/prnt/plugins/lj-x86_64.so
> /tmp/hplip-3.18.9/prnt/plugins/lj-arm32.so
> /tmp/hplip-3.18.9/prnt/hpcups/libImageProcessor-x86_32.so
> /tmp/hplip-3.18.9/prnt/hpcups/libImageProcessor-x86_64.so
> --8<---------------cut here---------------end--------------->8---
> 
> I tried removing them with a snippet (patch attached), but installation
> eventually fails while trying to link against libImageProcessor, which
> is now missing.
> 
> In <https://bugs.launchpad.net/hplip/+bug/1785230/> people suggest that
> 3.18.6 is the last known-good version.  Indeed that version does not
> have the obnoxious libImageProcessor, so that should be fine.  It does
> come with the non-free binary plug-ins, though these are just plugins so
> removing them will be easier:
> 
> --8<---------------cut here---------------start------------->8---
> ludo@ribbon ~/src/guix$ find /tmp/hplip-3.18.6/ -name \*.so
> /tmp/hplip-3.18.6/prnt/plugins/hbpl1-arm32.so
> /tmp/hplip-3.18.6/prnt/plugins/hbpl1-x86_64.so
> /tmp/hplip-3.18.6/prnt/plugins/lj-x86_32.so
> /tmp/hplip-3.18.6/prnt/plugins/hbpl1-arm64.so
> /tmp/hplip-3.18.6/prnt/plugins/hbpl1-x86_32.so
> /tmp/hplip-3.18.6/prnt/plugins/lj-arm64.so
> /tmp/hplip-3.18.6/prnt/plugins/lj-x86_64.so
> /tmp/hplip-3.18.6/prnt/plugins/lj-arm32.so
> --8<---------------cut here---------------end--------------->8---
> 
> Thus, I propose to:
> 
>   1. Revert to 3.18.6 (we’ll upgrade if and when hplip becomes free
>      again.)

Not bad for an interm solution. Debian already has 3.18.10 packaged, and
based on their versioning scheme it still contains non-free artifacts.

> 
>   2. Add a snippet to remove the non-free plugins.
> 
> Thoughts?

Here's what I have right now:

;; Delete non-free blobs$
(delete-file "prnt/hpcups/libImageProcessor-x86_64.so")$
(delete-file "prnt/hpcups/libImageProcessor-x86_32.so")$
(delete-file-recursively "prnt/plugins")$
(substitute* "Makefile.am"$
  (("dist_printplugins_DATA") "# dist_printplugins_DATA"))

and a patch from debian to address imageprocessor:
  https://salsa.debian.org/printing-team/hplip/raw/debian/3.18.10+dfsg0-1/debian/patches/0025-Remove-all-ImageProcessor-functionality-which-is-clo.patch

> 
> Thanks,
> Ludo’.
> 

> diff --git a/gnu/packages/cups.scm b/gnu/packages/cups.scm
> index 4259648c69..c0ac365691 100644
> --- a/gnu/packages/cups.scm
> +++ b/gnu/packages/cups.scm
> @@ -410,6 +410,19 @@ device-specific programs to convert and print many types of files.")
>                 '(begin
>                    (substitute* "prnt/hpcups/genPCLm.cpp"
>                      (("boolean") "bool"))
> +
> +                  ;; Starting from version 3.18.9, hplip comes with binary
> +                  ;; blobs under prnt/hpcups and prnt/plugins.  Remove them.
> +                  (for-each delete-file (find-files "." "\\.so$"))
> +
> +                  ;; This trick changes the behavior of the
> +                  ;; 'install-data-hook' target so that it doesn't install the
> +                  ;; binary blobs.
> +                  (substitute* "Makefile.in"
> +                    (("^UNAME =.*")
> +                     "UNAME = free-software-only-thanks\n")
> +                    (("prnt/hpcups/libImageProcessor-([[:graph:]]+)\\.so")
> +                     ""))
>                    #t))))
>      (build-system gnu-build-system)
>      (home-page "https://developers.hp.com/hp-linux-imaging-and-printing")


-- 
Efraim Flashner   <efraim@flashner.co.il>   אפרים פלשנר
GPG key = A28B F40C 3E55 1372 662D  14F7 41AA E7DC CA3D 8351
Confidentiality cannot be guaranteed on emails sent or received unencrypted

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

  reply	other threads:[~2018-11-07 12:50 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-11-07 10:19 bug#33300: hplip 3.18.9 contains non-free binary blobs Ludovic Courtès
2018-11-07 12:48 ` Efraim Flashner [this message]
2018-11-07 14:34   ` Ludovic Courtès
2018-11-07 13:09 ` Tobias Geerinckx-Rice
2018-11-07 14:41   ` Ludovic Courtès
2018-11-07 23:57     ` bug#33300: Automatically detecting binaries in source tarballs Danny Milosavljevic
2018-11-08  8:50       ` Ludovic Courtès
2018-11-08 23:11         ` Björn Höfling
2018-11-11  7:23           ` Efraim Flashner
2018-11-11 17:28             ` Ludovic Courtès
2018-11-11 17:30     ` bug#33300: hplip 3.18.9 contains non-free binary blobs Ludovic Courtès

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20181107124858.GE1206@macbook41 \
    --to=efraim@flashner.co.il \
    --cc=33300@debbugs.gnu.org \
    --cc=ludo@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).