Re: [NTG-pdftex] [tex-live] Debian TeX -- new packages
Hi, From a discussion on TeX-Live with regard to the debian texlive packages for texlive and the complications raised by libpoppler: Sanjoy Mahajan wrote:
[What I describe below is not a Debian problem, but the proposed change would make the packages easier for Ubuntu users to use.
I added dev-context to the CC: list since the pkg deps affect Ubuntu users -- e.g. me -- who use your excellent ConTeXt packages.]
I'm using Ubuntu 6.10 (edgy) with all your tug.org stanzas. An "apt-get install texlive-base-bin" or "apt-get install context" fails when going from the TL2005 packages to the 2007 ones. The blocking package is texlive-base-bin:
# apt-get install texlive-base-bin texlive-base-bin: Depends: libpng12-0 (>= 1.2.13-4) but 1.2.8rel-5.1ubuntu0.1 is to be installed Depends: libpoppler0c2 (>= 0.4.2) but it is not installable E: Broken packages
I'll upgrade to the Ubuntu 7.04 beta, which will solve the libpng12-0 problem because Ubuntu 7.04 uses libpng 1.2.15. But libpoppler0c2 would still be missing. Here are the libpoppler pkgs in versions of
If I understand that thread correctly, the use of poppler instead of xpdf is now really a requirement on both debian and ubuntu? And you cannot share the binary packages between the various linuxes because there are packaging differences that cannot be resolved, at all? And that there are different versions of (dynamic) libpoppler that are mutually exclusive, even at compile-time? But at the same time, static binaries with xpdf linked in are not usable or 'not done' for some reason? If this is a sign of things to come, I may have to reconsider switching to MacOSX or freebsd. Taco
Taco Hoekwater wrote:
If this is a sign of things to come, I may have to reconsider switching to MacOSX or freebsd.
thanks for the warning; very disturbing indeed even if the default linux linking is against poopler, users should have the freedom to use for instance xpdf as fallback or alternative Hans ----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com | www.pragma-pod.nl -----------------------------------------------------------------
Probably everyone on ntg-pdftex also reads tex-live. However, for completeness, here is the relevant piece of the msg that I just sent to ntg-context and the tex-live list: [Using Ubuntu 6.10/i386] I couldn't apply (without rejected hunks) the Ubuntu poppler patch at http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=356079 to the Debian texlive-2007-1 source. So I just removed debian/patches/30_libpoppler from the patch series, returning to using the xpdf sources that ship with pdftex. Then the texlive-2007 src pkg compiled into the many .deb's and these binary pkgs installed fine. They use libpng-1.2.8 and libc6-2.4.
If I understand that thread correctly, the use of poppler instead of xpdf is now really a requirement on both debian and ubuntu?
Right, both use libpoppler.
But at the same time, static binaries with xpdf linked in are not usable or 'not done' for some reason?
I think the reason is that xpdf and libpoppler frequently fix buffer overflows. By linking against a shared library (libpoppler) instead of against the xpdf sources, only the shared library needs to be updated, and there's no need to install new texlive binary packages. I'm not sure how much I agree with this argument. It does have downsides.
And you cannot share the binary packages between the various linuxes because there are packaging differences that cannot be resolved, at all?
Right. Library version skew. There are two libraries causing problems: libpng and libpoppler. * libpng: Norbert's texlive2007 packages are for Debian unstable and they require a libpng >= 1.2.13. Ubuntu won't be sufficiently updated until feisty (7.04, i.e. next month), and all older releases of Ubuntu use 1.2.8. That's not a problem in general because you could download the source package and recompile, but... * libpoppler. Debian and Ubuntu have decided to use libpoppler as a shared library instead of the xpdf sources included in the texlive tree already. Norbert's packages require libpoppler0c2 (which is libpoppler 0.4.5). Ubuntu hasn't used libpoppler0c2 for over a year, and they use libpoppler1, which is 0.5.x where x=1 for Dapper (6.04) and 4 for Edgy (6.10) and Feisty (7.04). So, rebuilding the source package on my system (Ubuntu 6.10) fails because my system has the libpoppler1 development library (API), which differs from libpoppler0c2 in Unicode string handling. One solution is to patch the texlive2007 tree to correctly use libpoppler1. But I don't know how to do that. Ubuntu has a patch but it is for doing the same for tetex-3.0, and I couldn't figure out how to get it to apply to texlive2007 (too many rejected hunks got me worried). So I just removed the use of libpoppler, instead using the xpdf in-tree sources, and it compiled fine. That's a one-line patch to the source tree (the debian patch series part of it). With those changes, I can use Norbert's latest and greatest context packages. But I know what I'm doing, relatively speaking. Most users on Ubuntu will be stuck until Ubuntu feisty+1 (till October 2007), because texlive2007 is too late to go into feisty (April 2007) and I don't think I should recommend these hacks on the context wiki (in the Ubuntu instructions). So almost all Ubuntu users will have to upgrade context by hand -- not good for them or for getting a wide testing base for context. One of the issues that would hold up texlive2007 in Ubuntu is that Debian didn't transition to the newer libpoppler http://lists.debian.org/debian-tex-maint/2006/10/msg00026.html because of the pain it would cause. So Ubuntu, which picks up Debian unstable and does some stuff to it, is divergent from Debian on this point (Ubuntu has used the newer libpoppler for a while), which was fine for texlive2005 I guess, but not for texlive2007. Which means that Ubuntu would have to do more work to get texlive2007 working -- for which there is no time before the release.
And that there are different versions of (dynamic) libpoppler that are mutually exclusive, even at compile-time?
They are not exclusive at run time, only at compile time. One approach I tried was to install a libpoppler0c2 from an old Ubuntu release, so now I have libpoppler.0 and libpoppler.1 on my system. Then the texlive-2007 binary pkgs could install except that it requires libpng >=1.2.13. Hence the need to recompile from the source pkg in order to compile against my libpng (1.2.8). But the compile fails because of the libpoppler1 headers on my system. And I cannot install an old libpoppler0 set of development headers, because those would overwrite the newer libpoppler1 development headers. I suppose I could install them, compile the src pkg, then reinstall the libpoppler1 development headers. But that's a terrible hack (plus I didn't think of it until now). -Sanjoy `Not all those who wander are lost.' (J.R.R. Tolkien)
Taco Hoekwater
If I understand that thread correctly, the use of poppler instead of xpdf is now really a requirement on both debian and ubuntu?
Err, no. The precompiled binary packages use libpoppler. That doesn't mean you can't compile your own pdftex, or even download the Debian sources, disable the poppler patch and build your own Debian package. And, in particular, it doesn't say anything about the TeXLive images on tug.org/CTAN: They do not use poppler.
And you cannot share the binary packages between the various linuxes because there are packaging differences that cannot be resolved, at all?
This is true (for the debs), but it's a very usual thing on a Linux system, that's why we have distinct releases (and much less of a DLL hell as some other OSses are said to have).
And that there are different versions of (dynamic) libpoppler that are mutually exclusive, even at compile-time?
Yes, and even that is very common - that's what usually is indicated by a soname change of a library. We (Debian/Ubuntu) have made the switch to poppler very early in its development, and this means that we're likely to face a couple of soname changes. Maybe later the API will become more stable.
But at the same time, static binaries with xpdf linked in are not usable or 'not done' for some reason?
They are of course perfectly usable, and they are available in the tug.org/CTAN images. We just don't provide any as debs, because our security team isn't able to handle all the instances of xpdf code in multiple versions which are embedded in o-so-many project's source.
If this is a sign of things to come, I may have to reconsider switching to MacOSX or freebsd.
There is nothing special to poppler about this situation. The same is also true, and has been true for ages, with libpng, libjpeg, libstdc++ etc., against which pdftex is linked, as soon as it is dynamically linked. There's also nothing special to pdftex about it, it's the same for any other program that links dynamically. And I think it is common that Linux distributions link dynamically, and there are good reasons for it. These reasons are probably stronger for programs you just use in bypassing, and much less strong for those where you are involved in development. If you don't like it, you're free to just not use the distribution's TeXLive packages, but install it from the images on tug.org/CTAN. You can do that for any OS Regards, Frank -- Dr. Frank Küster Single Molecule Spectroscopy, Protein Folding @ Inst. f. Biochemie, Univ. Zürich Debian Developer (teTeX/TeXLive)
Hi Frank, Frank Küster wrote:
Yes, and even that is very common - that's what usually is indicated by a soname change of a library. We (Debian/Ubuntu) have made the switch to poppler very early in its development, and this means that we're likely to face a couple of soname changes. Maybe later the API will become more stable.
As far as I know, it is not at all common that a program that uses a certain library in the repository is then redistributed using a different library altogether, with one version of that library available in one distro and another, incompatible version on another distibution. The connection with the main source is almost gone. And that is what has me worried. If everybody links with poppler, poppler should be in the repository, not xpdf. Regards, Taco
On 3/30/07, Taco Hoekwater
Frank Küster wrote:
Yes, and even that is very common - that's what usually is indicated by a soname change of a library. We (Debian/Ubuntu) have made the switch to poppler very early in its development, and this means that we're likely to face a couple of soname changes. Maybe later the API will become more stable.
As far as I know, it is not at all common that a program that uses a certain library in the repository is then redistributed using a different library altogether, with one version of that library available in one distro and another, incompatible version on another distibution. The connection with the main source is almost gone. And that is what has me worried.
If everybody links with poppler, poppler should be in the repository, not xpdf.
Poppler need not be in the reposity, but it should be detected and
enabled, or available as a build option.
Such changes take time. We are likely to see simiilar issues for xetex and the
font libraries (especially if there are big changes in the way math
fonts are handled).
It takes time for new libraries to be ported to legacy platforms.
Some new libraries
may end up being discarded when some fundamental design flaw is
discovered or something better comes along.
Many packages already have configure options to select different
libraries -- xdvi can be built against 4 different X-toolkits (Xaw,
Motif 1.2, Motif 2.x, LessTif). The repository needs to support
transitional situations by providing multiple libraries and supporting
builds with either. It is messy, but necessary if you are going to
support legacy systems without stopping innovation and security
improvements.
--
George N. White III
Taco Hoekwater
If everybody links with poppler, poppler should be in the repository, not xpdf.
I have half-finished autoconf magic to make the switch to poppler configurable. If you volunteer to finish it, I can send it to you. Regards, Frank -- Dr. Frank Küster Single Molecule Spectroscopy, Protein Folding @ Inst. f. Biochemie, Univ. Zürich Debian Developer (teTeX/TeXLive)
Hi Frank, Frank Küster wrote:
Taco Hoekwater
wrote: If everybody links with poppler, poppler should be in the repository, not xpdf.
I have half-finished autoconf magic to make the switch to poppler configurable. If you volunteer to finish it, I can send it to you.
Since I am the one complaining, that would definately be fair. But before I say yes, how much knowledge would be needed? I know only a very little bit about autoconf, and unless there is a good manual you can point me to, it could take me a long time to learn. Best wishes. Taco
2007/4/1, Taco Hoekwater
Frank Küster wrote:
I have half-finished autoconf magic to make the switch to poppler configurable. If you volunteer to finish it, I can send it to you.
Since I am the one complaining, that would definately be fair. But before I say yes, how much knowledge would be needed? I know only a very little bit about autoconf, and unless there is a good manual you can point me to, it could take me a long time to learn.
Taco, please finish luaTeX instead. :-) I know little about autofoo, but probably more than you, so I will help Frank. But please be patient. Not tomorrow, but definitely in time for 1.50. :-) I think it would help this effort if pdfTeX had a layer of abstraction between itself and xpdf/poppler/...; will work on that. Best Martin
"Martin Schröder"
I think it would help this effort if pdfTeX had a layer of abstraction between itself and xpdf/poppler/...; will work on that.
Once you've done that, you have the specifications (and probably some of the implementation) ready for the no-display C-only version of libpoppler, haven't you? Regards, Frank P.S. I'll send a diff with the autoconf stuff I have later -- Dr. Frank Küster Single Molecule Spectroscopy, Protein Folding @ Inst. f. Biochemie, Univ. Zürich Debian Developer (teTeX/TeXLive)
The autoconf manual is 'info autoconf', or as the autoconf entry in Emacs's info mode.
Since I am the one complaining, that would definately be fair.
I'm also been complaining, so if it doesn't require too much autoconf knowledge (I've written only one, short autoconf script, for an Othello program) I'll join Taco in finishing the autoconf magic.
half-finished autoconf magic to make the switch to poppler configurable.
Is the magic that autoconf should detect whether libpoppler0 (i.e. 0.4.x) and headers are on the system and use them if they are, otherwise use the in-tree xpdf? Or is that too much magic? -Sanjoy `Not all those who wander are lost.' (J.R.R. Tolkien)
2007/4/1, Sanjoy Mahajan
Is the magic that autoconf should detect whether libpoppler0 (i.e. 0.4.x) and headers are on the system and use them if they are, otherwise use the in-tree xpdf? Or is that too much magic?
The build should use the in-tree xpdf unless configure is instructed to use poppler (something like --with-poppler). Note that we already have patch 474 for tracking this feature. Best Martin
Taco Hoekwater
Hi Frank,
Frank Küster wrote:
Taco Hoekwater
wrote: If everybody links with poppler, poppler should be in the repository, not xpdf.
I have half-finished autoconf magic to make the switch to poppler configurable. If you volunteer to finish it, I can send it to you.
Since I am the one complaining, that would definately be fair. But before I say yes, how much knowledge would be needed? I know only a very little bit about autoconf, and unless there is a good manual you can point me to, it could take me a long time to learn.
I don't know much about autoconf, too, and I found the info manual, as well as other resources, hardly helpful: They teach you how to use existing macros, but not how to write new ones. I tried to prepare a diff of my working directory and normal texlive dir, but what I didn't remember was that I copied the poppler sources into the tree (because I thought it would be easier to make the dynamic-vs-static linking switch first, and xpdf vs poppler later). Since I am not sure which files in the poppler dir I touched, it doesn't make much sense to try to diff the trees without remembering what I did (and I don't have time for this ATM). Actually, what I did was pretty straightforward: I copied libfoo.ac (I think foo=png, but I'm not sure) and did simple replaces. I stopped when I came to the place were it was necessary to know how to detect installed poppler header files with autoconf, see above. Regards, Frank -- Dr. Frank Küster Single Molecule Spectroscopy, Protein Folding @ Inst. f. Biochemie, Univ. Zürich Debian Developer (teTeX/TeXLive)
participants (6)
-
Frank Küster
-
George N. White III
-
Hans Hagen
-
Martin Schröder
-
Sanjoy Mahajan
-
Taco Hoekwater