19

Where I can find the source code of pdflatex.exe?

Edit 1

This is quoted from the link given by @TH.

pdfTeX is built on top of TeX, written by Donald Knuth cum suis (Liang and so), and eTeX, written by Peter Breitenlohner cum suis; part of the paragraph optimization is inspired by the work of Hermann Zapf.

Does it imply that the source code of pdflatex.exe will invoke TeX and eTeX ?

Display Name
  • 46,933

1 Answers1

11

On CTAN. http://ctan.org/tex-archive/systems/pdftex/

Links to the source code repository can be found on tug.org.

Edit:
To answer your follow up question, pdflatex does not invoke tex or etex. Rather, pdfTeX implements the ε-TeX extensions.

TH.
  • 62,639
  • 1
    @TH. : thanks. By the way what is the difference between pdftex.exe and pdflatex.exe ? Please see my update also. – Display Name Mar 09 '11 at 09:02
  • 2
    @xport pdflatex is a shortcut for pdftex -fmt=pdflatex. See pdftex -help. – Andrey Vihrov Mar 09 '11 at 09:13
  • @Andrey: Oh, pdflatex.exe = pdftex.exe -fmt=pdflatex. Unbelievable. – Display Name Mar 09 '11 at 09:27
  • 1
    @xport: There are four ways to choose a format: the (base) name of the binary (e.g., pdflatex), via &format (e.g., pdftex &pdflatex, via -fmt (e.g., pdftex -fmt pdflatex), and via the first line of the input file (e.g., %&pdflatex). – TH. Mar 09 '11 at 09:32
  • @TH. : So the definition of pdflatex must exist first because it will be used by pdftex. It does not make sense actually. In my mental model, pdftex is more mature than pdflatex. – Display Name Mar 09 '11 at 09:39
  • @xport: I don't know what you mean. pdflatex is just a format. In TeX Live, it lives in .../texmf-var/web2c/pdftex/pdflatex.fmt. pdftex is the name of the pdfTeX binary as well as the name of the format (pdftex.fmt) that is essentially the plain format but with pdfTeX extensions and pdf output. latex is just a format. – TH. Mar 09 '11 at 09:44
  • The link no longer works. – Niels Abildgaard Oct 11 '17 at 07:49
  • The source is more specifically available at https://tug.org/svn/pdftex/branches/stable/ – Anm Sep 25 '23 at 14:34