Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 04 May 2021 22:01:46 +0200
From:      "Julian H. Stacey" <jhs@berklix.com>
To:        =?UTF-8?B?VMSzbA==?= Coosemans <tijl@freebsd.org>
Cc:        freebsd-ports@freebsd.org, "Julian H. Stacey" <jhs@berklix.com>
Subject:   Re: /usr/ports/print/ghostscript9-agpl-base gs_ll3.ps: Error: /undefinedresource (fwd)
Message-ID:  <202105042001.144K1kd1003733@fire.js.berklix.net>
In-Reply-To: Your message "Tue, 04 May 2021 17:51:05 %2B0200." <20210504175105.6e61b2d2@FreeBSD.org>

next in thread | previous in thread | raw e-mail | index | archive | help
Hi, Reference:
> From:		=?UTF-8?B?VMSzbA==?= Coosemans <tijl@freebsd.org>
> Date:		Tue, 4 May 2021 17:51:05 +0200

=?UTF-8?B?VMSzbA==?= Coosemans wrote:
> On Tue, 04 May 2021 16:29:47 +0200 "Julian H. Stacey" <jhs@berklix.com>
> wrote:
> > Hi ports@ people,
> > I wrote this to doceng@FreeBSD.org Sun, 02 May 2021 23:43:44 +0200
> > but no reply by Tue May  4 16:26:48 CEST 2021.
> > Have others seen similar or got ideas to fix gs ghostscript ?
> > -----------
> > 
> > Hi doceng@FreeBSD.org
> > as MAINTAINER= in /usr/ports/print/ghostscript9-agpl-base
> > 
> > I'm stuck, gs fails to start, suggestions please ?
> > 
> > FreeBSD lapr.js.berklix.net 12.2-STABLE FreeBSD 12.2-STABLE #1038: Mon Feb 15 02:04:28 CET 2021     jhs@lapr.no.berklix.net:/data/release/s2/usr/src/sys/amd64/compile/LAPR.small  amd64
> > 
> > % printenv
> > PATH=/sbin:/bin:/usr/sbin:/usr/bin:/usr/games:/usr/local/bin
> > TERM=xterm
> > DESTDIR=/
> > TERMPATH=/etc/termcap:/usr/share/misc/termcap
> > NOCLEANDEPENDS=
> > % printenv
> > PATH=/sbin:/bin:/usr/sbin:/usr/bin:/usr/games:/usr/local/bin
> > TERM=xterm
> > DESTDIR=/
> > TERMPATH=/etc/termcap:/usr/share/misc/termcap
> > NOCLEANDEPENDS=
> > 
> > % which gs
> > /usr/local/bin/gs
> > % ls -l /usr/local/bin/gs
> > - -rwxr-xr-x  1 root  wheel  7648 Apr 29 11:02 /usr/local/bin/gs*
> > 
> > gs
> > GPL Ghostscript 9.52 (2020-03-19)
> > Copyright (C) 2020 Artifex Software, Inc.  All rights reserved.
> > This software is supplied under the GNU AGPLv3 and comes with NO WARRANTY:
> > see the file COPYING for details.
> > While reading gs_ll3.ps:
> > Error: /undefinedresource in findresource
> > Operand stack:
> >    (gs_icc.ps\000gs_mex_e.ps\000gs_mro_e.ps\000gs_pdf_e.ps\000gs_wan_e.ps\000pdf_ops.ps\000pdf_rbld.ps\000pdf_base.ps\000pdf_draw.ps\000gs_cff.ps\000gs_mgl_e.ps\000gs_ttf.ps\000pdf_font.ps\000pdf_main.ps\000pdf_sec.ps\000gs_epsf.ps\000gs_pdfwr.ps)   (gs_ll3.ps)   1   Pscript5Idiom.pkgsave   IdiomSet   6   Pscript5Idiom.pkgsave
> > Execution stack:
> >    %interp_exit   --nostringval--   findresource   %loop_continue   findresource   findresource   findresource   false   1   %stopped_push   --nostringval--   1902   7   5   %oparray_pop   findresource   findresource   --dict:16/18(ro)(G)--   --dict:2/2(G)--   findresource   2   %dict_continue   findresource   findresource   1900   5   5   %oparray_pop   findresource   %errorexec_pop   findresource   findresource   findresource   findresource
> > Dictionary stack:
> >    --dict:943/1123(G)--   --dict:0/20(G)--   --dict:77/200(L)--   --dict:943/1123(G)--   --dict:38/43(G)--   --dict:16/18(ro)(G)--
> > Current allocation mode is global
> > Current file position is 18941
> > 
> > Any ideas please ?
> > I rebuilt my machine with make worl & generic then custom kernel &
> > a load of downloaded pkg 
> > pkg info -a | wc -l
> >     1348
> > 
> > ive since run 
> > cd /usr/ports/print/ghostscript9-agpl-base 
> > make clean
> > make reinstall
> > 
> > gs -help
> > ends
> >    /usr/local/share/ghostscript/9.52/Resource/Init :
> >    /usr/local/share/ghostscript/9.52/lib :
> >    /usr/local/share/ghostscript/9.52/Resource/Font :
> >    /usr/local/share/ghostscript/fonts : /usr/local/share/fonts
> >    Ghostscript is also using fontconfig to search for font files
> > 
> > my /usr/local/share/ghostscript/9.52/Resource/ has no Init should it ?
> > drwxr-xr-x   2 root  bin      4608 May  2 22:33 ./
> > drwxr-xr-x  11 root  bin       512 May  2 22:33 ../
> > - -rw-r--r--   1 root  wheel    3297 May  2 22:23 FAPIcidfmap
> > - -rw-r--r--   1 root  wheel    3297 Jun 16  2020 FAPIcidfmap.pkgsave
> > - -rw-r--r--   1 root  wheel    1158 May  2 22:23 FAPIconfig
> > - -rw-r--r--   1 root  wheel    1158 Jun 16  2020 FAPIconfig.pkgsave
> > - -rw-r--r--   1 root  wheel    1468 May  2 22:23 FAPIfontmap
> > - -rw-r--r--   1 root  wheel    1468 Jun 16  2020 FAPIfontmap.pkgsave
> > - -rw-r--r--   1 root  wheel    2857 May  2 22:23 FCOfontmap-PCLPS2
> > - -rw-r--r--   1 root  wheel    2857 Jun 16  2020 FCOfontmap-PCLPS2.pkgsave
> > - -rw-r--r--   1 root  wheel     109 May  2 22:23 Fontmap
> > - -rw-r--r--   1 root  wheel   12929 May  2 22:23 Fontmap.GS
> > - -rw-r--r--   1 root  wheel   12929 Jun 16  2020 Fontmap.GS.pkgsave
> > - -rw-r--r--   1 root  wheel     109 Jun 16  2020 Fontmap.pkgsave
> > - -rw-r--r--   1 root  wheel    4183 May  2 22:23 cidfmap
> > - -rw-r--r--   1 root  wheel    4183 Jun 16  2020 cidfmap.pkgsave
> > - -rw-r--r--   1 root  wheel  218021 May  2 22:23 gs_agl.ps
> > 
> > /usr/local/share/ghostscript/fonts
> > - -rw-r--r--  1 root  wheel   13643 Sep 19  2020 Fontmap
> > - -rw-r--r--  1 root  wheel   13643 Jul  6  2019 Fontmap.pkgsave
> > lrwxr-xr-x  1 root  wheel      49 Sep 19  2020 GothicBBB-Medium@ -> /usr/local/share/fonts/std.ja_JP/GothicBBB-Medium
> > lrwxr-xr-x  1 root  wheel      53 Sep 19  2020 GothicBBB-Medium.gs7@ -> /usr/local/share/fonts/std.ja_JP/GothicBBB-Medium.gs7
> > lrwxr-xr-x  1 root  wheel      44 Sep 19  2020 MSung-Light@ -> /usr/local/share/fonts/std.zh_CN/MSung-Light
> > lrwxr-xr-x  1 root  wheel      45 Sep 19  2020 Ryumin-Light@ -> /usr/local/share/fonts/std.ja_JP/Ryumin-Light
> > lrwxr-xr-x  1 root  wheel      49 Sep 19  2020 Ryumin-Light.gs7@ -> /usr/local/share/fonts/std.ja_JP/Ryumin-Light.gs7
> > lrwxr-xr-x  1 root  wheel      48 Sep 19  2020 STHeiti-Regular@ -> /usr/local/share/fonts/std.zh_CN/STHeiti-Regular
> > lrwxr-xr-x  1 root  wheel      45 Sep 19  2020 STSong-Light@ -> /usr/local/share/fonts/std.zh_CN/STSong-Light
> > - -rw-r--r--  1 root  wheel   42833 Sep 19  2020 a010013l.afm
> > 
> > - -rw-r--r--  1 root  wheel  19572 May  2 20:23 /usr/local/share/ghostscript/9.52/Resource/Init/gs_ll3.ps
> > MD5 (share/ghostscript/9.52/Resource/Init/gs_ll3.ps) = 9c92e1f0a9fbde8aff39ab3d49e1e35b
> > 
> > Could this be a font problem ?
> > 
> > I used to see fontconfig errs with firefox, but that starts
> > without error now, as does exmh so I guess its not fontfig.
> > 
> > BTW I chased this problem back from this failing
> > 	 cat thing.ps | /usr/local/bin/ps2pdf -sPAPERSIZE=a4 - thing.pdf
> > 
> > Hope you can help please, if I should provide more info please let me know.
> 
> Delete all those .pkgsave files.  These are backups created by pkg when
> it has to install a file over an existing file.  It means a previous
> version of ghostscript wasn't deleted properly.

Thanks Coosemans, I ran my compare+delete
http://berklix.com/~jhs/src/bsd/jhs/bin/public/cmpd/cmpd.c
cmpd -d -v \
 /usr/local/share/ghostscript/fonts/Fontmap.pkgsave \
 /usr/local/share/ghostscript/fonts/Fontmap
cmpd -d -v \
 /usr/local/share/ghostscript/9.52/Resource/Init/Fontmap.pkgsave \
 /usr/local/share/ghostscript/9.52/Resource/Init/Fontmap
cmpd -d -v \
 /usr/local/share/ghostscript/9.52/Resource/Init/Fontmap.GS.pkgsave \
 /usr/local/share/ghostscript/9.52/Resource/Init/Fontmap.GS
All identical & deleted.

& rebooted but no better, gs still fails.
  (also xsane fals since a pkg upgrade (after discovering the gs problem),
  xsane also stopped seeing a scanner which the same box with a few month
  old current still sees the scanner )

Unless someone else has an idea, I could try discarding the whole
of /usr/local & reinstall all for a clean system, with:
	cd /usr/local/.. mv  local local.old ; mkdir local
	cd /var/cache/pkg/.. mv pkg pkg.old ; mkdir pkg
	cd /var/db/pkg/.. ; mv pkg pkg/.old ; mkdir pkg
	cd /etc ; mv pkg pkg.old ; mkdir pkg
	Then reinstall all packages
Though that's crude & laborious & may not fix it.

Cheers,
-- 
Julian Stacey  http://berklix.com/jhs/  http://stolenvotes.uk
UK for Brexit stole 750K votes from Brits in EU of 3.7M globaly. Zap BoJo Mogg.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202105042001.144K1kd1003733>