Compiling Perl on x86_64

Phred on 2006-11-12T10:54:44

Been playing with an opteron box (hp dl145g2) the past few days. I built Perl 5.8.8 on it today from source. You can't just go flying through the 'sh Configure' like you can with x86. You have to specify /usr/lib64 as an additional library path (important!), and I added the optimization flags '-march=opteron -mcpu=opteron -mtune=opteron -fpic -pipe -fomit-frame-pointer'. Most of those are just for fun, but -fpic seems to be important, as Dynaloader broke and whined about needing it when building mod_perl2.

So far quite a bit of fun - damn fast cpu - but Centos 4.4 doesn't have the correct sata driver fix in the kernel (you need at least 2.6.10), and my own kernel builds have been failing. I've given up on Centos (it was fun while it lasted) and gone back to Gentoo. A longer install initially, but at least I know that it won't leave me stranded in a dead end trying to get everything working. Ah the joys of Linux - at least my macbook hasn't been giving me any grief :)


vendor support

nicholas on 2006-11-12T16:50:25

You can't just go flying through the 'sh Configure' like you can with x86.

It's notable (and frustrating) that none of the Linux vendors who sell and support x86_64, and ship Perl on it, have sent any patches upstream for Configure, so that we can incorporate whatever change they feel is the most appropriate to solve these problems. They're the experts on Linux on x86_64, not us.

indeed

jhi on 2006-11-12T18:36:23

Nicholas++.

I have always wondered how we (perl maintainers) most of the time needed/need to go and hunt down the people at various UNIX/Linux people and hold them upside down and shake until they submit their changes back to us. It would be so much easier for *them* to feed the changes back so that they don't need to maintain them.

There are some notable exceptions: e.g. OpenBSD, Solaris, Mac OS X, where the people have been very good, proactive and communicated back (and forth) with the perl maintainers. For Linux distributions, it has varied a lot depending on who has been there.

I actually assume the same goes for any other open source project in general -- one would think it would be in everyone's interest to submit patches back to the original owner.

oh, and...

jhi on 2006-11-12T18:38:44

Once you have things working with x86_64, please do send a note to perl5-porters@perl.org of the changes you needed.

Re:oh, and...

Phred on 2006-11-13T03:59:42

Will do Jarkko, thanks for the feedback. I didn't have to do too much different, but I've cut my teeth on a few x86_64 headaches before, so some of it may seem obvious to me. I remember it was a lot harder the first time I used 64bit.

Re:oh, and...

jhi on 2006-11-13T05:10:31

Well, *64-bit* as such has of course worked with Perl for, oh, more than six years now :-)