Problem Installing Perl 5.8.7 on Debian Stable

J

James E Keenan

I'm experiencing a problem installing Perl 5.8.7 on Debian Stable that
is similar to a previously reported -- but never fully solved --
problem.

In November 2003, reader King reported the following problem when he
tried to install Perl 5.8.2 on Debian:
[greatly snipped]
# sh Configure -de
.
You need to find a working C compiler.
Either (purchase and) install the C compiler supplied by your OS vendor,
or for a free C compiler try http://gcc.gnu.org/
I cannot continue any further, aborting.
#

This error continued even after he followed suggestions by other reader
and made sure that gcc was installed. Nothing seemed to work until
finally some magic was tried:

# apt-get install kernel-package libc6-dev tk8.3 libncurses5-dev
fakeroot bin86

But it was not clear why this worked.

Tonight, I tried to install Perl 5.8.7 on Debian stable. (Tried to do
so because it only came with Perl 5.8.4 -- and a very skeletal version
at that.) I got similar errors.

### START Configure error message ###
[snip]
Checking how to test for symbolic links...
Your builtin 'test -h' may be broken.
Trying external '/usr/bin/test -h'.
You can test for symbolic links with '/usr/bin/test -h'.


Good, your tr supports [:lower:] and [:upper:] to convert case.
Using [:upper:] and [:lower:] to convert case.
/usr/bin/ld: crt1.o: No such file: No such file or directory
collect2: ld returned 1 exit status
You need to find a working C compiler.
Either (purchase and) install the C compiler supplied by your OS
vendor,
or for a free C compiler try http://gcc.gnu.org/
I cannot continue any further, aborting.
### END Configure error message ###

But I had installed 'gcc' just minutes before trying to run Configure:

apt-get install gcc

reported no problems. 'man gcc' DWIMs.

So: (1) Why am I being told I have no working C compiler?

(2) Can anyone suggest a workaround? (I'm reluctant to try King's magic
unless/until I know why it did the trick.)

Thank you very much.
jimk
 
T

Tassilo v. Parseval

Also sprach James E Keenan:
I'm experiencing a problem installing Perl 5.8.7 on Debian Stable that
is similar to a previously reported -- but never fully solved --
problem.

In November 2003, reader King reported the following problem when he
tried to install Perl 5.8.2 on Debian:
[greatly snipped]
# sh Configure -de
.
You need to find a working C compiler.
Either (purchase and) install the C compiler supplied by your OS vendor,
or for a free C compiler try http://gcc.gnu.org/
I cannot continue any further, aborting.
#

This error continued even after he followed suggestions by other reader
and made sure that gcc was installed. Nothing seemed to work until
finally some magic was tried:

# apt-get install kernel-package libc6-dev tk8.3 libncurses5-dev
fakeroot bin86

But it was not clear why this worked.

Tonight, I tried to install Perl 5.8.7 on Debian stable. (Tried to do
so because it only came with Perl 5.8.4 -- and a very skeletal version
at that.) I got similar errors.

What do you mean with skeletal? You probably only have perl-base
installed which contains the interpreter and only an essential subset of
the standard modules. You also need the packages perl, perl-modules and
perl-doc to get a complete standard 5.8.4 distribution.
### START Configure error message ###
[snip]
Checking how to test for symbolic links...
Your builtin 'test -h' may be broken.
Trying external '/usr/bin/test -h'.
You can test for symbolic links with '/usr/bin/test -h'.


Good, your tr supports [:lower:] and [:upper:] to convert case.
Using [:upper:] and [:lower:] to convert case.
/usr/bin/ld: crt1.o: No such file: No such file or directory

crt1.o is contained in the package libc6-dev. If you don't have that
package installed, the gcc is virtually useless as you cannot compile
anything useful without the header- and object-files of the libc.

Of course, if you're lacking something as essential as that I wouldn't
be surprised if you were also lacking other important packages needed to
compile perl, such as make or so.
collect2: ld returned 1 exit status
You need to find a working C compiler.
Either (purchase and) install the C compiler supplied by your OS
vendor,
or for a free C compiler try http://gcc.gnu.org/
I cannot continue any further, aborting.
### END Configure error message ###

But I had installed 'gcc' just minutes before trying to run Configure:

apt-get install gcc

reported no problems. 'man gcc' DWIMs.

So: (1) Why am I being told I have no working C compiler?

(2) Can anyone suggest a workaround? (I'm reluctant to try King's magic
unless/until I know why it did the trick.)

It probably did the trick because it included 'apt-get install
libc6-dev'.

Tassilo
 
J

James E Keenan

Tassilo said:
[snip]
What do you mean with skeletal? You probably only have perl-base
installed which contains the interpreter and only an essential subset of
the standard modules. You also need the packages perl, perl-modules and
perl-doc to get a complete standard 5.8.4 distribution.

I gathered that. But I figured that if I was going to have to do more
work to get a functioning 5.8.4, I'd do the work needed to get a
functioning 5.8.7 instead. And since I was simultaneously and
successfully building 5.8.7 on my laptop, I figured I'd have no
problem.
[snip]
crt1.o is contained in the package libc6-dev. If you don't have that
package installed, the gcc is virtually useless as you cannot compile
anything useful without the header- and object-files of the libc.

Of course, if you're lacking something as essential as that I wouldn't
be surprised if you were also lacking other important packages needed to
compile perl, such as make or so.

[snip]
It probably did the trick because it included 'apt-get install
libc6-dev'.
Your hunch was absolutely correct. I installed libc6-dev and was
thereafter able to run Configure, make, etc. successfully. So now I
have done my first build of Perl on Debian. Thank you very much.

jimk
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,756
Messages
2,569,535
Members
45,008
Latest member
obedient dusk

Latest Threads

Top