Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 348861

Summary: app-text/pdftk-1.44: nodrm patch missing
Product: Gentoo Linux Reporter: Mariusz Pękala <mariusz>
Component: New packagesAssignee: Printing Team <printing>
Status: RESOLVED WONTFIX    
Severity: enhancement CC: java, mao.c.pu, martin, pk1
Priority: High    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Attachments: pdftk nodrm patch

Description Mariusz Pękala 2010-12-16 11:11:40 UTC
The situation is the same as in bug #296455:
pdftk-1.44 is missing the nodrm patch (see bug #127891), which was available in
previous versions. Please add it back again.


Reproducible: Always
Comment 1 Mao PU 2011-09-07 06:53:24 UTC
Created attachment 285761 [details, diff]
pdftk nodrm patch

Maybe you can try this patch, which uses the solution proposed at http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=531529.
Comment 2 Mao PU 2011-11-26 15:14:27 UTC
Did anyone have the chance to test the proposed patch?
Comment 3 Pouya K 2011-11-26 17:29:05 UTC
Seems to work for me. I have been using the change (although without this specific patch file) for a while now without any issues.
Comment 4 Andreas K. Hüttel archtester gentoo-dev 2012-06-03 17:43:55 UTC
Seems like noone wants to put this back in, given the fervent activity on this bug.

I suggest you add the patch yourself if you need it (via /etc/portage/patches).
Comment 5 gentoolinux 2012-08-21 15:47:17 UTC
Adding the patch via /etc/portage/patches doesn't work because the ebuild doesn't call epatch_user. OK, you can create a file /etc/portage/bashrc to force a call to epatch_user, but why all the trouble? This is just a small patch, which isn't enabled by default. So why don't you add it? If I had the rights, I would do so.

If you don't want to add an extra file, there is even a smaller way (nearly a one-liner) to achieve that pdftk can handle encrypted PDF files:

if use nodrm; then
  sed -i 's:passwordIsOwner= false:passwordIsOwner= true:' "${WORKDIR}/${P}"-dist/java/com/lowagie/text/pdf/PdfReader.java || die
fi

This is the same way how it was done in pdftk-1.41 (see bug #296455) and also works fine with pdftk-1.44.