Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 160294 - app-text/ghostscript-{gnu,gpl} patch request: /invalidfont in --show-- when trying to convert the PDF file
Summary: app-text/ghostscript-{gnu,gpl} patch request: /invalidfont in --show-- when t...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Printing (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Printing Team
URL: http://bugs.ghostscript.com/show_bug....
Whiteboard:
Keywords:
Depends on:
Blocks: 132706
  Show dependency tree
 
Reported: 2007-01-05 09:58 UTC by Ed Catmur
Modified: 2007-10-21 18:03 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
688536-bugs.ghostscript.com-invalidfont.patch (688536-bugs.ghostscript.com-invalidfont.patch,4.95 KB, patch)
2007-02-28 23:57 UTC, Ed Catmur
Details | Diff
foo.ps (pstest.ps,234 bytes, text/plain)
2007-03-02 16:44 UTC, Marijn Schouten (RETIRED)
Details
foo.ps (pstest.ps,117 bytes, text/plain)
2007-03-02 16:46 UTC, Marijn Schouten (RETIRED)
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Ed Catmur 2007-01-05 09:58:27 UTC
Requesting patch from http://ghostscript.com/pipermail/gs-cvs/2006-July/006677.html to fix http://bugs.ghostscript.com/show_bug.cgi?id=688536

This applies to ghostscript-gnu 8.54 and ghostscript-gpl-8.54.

Needed to build lilypond 2.10 documentation (bug 132706).

Testcase:

%!PS-Adobe-2.0
(/usr/share/fonts/TTF/luximr.ttf) (r) file .loadfont
10 10 moveto
/LuxiMono 12 selectfont
/r glyphshow

$ gs -dNOSAFER -dNOPAUSE -dBATCH -sDEVICE=pdfwrite -sOutputFile=foo.pdf -c .setpdfwrite -f foo.eps
Comment 1 Marijn Schouten (RETIRED) gentoo-dev 2007-02-15 15:39:40 UTC
Ed, is this fixed in ghostscript-gnu-8.55?
Comment 2 Ed Catmur 2007-02-15 16:04:21 UTC
(In reply to comment #1)
> Ed, is this fixed in ghostscript-gnu-8.55?

No, the patch still applies.
Comment 3 Marijn Schouten (RETIRED) gentoo-dev 2007-02-28 18:25:56 UTC
Ed, can you provide a patch for one of the ghostscript ebuilds and attach the patch to this bug? I'm having some trouble getting it to apply.
Comment 4 Ed Catmur 2007-02-28 23:57:40 UTC
Created attachment 111640 [details, diff]
688536-bugs.ghostscript.com-invalidfont.patch

This is tested against ghostscript-gpl-8.54.
Comment 5 Marijn Schouten (RETIRED) gentoo-dev 2007-03-02 16:44:46 UTC
Created attachment 111814 [details]
foo.ps

Ed, can you reproduce on the attached ps?
Comment 6 Marijn Schouten (RETIRED) gentoo-dev 2007-03-02 16:46:43 UTC
Created attachment 111815 [details]
foo.ps

I mean this one.
Comment 7 Ed Catmur 2007-03-03 12:20:21 UTC
Yes, fully reproducible (i.e. the bug shows up when compiled without the patch, and disappears when compiled with the patch).
Comment 8 Marijn Schouten (RETIRED) gentoo-dev 2007-03-03 13:14:54 UTC
I asked because I noticed no difference in behaviour myself. What are the respective outputs?
Comment 9 Ed Catmur 2007-03-03 23:18:47 UTC
Without patch:
$ gs -dNOSAFER -dNOPAUSE -dBATCH -sDEVICE=pdfwrite -sOutputFile=foo.pdf -c .setpdfwrite -f foo.ps
GPL Ghostscript 8.54 (2006-05-17)
Copyright (C) 2006 artofcode LLC, Benicia, CA.  All rights reserved.
This software comes with NO WARRANTY: see the file PUBLIC for details.
Error: /invalidfont in --glyphshow--
Operand stack:

Execution stack:
   %interp_exit   .runexec2   --nostringval--   --nostringval--   --nostringval--   2   %stopped_push   --nostringval--   --nostringval--   --nostringval--   false   1   %stopped_push   1   3   %oparray_pop   1   3   %oparray_pop   1   3   %oparray_pop   1   3   %oparray_pop   .runexec2   --nostringval--   --nostringval--   --nostringval--   2   %stopped_push   --nostringval--
Dictionary stack:
   --dict:1126/1686(ro)(G)--   --dict:0/20(G)--   --dict:70/200(L)--
Current allocation mode is local
Current file position is 118
GPL Ghostscript 8.54: Unrecoverable error, exit code 1

With patch:
$ gs -dNOSAFER -dNOPAUSE -dBATCH -sDEVICE=pdfwrite -sOutputFile=foo.pdf -c .setpdfwrite -f foo.ps
GPL Ghostscript 8.54 (2006-05-17)
Copyright (C) 2006 artofcode LLC, Benicia, CA.  All rights reserved.
This software comes with NO WARRANTY: see the file PUBLIC for details.
$ echo $?
0

/usr/share/fonts/TTF/luximr.ttf is from font-bh-ttf.
Comment 10 Didier Link 2007-05-08 15:57:52 UTC
I've just tested the ps file with the last gnu gs package (8.56.0) and the file is interpreted correctly.

I submit a new ebuild for this new gnu version. Can you test it after portage tree update ?

Thanks for report it with a test case !

Comment 11 Timo Gurr (RETIRED) gentoo-dev 2007-06-13 12:30:05 UTC
Tested this, too with ghostscript-gpl-8.57 and it seems to work.

# gs -dNOSAFER -dNOPAUSE -dBATCH -sDEVICE=pdfwrite -sOutputFile=foo.pdf -c .setpdfwrite -f foo.ps
GPL Ghostscript 8.57 (2007-05-11)
Copyright (C) 2007 artofcode LLC, Benicia, CA.  All rights reserved.
This software comes with NO WARRANTY: see the file PUBLIC for details.

# pdfinfo foo.pdf
Producer:       GPL Ghostscript 8.57
CreationDate:   Wed Jun 13 12:10:10 2007
ModDate:        Wed Jun 13 12:10:10 2007
Tagged:         no
Pages:          1
Encrypted:      no
Page size:      612 x 792 pts (letter)
File size:      5483 bytes
Optimized:      no
PDF version:    1.4
Comment 12 Stefan Schweizer (RETIRED) gentoo-dev 2007-10-21 18:03:15 UTC
seems to be fixed. If not please reopen.