[Numpy-discussion] Problem installing numpy on Gentoo

Webb Sprague webb.sprague at gmail.com
Wed Jun 21 13:27:53 EDT 2006


I am trying to install numpy on Gentoo (see my info below for version
etc).  It all seems to go fine, but when I try to import it and run
the tests, I get the following error (in ipython):

In [1]: import numpy
import linalg -> failed: libg2c.so.0: cannot open shared object file:
No such file or directory

I have gfortran on my system, but libg2c is not part of the gcc-4.1.1
distribution anymore (maybe that is a bug with Gentoo?).  I also get
the same error when I run f2py from the command line.

Here is the bug I filed: http://bugs.gentoo.org/show_bug.cgi?id=136988

Info that might help:

cowboy ~ # ls /usr/lib/gcc/i686-pc-linux-gnu/4.1.1/
crtbegin.o     libgcc.a        libgfortran.so.1      libobjc.so.1.0.0
crtbeginS.o    libgcc_eh.a     libgfortran.so.1.0.0  libstdc++.a
crtbeginT.o    libgcc_s.so     libgfortranbegin.a    libstdc++.so
crtend.o       libgcc_s.so.1   libgfortranbegin.la   libstdc++.so.6
crtendS.o      libgcov.a       libobjc.a             libstdc++.so.6.0.8
crtfastmath.o  libgfortran.a   libobjc.la            libstdc++_pic.a
include        libgfortran.la  libobjc.so            libsupc++.a
install-tools  libgfortran.so  libobjc.so.1          libsupc++.la

cowboy ~ # ls /usr/lib/gcc/i686-pc-linux-gnu/3.4.6/
SYSCALLS.c.X            libffi.la        libobjc.la
crtbegin.o              libffi.so        libobjc.so
crtbeginS.o             libfrtbegin.a    libobjc.so.1
crtbeginT.o             libg2c.a         libobjc.so.1.0.0
crtend.o                libg2c.la        libstdc++.a
crtendS.o               libg2c.so        libstdc++.la
hardened.specs          libg2c.so.0      libstdc++.so
hardenednopie.specs     libg2c.so.0.0.0  libstdc++.so.6
hardenednopiessp.specs  libgcc.a         libstdc++.so.6.0.3
hardenednossp.specs     libgcc_eh.a      libstdc++_pic.a
include                 libgcc_s.so      libsupc++.a
install-tools           libgcc_s.so.1    libsupc++.la
libffi-2.00-beta.so     libgcov.a        specs
libffi.a                libobjc.a        vanilla.specs
cowboy ~ # emerge --info
Portage 2.1.1_pre1-r1 (default-linux/x86/2006.0, gcc-4.1.1/vanilla,
glibc-2.4-r3, 2.6.11-gentoo-r9 i686)
=================================================================
System uname: 2.6.11-gentoo-r9 i686 AMD Athlon(tm) Processor
Gentoo Base System version 1.12.1
distcc 2.18.3 i686-pc-linux-gnu (protocols 1 and 2) (default port
3632) [disabled]
ccache version 2.4 [enabled]
dev-lang/python:     2.4.3-r1
dev-python/pycrypto: 2.0.1-r5
dev-util/ccache:     2.4-r2
dev-util/confcache:  [Not Present]
sys-apps/sandbox:    1.2.18.1
sys-devel/autoconf:  2.13, 2.59-r7
sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2
sys-devel/binutils:  2.16.1-r2
sys-devel/gcc-config: 2.0.0_rc1
sys-devel/libtool:   1.5.22
virtual/os-headers:  2.6.11-r5
ACCEPT_KEYWORDS="x86 ~x86"
AUTOCLEAN="yes"
CBUILD="i686-pc-linux-gnu"
CFLAGS=" -march=athlon -O2 -pipe -fomit-frame-pointer"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/X11/xkb"
CONFIG_PROTECT_MASK="/etc/env.d /etc/eselect/compiler /etc/gconf
/etc/revdep-rebuild /etc/terminfo /etc/texmf/web2c"
CXXFLAGS=" -march=athlon -O2 -pipe -fomit-frame-pointer"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoconfig ccache distlocks metadata-transfer sandbox sfperms"
GENTOO_MIRRORS="http://distfiles.gentoo.org
http://distro.ibiblio.org/pub/linux/distributions/gentoo"
PKGDIR="/usr/portage/packages"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times
--compress --force --whole-file --delete --delete-after --stats
--timeout=180 --exclude='/distfiles' --exclude='/local'
--exclude='/packages'"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="x86 X alsa apache2 apm arts avi berkdb bitmap-fonts blas cli
crypt cups dba dri eds emacs emboss encode esd f77 fftw foomaticdb
fortran g77 gdbm gif gnome gpm gstreamer gtk gtk2 imlib ipv6 isdnlog
jpeg lapack libg++ libwww mad mikmod mime mmap motif mp3 mpeg ncurses
nls nptl nptlonly objc ogg opengl oss pam pcre pdflib perl png
postgres pppd python quicktime readline reflection sdl session spell
spl ssl svg tcltk tcpd tidy truetype truetype-fonts type1-fonts udev
unicode vorbis xml xmms xorg xv zlib elibc_glibc kernel_linux
userland_GNU"
Unset:  CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LANG, LC_ALL,
LDFLAGS, LINGUAS, MAKEOPTS, PORTAGE_RSYNC_EXTRA_OPTS

cowboy ~ # gcc --version
i686-pc-linux-gnu-gcc (GCC) 4.1.1 (Gentoo 4.1.1)
Copyright (C) 2006 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.




More information about the NumPy-Discussion mailing list