Opened 18 years ago

Closed 16 years ago

#464 closed defect (fixed)

TeX-3.0 default pdf generation no good

Reported by: billyoc@… Owned by: bdubbs@…
Priority: high Milestone: 6.2.0
Component: BOOK Version: SVN
Severity: normal Keywords:
Cc: alexander@…

Description

TeX needs additional fonts for proper pdf generation.

Attachments (3)

test.log (3.4 KB ) - added by bdubbs@… 16 years ago.
Output from pdflatex test.tex > test.out
test.out (1.1 KB ) - added by bdubbs@… 16 years ago.
Output from pdflatex test.tex > test.out
test.pdf (1.6 KB ) - added by bdubbs@… 16 years ago.
output from pdflatex test.tex > test.out

Download all attachments as: .zip

Change History (24)

comment:1 by billyoc@…, 18 years ago

Status: newassigned

comment:2 by billyoc@…, 18 years ago

Owner: changed from blfs-book@… to billyoc@…
Status: assignednew

comment:3 by larry@…, 17 years ago

Owner: changed from billyoc@… to blfs-book@…

comment:4 by bdubbs@…, 17 years ago

Version: ~CVSSVN

comment:5 by Randy McMurchy, 16 years ago

Milestone: future6.1
Resolution: fixed
Status: newclosed

Closing this old bug as TeX has been updated to 3.0 and the new version contains many new font sets.

comment:6 by alexander@…, 16 years ago

Resolution: fixed
Status: closedreopened

There are still issues with generated PDF files. Testcase: cat >test.tex <<"EOF" \documentclass{article} \usepackage[koi8-r]{inputenc} \usepackage[russian]{babel} \begin{document} \CYRA \end{document} EOF pdflatex test.tex The resulting PDF looks correctly but text extraction is broken. pdftotext -enc UTF-8 test.pdf - | xxd The expected output is: 0000000: d090 0a0a 310a 0a0c 0a ....1.... The actual output is: 0000000: c380 0a0a 310a 0a0c 0a ....1.... The issue is fixed for xpdf by installing the "cm-super" font package from CTAN. This package also makes the PDF output look better in Adobe Reader for Windows. For text extraction and searching to work in Adobe Reader for Windows, also the tiny "cmap" package from CTAN is required in addition to "cm-super".

comment:7 by alexander@…, 16 years ago

Summary: TeX-2.0.2 default pdf generation no goodTeX-3.0 default pdf generation no good

Forgot to change tetex version number in bug title

comment:8 by bdubbs@…, 16 years ago

Alexander,

In reviewing this bug, the instructions for installing the cm-super fonts are

unclear.

  1. I don't see an easy way to get the fonts. That is, I cannot find a

prepackaged .gz or bz2 file. Do you know where a tarball is located?

  1. It looks like the steps are:
    1. Copy the */pfb files to /usr/share/texmf/fonts/type1/public/cm-super/
    2. Edit the file /usr/share/texmf/dvips/config/updmap
    3. Run updmap

The problem is that my system does not have the file in 2b and I don't know if any parameters are needed for 2c.

Can you give more specific instructions?

comment:9 by alexander@…, 16 years ago

The installation instructions that come with cm-super are indeed outdated and don't work with tetex-3.0.

  1. In fact a tar.gz file can be autogenerated on-the-fly by some ftp mirrors,

e.g: ftp://tug.ctan.org/tex-archive/fonts/ps-type1/cm-super.tar.gz Note that it works only with some, not all, ftp clients (wget and Konqueror are OK), and doesn't work at all if you are behind certain versions of Microsoft proxy server.

  1. a. *.pfb files go into /usr/share/texmf/fonts/type1/public/cm-super/
    1. *.afm files (uncompressed) optionally go into /usr/share/texmf/fonts/afm/public/cm-super/
    2. *.enc files go to .../texmf/fonts/enc/dvips/cm-super/
    3. *.map files for dvips go to .../texmf/fonts/map/dvips/cm-super/
    4. looks like *.map files for dvipdfm could go to .../texmf/fonts/map/dvips/cm-super/, but they don't seem to be used here at all.
    5. the file to be edited is: .../texmf/web2c/updmap.cfg. Add lines:

MixedMap cm-super-t1.map MixedMap cm-super-t2a.map MixedMap cm-super-t2b.map MixedMap cm-super-t2c.map MixedMap cm-super-ts1.map MixedMap cm-super-x2.map

  1. updmap doesn't need any parameters

comment:10 by alexander@…, 16 years ago

oops,

  1. looks like *.map files for dvipdfm could go to .../texmf/fonts/map/dvipdfm/cm-super/, but they don't seem to be used here at all.

comment:11 by bdubbs@…, 16 years ago

Owner: changed from blfs-book@… to bdubbs@…
Status: reopenednew

comment:12 by bdubbs@…, 16 years ago

Status: newassigned

by bdubbs@…, 16 years ago

Attachment: test.log added

Output from pdflatex test.tex > test.out

by bdubbs@…, 16 years ago

Attachment: test.out added

Output from pdflatex test.tex > test.out

by bdubbs@…, 16 years ago

Attachment: test.pdf added

output from pdflatex test.tex > test.out

comment:13 by bdubbs@…, 16 years ago

Trying to fix this bug...

Alex,

I installed the fonts. The result of updmap includes:

updmap: using map file `/usr/share/texmf/fonts/map/dvipdfm/cm-super/cm-super-t1.map' updmap: using map file `/usr/share/texmf/fonts/map/dvipdfm/cm-super/cm-super-t2a.map' updmap: using map file `/usr/share/texmf/fonts/map/dvipdfm/cm-super/cm-super-t2b.map' updmap: using map file `/usr/share/texmf/fonts/map/dvipdfm/cm-super/cm-super-t2c.map' updmap: using map file `/usr/share/texmf/fonts/map/dvipdfm/cm-super/cm-super-ts1.map' updmap: using map file `/usr/share/texmf/fonts/map/dvipdfm/cm-super/cm-super-x2.map'

When running the test in Comment #2, I get: # pdftotext -enc UTF-8 test.pdf - | xxd 0000000: 310a 0a0c 0a 1....

Attaching working files.

I need to get this fixed asap if we want to get it into 6.1.

comment:14 by alexander@…, 16 years ago

The PDF file you attached doesn't even contain the cyrillic leter A when viewed. Something went wrong, possibly because:

1) you disabled font embedding (the Adobe PDF specification _requires_ embedding of fonts with non-ISO-8859-1 glyphs). 2) Not sure why you have /root/.texmf-var/ mentioned in the output.

comment:15 by alexander@…, 16 years ago

Cc: alexander@… added

comment:16 by alexander@…, 16 years ago

In your output, it looks like updmap found only dvipdfm map files, not dvips (also used by pdflatex)

comment:17 by bdubbs@…, 16 years ago

Milestone: 6.16.2

Changing target milestone to 6.2 so we have time to validate the fix.

comment:18 by alexander@…, 16 years ago

Found the possible problem. 1) Looks like dvipdfm map files are harmful. Try removing .../texmf/fonts/map/dvipdfm/cm-super/ at all, rerunning updmap and retesting the PDF output. Even without them, dvipdfm uses Type1 fonts. 2) I don't like the fact that the configuration is saved in /root/.texmf-var: this way, all changes in font configuration apply to root only. Fix: TEXMFVAR=/usr/share/texmfvar updmap Not sure if that also applies to "texconfig dvips paper letter" in the book.

comment:19 by alexander@…, 16 years ago

Reposting using Mozilla Firefox instead of Links -- hopefully, this will fix the formatting.

Found the possible problem.

1) Looks like dvipdfm map files are harmful. Try removing .../texmf/fonts/map/dvipdfm/cm-super/ at all, rerunning updmap and retesting the PDF output. Even without them, dvipdfm uses Type1 fonts.

2) I don't like the fact that the configuration is saved in /root/.texmf-var: this way, all changes in font configuration apply to root only.

Fix: TEXMFVAR=/usr/share/texmf-var updmap

Not sure if that also applies to "texconfig dvips paper letter" command in the book.

comment:20 by bdubbs@…, 16 years ago

Alex, look at:

http://anduin.linuxfromscratch.org/~bdubbs/blfs-book-xsl/pst/typesetting.html#tex

to see if the changes I made fixes this bug.

comment:21 by bdubbs@…, 16 years ago

Resolution: fixed
Status: assignedclosed

Added installation instructions for cm-super fonts.

Note: See TracTickets for help on using tickets.