Bug 172268 - tetex-font-cm-lgc - bad %post and %postun scripts
tetex-font-cm-lgc - bad %post and %postun scripts
Product: Fedora
Classification: Fedora
Component: tetex-font-cm-lgc (Show other bugs)
All Linux
medium Severity medium
: ---
: ---
Assigned To: Sarantis Paskalis
Fedora Extras Quality Assurance
Depends On:
  Show dependency treegraph
Reported: 2005-11-02 00:19 EST by Michal Jaegermann
Modified: 2007-11-30 17:11 EST (History)
1 user (show)

See Also:
Fixed In Version: tetex-font-cm-lgc-0.5.4.fc4
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2005-11-02 06:42:49 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Michal Jaegermann 2005-11-02 00:19:03 EST
Description of problem:

In %post script of tetex-font-cm-lgc I see:

/usr/bin/updmap-sys --quiet --nohash --outputdir %{texmf}/dvips/config \
   --enable Map cm-lgc.map

and similar, but with '--disable', for %postun.  This actually is a bad idea
as you have no clue where fonts map really reside. TEXMFSYSVAR may be set
and point somewhere else.

These are fragments of a 'texconfig-sys conf' output from a real system:

============================= font map files =============================
psfonts.map: /usr/share/texmf-var/fonts/map/dvips/updmap/psfonts.map
pdftex.map: /usr/share/texmf-var/fonts/map/dvips/updmap/pdftex.map
ps2pk.map: /usr/share/texmf-var/fonts/map/dvips/updmap/ps2pk.map
dvipdfm.map: /usr/share/texmf-var/fonts/map/dvipdfm/updmap/dvipdfm.map

Oops! Nothing works after an installation was presumably finished.

AFAICS just running '/usr/bin/updmap-sys --quiet' should be enough to properly
rebuild map files in whatever directories they happen to be located.  This
makes new fonts findable for dvips, pdf(la)tex and dvipdfm.  If you want to be
specific with '--enable/--disable' then so be it; although I am not so sure 
what that actually buys.

I do not know why '--nohash' is there?  If you are or removing files from
your TeX installation tree you actually _want_ to run 'texhash' so corresponding
lists will reflect an actual state.

Version-Release number of selected component (if applicable):

Additional info:
I did not check how corresponding scripts look in other 'tetex-font...' packages.
Comment 1 Sarantis Paskalis 2005-11-02 06:42:49 EST
Explicit outputdirs removed from %post and %postun.

The --enable and --disable options are mandatory when installing/removing the
map,  because change to the updmap.cfg is required.  Without them, the
updmap.cfg is not changed and the changes are not propagated to psfonts.map,
pdftex.map, etc.

The --nohash switch is needed to not run texhash twice.  My half-baked approach
to clean up the spec file removed the texhash command before updmap-sys, but
keeping the nohash switch.  I discovered that running texhash before updmap-sys
is necessary when installing a map, because updmap-sys uses that information to
locate the map file.  So, the correct procedure (in %post) is to run texhash,
and then updmap-sys.  Running updmap-sys without --nohash runs texhash for a
second time, when no new files are added (only the psfonts.map, pdftex.map, etc
are _changed_).

(also fixed tetex-font-kerkis)

tetex-font-cm-lgc-0.5.4.fc4 just built on the buildsystem.

Note You need to log in before you can comment on or make changes to this bug.