develooper Front page | perl.perl5.porters | Postings from March 2011

Fwd: Re: [perl #86854] libs empty on Ubuntu 11.04 alpha (linux2.6.38-7-generic #38-Ubuntu)

Thread Next
From:
Dave Mitchell
Date:
March 30, 2011 08:04
Subject:
Fwd: Re: [perl #86854] libs empty on Ubuntu 11.04 alpha (linux2.6.38-7-generic #38-Ubuntu)
Message ID:
20110330150412.GS2900@iabyn.com
I'm just forwarding this email back to the list (and to RT), because for
some reason it hasn't shown up on the ticket, and possibly the OP hasn't
seen it.

Also, a question to the OP: does your Ubuntu alpha installation already
have a system perl installed on it; if so, could you post the output of
/usr/bin/perl -V ?

----- Forwarded message from Andy Dougherty <doughera@lafayette.edu> -----

Date: Thu, 24 Mar 2011 12:37:17 -0400 (EDT)
From: Andy Dougherty <doughera@lafayette.edu>
To: Perl Porters <perl5-porters@perl.org>
Subject: Re: [perl #86854] libs empty on Ubuntu 11.04 alpha (linux
	2.6.38-7-generic #38-Ubuntu)
Message-ID: <alpine.DEB.2.00.1103241207540.22420@fractal.phys.lafayette.edu>

On Wed, 23 Mar 2011, Ilmari Vacklin wrote:

> # New Ticket Created by  Ilmari Vacklin 
> # Please include the string:  [perl #86854]
> # in the subject line of all future correspondence about this issue. 
> # <URL: http://rt.perl.org/rt3/Ticket/Display.html?id=86854 >
> 
> 
> Hi,
> 
> I'm trying to compile perl-5.12.3 on Ubuntu 11.04 alpha 3, 32-bit
> variant. Configure fails to find any libs to link against, which
> causes make to fail because e.g. pow() isn't found (-lm is not used).

By default, Configure looks in the following directories for libraries:

    /usr/local/lib /lib /usr/lib /usr/lib64

It looks like Ubuntu has moved the math library (and presumably other 
libraries as well) out of /lib/ and /usr/lib into /lib/i386-linux-gnu. (I 
presume other names are used for other architectures, but I don't know 
what those other names actually are.) 

The quick workaround is to tell Configure about the new directory:

    sh Configure -Dplibpth=/lib/i386-linux-gnu -de

I don't know how Ubuntu is managing to compile perl for itself without 
such a workaround (or its equivalent).

Assuming this is a deliberate change in Ubuntu, the fix for 5.14 will be 
to detect this situation in the hints/linux.sh hint file and add the 
appropriate plibpth values automatically.  In order to do that, I could 
use some help:

Does anyone understand this new organization enough to suggest how to coax 
the necessary directory name (e.g. /lib/i386-linux-gnu) out of the build 
tools?  (For example, what should it be on an amd64 system?  How about 
PPC?  SPARC? Are there trailing 32s or 64s on any of those names?  etc.)

Clearly, however, the compiler on the system has been taught to look in 
the appropriate directories.  In the long term, perhaps Configure ought to 
consider looking for a library by trying to use it
	cc -o try try.c -lm
rather than trying to find the file libm.*.

-- 
    Andy Dougherty		doughera@lafayette.edu

----- End forwarded message -----

-- 
Indomitable in retreat, invincible in advance, insufferable in victory
    -- Churchill on Montgomery

Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About