[tlbuild] Building TL 2015

Richard Koch koch at math.uoregon.edu
Tue Dec 23 11:16:02 CET 2014


Folks,

Peter wrote

"close inspection of your config.log shows that ___gmpz_init is present, but
the link failed due to a duplicate symbol ___gmpz_abs (in sub_n.o and
init.o).  The problem seems to be that gcc-4.0.1 mishandles 'extern inline'.

"The original gmp-6.0.0a distribution contains a test for that, now copied to
the TL sources (r35881), but I am not sure that this changes the situation. You'll just have to try.


I retried yesterday morning, but without success. I don’t know if “rsync” picked
up this change, so I’ll try again today. Later experiments show that
Peter’s paragraphs are pointing in the right direction.

Reading the documentation about compiling TeX Live, I discovered that .Build
doesn’t rebuild the “configure” scripts. So I edited “configure” in the mpfr source
to omit the __gmpz_init test. To be specific, I replaced lines 6747 - 6752 with
blank lines.

After that, ./Build plowed through all the libraries without trouble and only ran into
trouble when compiling mpost. And the mpost complaint was about gmp
rather than mpfr, and indeed complained that the library contained duplicate
symbols ___gmpz_abs.

Therefore I believe with Peter that mpfr is not to blame and the problem is
those duplicate symbols in the gmp library.

An internet search shows that others had trouble with __gmpz_init while
compiling mpfr, and the cause was probably this same duplicate symbol in gmp.
There are many more links to duplicate symbol problems in the gmp library,
for OS X but also for other Unix systems.


———————

I looked up Peter’s earlier suggestion to read the tlbuild.pdf document and use

 ./Build --build=i686-apple-darwin9 CC='gcc -m32' CXX='g++ -m32' \
         OBJCXX='g++ -m32’

I couldn’t get the system to even accept this command. It claimed not to
understand “m32” or the equivalent “arch i386”. 

The command is described in tlbuild.pdf in the “cross compiling” section.
 I have very deliberately never cross compiled when making TeX Live
for OS X. I always Build the code on the machine which will be used to
run it.

In OS X 10.5, the compiler produces 32 bit code by default, even on a 64 bit
machine, and I have always compiled 32 bit Intel code on the machine I am using
now. Apple changed in OS X 10.6, where the compiler produces 64 bit code by
default.

————

Apple switched to Intel in 2006. For about six months they sold machines
with 32 bit processors, and then they switched to 64 bit processors for all
hardware. So we are supporting hardware that is at least eight years old
with the 32 bit compile.The time is coming when we’ll be able
to drop support for powerpc and for 32 bit Intel code.

I’m hoping, however, that we do that one step at a time, and leave the
code in a condition that older users could compile themselves with a
simple ./Build command. So let’s hope this duplicate symbol problem
can be solved!

Thanks, Peter, for what is surely the correct analysis of the problem.

Dick Koch




More information about the tlbuild mailing list