开发者

bugzilla | perl module installation nightmare: no cc, is gcc OK?

开发者 https://www.devze.com 2023-04-09 01:11 出处:网络
I am trying to install Bugzilla.I don\'t recall it being so difficult.We have a ubuntu server on the cloud, and at first I attempted to install through the rackspace UI.This didn\'t work, so I ssh\'ed

I am trying to install Bugzilla. I don't recall it being so difficult. We have a ubuntu server on the cloud, and at first I attempted to install through the rackspace UI. This didn't work, so I ssh'ed in and actually downloaded the tarball to do it the old-fashioned way.

However, it appears there are three perl modules having install problems. I have tried everything I know to get them to install, and am at a loss. I've tried googling for some answers, but I am either not using the correct terminology or this is truly unique to my situation.

The three offending perl modules failing the checksetup.pl:

/usr/bin/perl install-module.pl DateTime
/usr/bin/perl install-module.pl DateTime::TimeZone
/usr/bin/perl install-module.pl Template

When I attempt to install any of them, they fail miserably, apparently because the cc compiler is not installed (see below). When I checked for a cc package under APT, I could only find gcc. Will that be sufficient, and will I need to alias gcc to cc in order for these installs to work?

/usr/bin/perl /usr/local/share/perl/5.10.1/ExtUtils/xsubpp  -typemap /usr/share/perl/5.10/ExtUtils/typemap  Stash.xs > Stash.xsc && mv Stash.xsc Stash.c
cc -c   -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fno-strict-aliasing -pipe -fstack-protector -I开发者_JAVA百科/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -O2 -g   -DVERSION=\"2.22\" -DXS_VERSION=\"2.22\" -fPIC "-I/usr/lib/perl/5.10/CORE"   Stash.c
/bin/sh: cc: not found
make[1]: *** [Stash.o] Error 127
make[1]: Leaving directory `/root/.cpan/build/Template-Toolkit-2.22-xzQg_q/xs'
make: *** [subdirs] Error 2
  ABW/Template-Toolkit-2.22.tar.gz
  /usr/bin/make -- NOT OK
Skipping test because of notest pragma
Running make install
  Make had returned bad status, install seems impossible


You shouldn't compile Perl with one compiler (cc) and then compile modules with another compiler or compiler build (gcc) unless you happen to know their compatible. I find it very hard to believe that Ubuntu provided a Perl built with a compiler they don't provide.

Then there's the issue that you're installing unmanaged modules into a distro-managed Perl. That's... less than ideal.

The simplest solution is probably:

apt-get install \
    libdatetime-perl \
    libdatetime-timezone-perl \
    libtemplate-perl

Another solution is to install a local build of Perl, perhaps using perlbrew.

Personally, I never use the system Perl. It's there for the system's needs first (not mine), and that causes problems. In this case, since the distro does provide the packages you need, it should be fine to just install those packages.


Just Install GCC and then Perl.To install the gcc package in the Debian/Ubuntu Linux distribution, enter the following command in a terminal:

> apt-get install gcc make linux-headers-$(uname -r)


I went ahead and installed the gcc package, and the installs completed. Whew. It has been a long time...

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号