Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 128993 - dev-python/numpy-0.9.6 has build errors
Summary: dev-python/numpy-0.9.6 has build errors
Status: RESOLVED INVALID
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Library (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Python Gentoo Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-04-05 22:58 UTC by Hypnos
Modified: 2006-06-07 20:38 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Hypnos 2006-04-05 22:58:41 UTC
TAIL OF OUTPUT:

###########
i686-pc-linux-gnu-gcc: build/src/atlas_version_0x26de9279.c
/usr/bin/g77 -Wl,-O1 build/temp.linux-i686-2.4/build/src/atlas_version_0x26de9279.o -L/usr/lib -llapack -llapack -lblas -lcblas -latlas -lg2c -o build/temp.linux-i686-2.4/atlas_version.so
build/temp.linux-i686-2.4/build/src/atlas_version_0x26de9279.o: In function `initatlas_version':
atlas_version_0x26de9279.c:(.text+0x43): undefined reference to `Py_InitModule4'/usr/lib/gcc/i686-pc-linux-gnu/3.4.5/libfrtbegin.a(frtbegin.o): In function `main':
main.c:(.text+0x35): undefined reference to `MAIN__'
collect2: ld returned 1 exit status
build/temp.linux-i686-2.4/build/src/atlas_version_0x26de9279.o: In function `initatlas_version':
atlas_version_0x26de9279.c:(.text+0x43): undefined reference to `Py_InitModule4'/usr/lib/gcc/i686-pc-linux-gnu/3.4.5/libfrtbegin.a(frtbegin.o): In function `main':
main.c:(.text+0x35): undefined reference to `MAIN__'
collect2: ld returned 1 exit status
##### msg: error: Command "/usr/bin/g77 -Wl,-O1 build/temp.linux-i686-2.4/build/src/atlas_version_0x26de9279.o -L/usr/lib -llapack -llapack -lblas -lcblas -latlas -lg2c -o build/temp.linux-i686-2.4/atlas_version.so" failed with exit status 1
error: Command "/usr/bin/g77 -Wl,-O1 build/temp.linux-i686-2.4/build/src/atlas_version_0x26de9279.o -L/usr/lib -llapack -llapack -lblas -lcblas -latlas -lg2c -o build/temp.linux-i686-2.4/atlas_version.so" failed with exit status 1
  FOUND:
    libraries = ['lapack', 'lapack', 'blas', 'cblas', 'atlas']
    library_dirs = ['/usr/lib']
    language = f77
    define_macros = [('NO_ATLAS_INFO', 2)]
    include_dirs = ['/usr/include/atlas']

Warning: distutils distribution has been initialized, it may be too late to add an extension lapack_lite
Warning: distutils distribution has been initialized, it may be too late to add a subpackage linalg
Warning: distutils distribution has been initialized, it may be too late to add an extension mtrand
Warning: distutils distribution has been initialized, it may be too late to add a subpackage random
Traceback (most recent call last):
  File "setup.py", line 76, in ?
    setup_package()
  File "setup.py", line 63, in setup_package
    config.add_subpackage('numpy')
  File "/var/tmp/portage/numpy-0.9.6/work/numpy-0.9.6/numpy/distutils/misc_util.py", line 592, in add_subpackage
    config_list = self.get_subpackage(subpackage_name,subpackage_path)
  File "/var/tmp/portage/numpy-0.9.6/work/numpy-0.9.6/numpy/distutils/misc_util.py", line 582, in get_subpackage
    subpackage_path)
  File "/var/tmp/portage/numpy-0.9.6/work/numpy-0.9.6/numpy/distutils/misc_util.py", line 539, in _get_configuration_from_setup_py
    config = setup_module.configuration(*args)
  File "/var/tmp/portage/numpy-0.9.6/work/numpy-0.9.6/numpy/setup.py", line 15, in configuration
    config.add_data_dir('doc')
  File "/var/tmp/portage/numpy-0.9.6/work/numpy-0.9.6/numpy/distutils/misc_util.py", line 636, in add_data_dir
    self.add_data_files((ds,filenames))
  File "/var/tmp/portage/numpy-0.9.6/work/numpy-0.9.6/numpy/distutils/misc_util.py", line 702, in add_data_files
    dist.data_files.extend(data_dict.items())
AttributeError: 'NoneType' object has no attribute 'extend'

!!! ERROR: dev-python/numpy-0.9.6 failed.
Call stack:
  ebuild.sh, line 1526:   Called dyn_compile
  ebuild.sh, line 923:   Called src_compile
  ebuild.sh, line 1236:   Called distutils_src_compile
  distutils.eclass, line 35:   Called die

!!! compilation failed
!!! If you need support, post the topmost build error, and the call stack if relevant.
###########


EMERGE INFO:

#############
Portage 2.1_pre7-r2 (default-linux/x86/2006.0, gcc-3.4.5, glibc-2.3.5-r0, 2.6.13 i686)
=================================================================
System uname: 2.6.13 i686 Intel(R) Pentium(R) 4 Mobile CPU 1.60GHz
Gentoo Base System version 1.6.14
dev-lang/python:     2.2.3-r5, 2.3.5, 2.4.1-r1
sys-apps/sandbox:    1.2.12
sys-devel/autoconf:  2.13, 2.59-r6
sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r1
sys-devel/binutils:  2.11.92.0.12.3-r2, 2.16.1
sys-devel/libtool:   1.5.18-r1
virtual/os-headers:  2.6.7-r4
ACCEPT_KEYWORDS="x86"
AUTOCLEAN="yes"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-pipe -Wall -Wno-error -O2 -mtune=pentium4 -march=pentium4"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3/share/config /usr/share/X11/xkb /usr/share/config /usr/share/texmf/dvipdfm/config/ /usr/share/texmf/dvips/config/ /usr/share/texmf/tex/generic/config/ /usr/share/texmf/tex/platex/config/ /usr/share/texmf/xdvi/ /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/afs/C /etc/afs/afsws /etc/eselect/compiler /etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-pipe -Wall -Wno-error -O2 -mtune=pentium4 -march=pentium4"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoconfig collision-protect distlocks metadata-transfer sandbox sfperms strict userprive usersandbox"
GENTOO_MIRRORS="http://distfiles.gentoo.org http://distro.ibiblio.org/pub/linux/distributions/gentoo"
LDFLAGS="-Wl,-O1"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/home/system/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="x86 16bit 3ds S3TC X X509 a52 aac acpi acpi4linux aim alsa amd amr ansi apache2 asf asm asterisk async atlas avahi avantgo avi bcmath beep berkdb bidi bindist bitmap-fonts blas bonjour bonobo bots bzlib c++ cacheemu cairo callbacks canna cap caps cardbus cdda cddb cdf cdinstall cdio cdparanoia cdrom cgi chroot cjk clamav clanJavaScript clanVoice cli client cln codecs composite corba cpdflib cpudetection cpulimit cracklib crypt css csv ctype cups custom-cflags daap db2 dba dbase dbm dbus dbx dga dhcp dio disk-cache distcache distribution divx dlopen dlz dnd dnsdb dpms dri dv dvb dvd dvdread ecc eds emboss emoticon encode enscript erandom esd ethereal evo evo2 examples exiscan exiscan-acl expat ext-png ext-zlib extensions extlib extraicons extramodules extras f77 faad fame fastbuild fax fdftk festival fftw finger firebird firefox fits flash flatfile fluidsynth fmod foomaticdb force-cgi-redirect fortran fpx freetts freetype freewnn fs ftp fullrpc fusion fwdzone gamma gd gd-external gdbm gecko-sdk geoip gg gif gimp gimpprint ginac glade glgd glibc glitz gmail gmtfull gmthigh gmtsuppl gmttria gnome gnomedb gnuplot gnustep gpgme gpm gps graphviz gs gsl gsm gsnd gstreamer gtk gtk2 h323 hbci hdf hdf5 hlapi html http httpd icq icu id3 ide idea idl image imap imlib imlib2 informix inifile inkjar innodb input_devices_evdev input_devices_keyboard input_devices_mouse input_devices_synaptics iodbc ipalias ipcs ipv6 ipv6arpa irc irda irmc isdnlog jabber javascript jikes jp2 jpeg jpeg2k justify kakasi kerberos krb4 ladcca ladspa lapack latex libclamav libdsk libg++ libgd libgda libsamplerate libvisual libwww lids live lj lmtp logrotate lzo lzw lzw-tiff mad mailbox maildir maildrop mailwrapper make-busybox-symlinks make-symlinks math matroska mbox mbrola mcal mcve md5sum mdb mecab memlimit messages mew mhash migemo mikmod milter mime mimencode ming mixer mjpeg mldonkeypango mmap mmx mmxext monkey moznocompose moznoirc moznomail mozp3p mozsvg mp3 mpeg mpeg4 mpi mplayer msdav msn msql mssql multicall multipleip music musicbrainz mysqli nagios-dns nagios-game nagios-ntp nagios-ping nagios-ssh native ncurses net netcdf network neural nls nntp nogcj nomotif nptl nsplugin numeric nviz oav oci8 octave ode offensive ofx ogdi ogg openexr opengl openntpd openssh operanom2 opie oracle oracle7 orathreads ortp oscar oss pam pam_chroot pam_console pam_timestamp pango parse-clocks passfile password pcap pcmcia pcre pda pdf pdfkit pdflib pfpro pg-hier pg-intdatetime pg-vacuumdelay physfs pic plugin png pnp portaudio posix ppds pppd print priority psyco pthreads pwdb python qhull quicktime quotas quotes radeon radius rar rdesktop readline real recode regexp remix rhythmbox roundrobin rpc rplay rpm rss rtc sapdb sasl savedconfig screenshot sdl sendfile session sharedmem shorten silc simplexml sis skey slp smime sms sndfile soap sockets sounds soundtouch sox speedo spell spl sql sqlite3 sse sse2 ssl stencil-buffer subversion svgz sybase sybase-ct sysfs sysvipc szip t1lib tagwriting tga theora timidity tokenizer transcode truetype truetype-fonts trusted type1 type1-fonts ucs2 udev unicode utf8 v4l v4l2 vcd vcdimager vda vdesktop vhosts video_cards_ati videos vidix vim-with-x virus-scan visualization vmdbmysql vmdbpostgres vnc voice vorbis wifi wildlsearch win32codecs wma wma123 wordperfect wsconvert wv xanim xatrix xbase xface xim xinerama xml xmlrpc xosd xpm xrandr xscreensaver xsl xv xvmc yahoo yaz yv12 zlib zvbi elibc_glibc kernel_linux userland_GNU video_cards_vesa video_cards_fbdev"Unset:  ASFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LANG, LC_ALL, LINGUAS
###############

A Python version mismatch?
Comment 1 Sébastien Fabbro (RETIRED) gentoo-dev 2006-06-07 10:40:00 UTC
It looks like you have problems with compiler versions. you may have compiled atlas with gfortran (gcc-4) but are trying to compile numpy with gcc-3.
I put an ebuild for numpy-0.9.8 updated in the Gentoo Scientific overlay in http://gentooscience.org. Could you test and report in this bug?
Comment 2 Hypnos 2006-06-07 15:57:35 UTC
Here is a tail of the error with numpy-0.9.8 from the overlay:

###
i686-pc-linux-gnu-gcc: numpy/linalg/lapack_litemodule.c
/usr/bin/g77 -Wl,-O1 build/temp.linux-i686-2.4/numpy/linalg/lapack_litemodule.o -L/usr/lib -llapack -llapack -lblas -lcblas -latlas -lg2c -o build/lib.linux-i686-2.4/numpy/linalg/lapack_lite.so

build/temp.linux-i686-2.4/numpy/linalg/lapack_litemodule.o: In function `check_object':
lapack_litemodule.c:(.text+0x3a): undefined reference to `PyType_IsSubtype'
lapack_litemodule.c:(.text+0x7e): undefined reference to `PyErr_Format'
lapack_litemodule.c:(.text+0xb2): undefined reference to `PyErr_Format'
build/temp.linux-i686-2.4/numpy/linalg/lapack_litemodule.o: In function `lapack_lite_dgeev':
lapack_litemodule.c:(.text+0x16d): undefined reference to `PyArg_ParseTuple'
lapack_litemodule.c:(.text+0x395): undefined reference to `Py_BuildValue'
build/temp.linux-i686-2.4/numpy/linalg/lapack_litemodule.o: In function `lapack_lite_dsyevd':
lapack_litemodule.c:(.text+0x432): undefined reference to `PyArg_ParseTuple'
lapack_litemodule.c:(.text+0x5e4): undefined reference to `Py_BuildValue'
build/temp.linux-i686-2.4/numpy/linalg/lapack_litemodule.o: In function `lapack_lite_zheevd':
lapack_litemodule.c:(.text+0x692): undefined reference to `PyArg_ParseTuple'
lapack_litemodule.c:(.text+0x89a): undefined reference to `Py_BuildValue'
build/temp.linux-i686-2.4/numpy/linalg/lapack_litemodule.o: In function `lapack_lite_dgelsd':
lapack_litemodule.c:(.text+0x952): undefined reference to `PyArg_ParseTuple'
lapack_litemodule.c:(.text+0xb64): undefined reference to `Py_BuildValue'
build/temp.linux-i686-2.4/numpy/linalg/lapack_litemodule.o: In function `lapack_lite_dgesv':
lapack_litemodule.c:(.text+0xbe3): undefined reference to `PyArg_ParseTuple'
lapack_litemodule.c:(.text+0xd31): undefined reference to `Py_BuildValue'
build/temp.linux-i686-2.4/numpy/linalg/lapack_litemodule.o: In function `lapack_lite_dgesdd':
lapack_litemodule.c:(.text+0xde3): undefined reference to `PyArg_ParseTuple'
lapack_litemodule.c:(.text+0x1010): undefined reference to `Py_BuildValue'
build/temp.linux-i686-2.4/numpy/linalg/lapack_litemodule.o: In function `lapack_lite_dgetrf':
lapack_litemodule.c:(.text+0x107b): undefined reference to `PyArg_ParseTuple'
lapack_litemodule.c:(.text+0x117c): undefined reference to `Py_BuildValue'
build/temp.linux-i686-2.4/numpy/linalg/lapack_litemodule.o: In function `lapack_lite_dpotrf':
lapack_litemodule.c:(.text+0x11da): undefined reference to `PyArg_ParseTuple'
lapack_litemodule.c:(.text+0x128b): undefined reference to `Py_BuildValue'
build/temp.linux-i686-2.4/numpy/linalg/lapack_litemodule.o: In function `lapack_lite_zgeev':
lapack_litemodule.c:(.text+0x133d): undefined reference to `PyArg_ParseTuple'
lapack_litemodule.c:(.text+0x156b): undefined reference to `Py_BuildValue'
build/temp.linux-i686-2.4/numpy/linalg/lapack_litemodule.o: In function `lapack_lite_zgelsd':
lapack_litemodule.c:(.text+0x162a): undefined reference to `PyArg_ParseTuple'
lapack_litemodule.c:(.text+0x1869): undefined reference to `Py_BuildValue'
build/temp.linux-i686-2.4/numpy/linalg/lapack_litemodule.o: In function `lapack_lite_zgesv':
lapack_litemodule.c:(.text+0x18e8): undefined reference to `PyArg_ParseTuple'
lapack_litemodule.c:(.text+0x1a36): undefined reference to `Py_BuildValue'
build/temp.linux-i686-2.4/numpy/linalg/lapack_litemodule.o: In function `lapack_lite_zgesdd':
lapack_litemodule.c:(.text+0x1aef): undefined reference to `PyArg_ParseTuple'
lapack_litemodule.c:(.text+0x1d5a): undefined reference to `Py_BuildValue'
build/temp.linux-i686-2.4/numpy/linalg/lapack_litemodule.o: In function `lapack_lite_zgetrf':
lapack_litemodule.c:(.text+0x1dc5): undefined reference to `PyArg_ParseTuple'
lapack_litemodule.c:(.text+0x1ec6): undefined reference to `Py_BuildValue'
build/temp.linux-i686-2.4/numpy/linalg/lapack_litemodule.o: In function `lapack_lite_zpotrf':
lapack_litemodule.c:(.text+0x1f24): undefined reference to `PyArg_ParseTuple'
lapack_litemodule.c:(.text+0x1fd5): undefined reference to `Py_BuildValue'
build/temp.linux-i686-2.4/numpy/linalg/lapack_litemodule.o: In function `initlapack_lite':
lapack_litemodule.c:(.text+0x202d): undefined reference to `Py_InitModule4'
lapack_litemodule.c:(.text+0x203e): undefined reference to `PyImport_ImportModule'
lapack_litemodule.c:(.text+0x2056): undefined reference to `PyObject_GetAttrString'
lapack_litemodule.c:(.text+0x2066): undefined reference to `PyCObject_Type'
lapack_litemodule.c:(.text+0x20c9): undefined reference to `PyExc_RuntimeError'
lapack_litemodule.c:(.text+0x20d3): undefined reference to `PyErr_Format'
lapack_litemodule.c:(.text+0x2114): undefined reference to `PyCObject_AsVoidPtr'lapack_litemodule.c:(.text+0x212a): undefined reference to `PyModule_GetDict'
lapack_litemodule.c:(.text+0x214a): undefined reference to `PyErr_NewException'
lapack_litemodule.c:(.text+0x2166): undefined reference to `PyDict_SetItemString'
/usr/lib/gcc/i686-pc-linux-gnu/3.4.5/libfrtbegin.a(frtbegin.o): In function `main':
: undefined reference to `MAIN__'
collect2: ld returned 1 exit status
error: Command "/usr/bin/g77 -Wl,-O1 build/temp.linux-i686-2.4/numpy/linalg/lapack_litemodule.o -L/usr/lib -llapack -llapack -lblas -lcblas -latlas -lg2c -o build/lib.linux-i686-2.4/numpy/linalg/lapack_lite.so" failed with exit status 1

!!! ERROR: dev-python/numpy-0.9.8 failed.
Call stack:
  ebuild.sh, line 1531:   Called dyn_compile
  ebuild.sh, line 931:   Called src_compile
  ebuild.sh, line 1240:   Called distutils_src_compile
  distutils.eclass, line 38:   Called die
####

Looks like the Python library is not in the library list for the linker!

(FYI, I have never had gcc-4 on my system.)
Comment 3 Hypnos 2006-06-07 16:06:34 UTC
If I manually add "-lpython2.4" to the LDFLAGS, I recover something like the original error:

####
: undefined reference to `MAIN__'
collect2: ld returned 1 exit status
error: Command "/usr/bin/g77 -lpython2.4 build/temp.linux-i686-2.4/numpy/linalg/lapack_litemodule.o -L/usr/lib -llapack -llapack -lblas -lcblas -latlas -lg2c -o build/lib.linux-i686-2.4/numpy/linalg/lapack_lite.so" failed with exit status 1
####
Comment 4 Hypnos 2006-06-07 20:38:24 UTC
How embarrassing -- the problem ostensibly was my link optimization LDFLAGS="-Wl,-O1" in /etc/make.conf (left over from a prior experiment), which g77 does not like.  I rebuilt all the scipy deps, and now all of them including numpy-0.9.6 build fine.

I am closing the bug, with apologies.