Discussion:
[tex-live] Building pdflatex
pilot constatinus
2018-03-23 19:24:05 UTC
Permalink
Hi, dear texlive. I was wondering how can i build pdflatex, a latex
compiler for pdf. Even if i built my tl with ./configure --enable-all-pkgs,
under texk/web2c there is no pdflatex, only pdftex and some other tools.
How is it that i can find this only in debian repository and cant build it
myself? I have acctually downloaded the source texlive-full from the repo
and i dont seem to know how to do anything with it. Thanks in advance.
Philip Taylor (RHUoL)
2018-03-23 21:34:24 UTC
Permalink
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;
charset=ISO-8859-1">
</head>
<body text="#000000" bgcolor="#FFFFFF">
<p>It is extremely likely that an apparently executable image called
"pdflatex" is, in fact, merely an instance of pdftex that has
pre-loaded the LaTeX format.  You can get the effect of pdflatex
by using <br>
</p>
<ul>
<li>pdftex &amp;latex</li>
</ul>
<p>(tho' pdftex might need some additional qualifier to indicate
that it should be launched in initex mode).</p>
<p>Philip Taylor</p>
<p>--------<br>
</p>
<div class="moz-cite-prefix">pilot constatinus wrote:<br>
</div>
<blockquote type="cite"
cite="mid:CAKZd3Gz2wfumT0vbjBuk2KepjjYH2AOkU0MXQh-+***@mail.gmail.com">
<meta http-equiv="Content-Type" content="text/html;
charset=ISO-8859-1">
<div dir="auto">Hi, dear texlive. I was wondering how can i build
pdflatex, a latex compiler for pdf. Even if i built my tl with
./configure --enable-all-pkgs, under texk/web2c there is no
pdflatex, only pdftex and some other tools. How is it that i can
find this only in debian repository and cant build it myself? I
have acctually downloaded the source texlive-full from the repo
and i dont seem to know how to do anything with it. Thanks in
advance.<br>
</div>
</blockquote>
<br>
</body>
</html>
Justin C. Walker
2018-03-23 21:49:27 UTC
Permalink
Hi, dear texlive. I was wondering how can i build pdflatex, a latex compiler for pdf. Even if i built my tl with ./configure --enable-all-pkgs, under texk/web2c there is no pdflatex, only pdftex and some other tools. How is it that i can find this only in debian repository and cant build it myself? I have acctually downloaded the source texlive-full from the repo and i dont seem to know how to do anything with it. Thanks in advance.
pdflatex is actually a symbolic link to pdftex (at least on Unix-like systems). This means that the actual program will behave as Philip describes, and decides this by looking at the name by which it is invoked.

HTH

Justin

--
Justin C. Walker, Curmudgeon at Large
Director
Institute for the Enhancement of the Director's income
-----------
Question 43:
What if the hokey pokey
really *is* what it’s all about?
--
pilot constatinus
2018-03-23 22:10:23 UTC
Permalink
I was also thinking the same, but didn't quite catch that in the man page.
Thanks very much!
Post by pilot constatinus
Post by pilot constatinus
Hi, dear texlive. I was wondering how can i build pdflatex, a latex
compiler for pdf. Even if i built my tl with ./configure --enable-all-pkgs,
under texk/web2c there is no pdflatex, only pdftex and some other tools.
How is it that i can find this only in debian repository and cant build it
myself? I have acctually downloaded the source texlive-full from the repo
and i dont seem to know how to do anything with it. Thanks in advance.
pdflatex is actually a symbolic link to pdftex (at least on Unix-like
systems). This means that the actual program will behave as Philip
describes, and decides this by looking at the name by which it is invoked.
HTH
Justin
--
Justin C. Walker, Curmudgeon at Large
Director
Institute for the Enhancement of the Director's income
-----------
What if the hokey pokey
really *is* what it’s all about?
--
pilot constatinus
2018-03-24 19:31:03 UTC
Permalink
Acctually, what was really going on was that pdftex &latex was just running
'latex'. After i uninstalled the repo version and installed the compiled
one, i got suspended tty input... I still don't have latex/pdflatex
executable compiled. Why is this?
Post by pilot constatinus
I was also thinking the same, but didn't quite catch that in the man page.
Thanks very much!
Post by pilot constatinus
Post by pilot constatinus
Hi, dear texlive. I was wondering how can i build pdflatex, a latex
compiler for pdf. Even if i built my tl with ./configure --enable-all-pkgs,
under texk/web2c there is no pdflatex, only pdftex and some other tools.
How is it that i can find this only in debian repository and cant build it
myself? I have acctually downloaded the source texlive-full from the repo
and i dont seem to know how to do anything with it. Thanks in advance.
pdflatex is actually a symbolic link to pdftex (at least on Unix-like
systems). This means that the actual program will behave as Philip
describes, and decides this by looking at the name by which it is invoked.
HTH
Justin
--
Justin C. Walker, Curmudgeon at Large
Director
Institute for the Enhancement of the Director's income
-----------
What if the hokey pokey
really *is* what it’s all about?
--
Zdenek Wagner
2018-03-24 19:46:31 UTC
Permalink
latex and pdflatex executables exist on Windows only but as a wrapper
written in lua which calls pdftex with &formatname. On unix systems
(including Mac) these are just symlinks to pdftex. If you use unix system,
then cd to the executable directory and do:

ln -s pdftex latex
ln -s pdftex pdflatex


Zdeněk Wagner
http://ttsm.icpf.cas.cz/team/wagner.shtml
http://icebearsoft.euweb.cz
Post by pilot constatinus
Acctually, what was really going on was that pdftex &latex was just
running 'latex'. After i uninstalled the repo version and installed the
compiled one, i got suspended tty input... I still don't have
latex/pdflatex executable compiled. Why is this?
Post by pilot constatinus
I was also thinking the same, but didn't quite catch that in the man
page. Thanks very much!
Post by pilot constatinus
Post by pilot constatinus
Hi, dear texlive. I was wondering how can i build pdflatex, a latex
compiler for pdf. Even if i built my tl with ./configure --enable-all-pkgs,
under texk/web2c there is no pdflatex, only pdftex and some other tools.
How is it that i can find this only in debian repository and cant build it
myself? I have acctually downloaded the source texlive-full from the repo
and i dont seem to know how to do anything with it. Thanks in advance.
pdflatex is actually a symbolic link to pdftex (at least on Unix-like
systems). This means that the actual program will behave as Philip
describes, and decides this by looking at the name by which it is invoked.
HTH
Justin
--
Justin C. Walker, Curmudgeon at Large
Director
Institute for the Enhancement of the Director's income
-----------
What if the hokey pokey
really *is* what it’s all about?
--
Akira Kakuto
2018-03-24 22:14:53 UTC
Permalink
Dear Zdenek,
Post by Zdenek Wagner
latex and pdflatex executables exist on Windows
only but as a wrapper written in lua which calls
pdftex with &formatname.
Actually they are not wrappers, and they don't call
lua scripts. They use a common dynamic library pdftex.dll.
Accidentally, their size (1536 bytes) is the same as
that of script wrappers such as epstopdf.exe.

Thanks,
Akira
Zdenek Wagner
2018-03-24 23:20:27 UTC
Permalink
Post by Akira Kakuto
Dear Zdenek,
latex and pdflatex executables exist on Windows
Post by Zdenek Wagner
only but as a wrapper written in lua which calls
pdftex with &formatname.
Actually they are not wrappers, and they don't call
lua scripts. They use a common dynamic library pdftex.dll.
Accidentally, their size (1536 bytes) is the same as
that of script wrappers such as epstopdf.exe.
Thank you for explanation. I do not use TeX on Windows and my memory is
apparantly not so good.
Post by Akira Kakuto
Thanks,
Akira
Zdeněk Wagner
http://ttsm.icpf.cas.cz/team/wagner.shtml
http://icebearsoft.euweb.cz
Reinhard Kotucha
2018-03-24 23:54:39 UTC
Permalink
Post by Zdenek Wagner
latex and pdflatex executables exist on Windows only but as a
wrapper written in lua which calls pdftex with &formatname.
Not exactly. The Lua wrappers are used by scripts. pdflatex.exe is a
tiny program written in C which loads pdftex.dll and, dependent on
argv[0], the appropriate format file. No Lua involved here.

Scripts have to be treated differently. First of all, their locations
within the TEXMF trees and the appropriate interpreter have to be
determined. Furthermore, Perl and Ghostscript have to be added to
PATH. The details are explained in

bin/win32/runscript.tlu

So we use different wrappers for TeX programs in bin/win32 and scripts
in TEXMF. In older versions of TeX Live you could distinguish between
these wrappers by file size. This doesn't seem to be the case anymore

$ ls -l updmap.exe pdftex.exe
-rwxr-xr-x 1 reinhard users 1536 Nov 25 2016 pdftex.exe
-rwxr-xr-x 1 reinhard users 1536 Nov 25 2016 updmap.exe

$ cmp updmap.exe pdflatex.exe
updmap.exe pdflatex.exe differ: byte 137, line 2

$ strings updmap.exe | grep '\.dll$'
runscript.dll
msvcrt.dll

$ strings pdftex.exe | grep '\.dll$'
pdftex.dll
msvcrt.dll

All the script related .exe wrappers are identical on purpose and
invoke runscript.dll which in turn executes runscript.tlu.

In order to support an additional script you have to

copy runscript.exe mynewsript.exe

but you run into trouble if you

copy pdftex.exe mynewsript.exe
Post by Zdenek Wagner
On unix systems (including Mac) these are just symlinks to
pdftex. If you use unix system, then cd to the executable directory
ln -s pdftex latex
ln -s pdftex pdflatex
You just mention 2 of 263 symlinks. You did something completely
wrong before if you have to create all of them manually. The preferred
approach is

$ cd /path/to/svn/trunk/Build/source
$ ./Build <configure options>

The programs *and* symlinks are then in

/path/to/svn/trunk/Build/source/inst/bin/<platform>

Regards,
Reinhard
--
------------------------------------------------------------------
Reinhard Kotucha Phone: +49-511-3373112
Marschnerstr. 25
D-30167 Hannover mailto:***@web.de
------------------------------------------------------------------
pilot constatinus
2018-03-25 06:10:16 UTC
Permalink
Thanks to all. My problem is finally solved. I didn't know that pdftex will
judge the format just by the symlink name. Thanks.
Post by Reinhard Kotucha
Post by Zdenek Wagner
latex and pdflatex executables exist on Windows only but as a
wrapper written in lua which calls pdftex with &formatname.
Not exactly. The Lua wrappers are used by scripts. pdflatex.exe is a
tiny program written in C which loads pdftex.dll and, dependent on
argv[0], the appropriate format file. No Lua involved here.
Scripts have to be treated differently. First of all, their locations
within the TEXMF trees and the appropriate interpreter have to be
determined. Furthermore, Perl and Ghostscript have to be added to
PATH. The details are explained in
bin/win32/runscript.tlu
So we use different wrappers for TeX programs in bin/win32 and scripts
in TEXMF. In older versions of TeX Live you could distinguish between
these wrappers by file size. This doesn't seem to be the case anymore
$ ls -l updmap.exe pdftex.exe
-rwxr-xr-x 1 reinhard users 1536 Nov 25 2016 pdftex.exe
-rwxr-xr-x 1 reinhard users 1536 Nov 25 2016 updmap.exe
$ cmp updmap.exe pdflatex.exe
updmap.exe pdflatex.exe differ: byte 137, line 2
$ strings updmap.exe | grep '\.dll$'
runscript.dll
msvcrt.dll
$ strings pdftex.exe | grep '\.dll$'
pdftex.dll
msvcrt.dll
All the script related .exe wrappers are identical on purpose and
invoke runscript.dll which in turn executes runscript.tlu.
In order to support an additional script you have to
copy runscript.exe mynewsript.exe
but you run into trouble if you
copy pdftex.exe mynewsript.exe
Post by Zdenek Wagner
On unix systems (including Mac) these are just symlinks to
pdftex. If you use unix system, then cd to the executable directory
ln -s pdftex latex
ln -s pdftex pdflatex
You just mention 2 of 263 symlinks. You did something completely
wrong before if you have to create all of them manually. The preferred
approach is
$ cd /path/to/svn/trunk/Build/source
$ ./Build <configure options>
The programs *and* symlinks are then in
/path/to/svn/trunk/Build/source/inst/bin/<platform>
Regards,
Reinhard
--
------------------------------------------------------------------
Reinhard Kotucha Phone: +49-511-3373112
Marschnerstr. 25
------------------------------------------------------------------
Loading...