<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "http://bugs.gentoo.org/bugzilla.dtd">

<bugzilla version="2.22.7"
          urlbase="http://bugs.gentoo.org/"
          maintainer="bugzilla@gentoo.org"
>

    <bug>
          <bug_id>217914</bug_id>
          
          <creation_ts>2008-04-16 08:27 0000</creation_ts>
          <short_desc>scipy-0.6.0-r4: compilation failed: undefined reference to `MAIN__&apos;</short_desc>
          <delta_ts>2008-04-17 00:45:38 0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>Bugzilla</product>
          <component>General Bugs</component>
          <version>unspecified</version>
          <rep_platform>x86</rep_platform>
          <op_sys>Linux</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          
          <priority>P2</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          
          <everconfirmed>1</everconfirmed>
          <reporter>alexander.filov@gmail.com</reporter>
          <assigned_to>sci@gentoo.org</assigned_to>
          

      

      
          <long_desc isprivate="0">
            <who>alexander.filov@gmail.com</who>
            <bug_when>2008-04-16 08:27:32 0000</bug_when>
            <thetext>sci-libs/scipy-0.6.0-r4 failed

Reproducible: Always

Steps to Reproduce:
1.emerge scipy
2.
3.

Actual Results:  
build/temp.linux-i686-2.5 -ldfftpack -ldrfftw -ldfftw -lpython2.5 -lgfortran -o build/lib.linux-i686-2.5/scipy/fftpack/_fftpack.so
/usr/lib/gcc/i686-pc-linux-gnu/4.2.3/libgfortranbegin.a(fmain.o): In function `main&apos;:
(.text+0x23): undefined reference to `MAIN__&apos;
collect2: выполнение ld завершилось с кодом возврата 1
/usr/lib/gcc/i686-pc-linux-gnu/4.2.3/libgfortranbegin.a(fmain.o): In function `main&apos;:
(.text+0x23): undefined reference to `MAIN__&apos;
collect2: выполнение ld завершилось с кодом возврата 1
error: Command &quot;/usr/bin/gfortran -Wall build/temp.linux-i686-2.5/build/src.linux-i686-2.5/scipy/fftpack/_fftpackmodule.o build/temp.linux-i686-2.5/scipy/fftpack/src/zfft.o build/temp.linux-i686-2.5/scipy/fftpack/src/drfft.o build/temp.linux-i686-2.5/scipy/fftpack/src/zrfft.o build/temp.linux-i686-2.5/scipy/fftpack/src/zfftnd.o build/temp.linux-i686-2.5/build/src.linux-i686-2.5/fortranobject.o -L/usr/lib -L/usr/lib -Lbuild/temp.linux-i686-2.5 -ldfftpack -ldrfftw -ldfftw -lpython2.5 -lgfortran -o build/lib.linux-i686-2.5/scipy/fftpack/_fftpack.so&quot; failed with exit status 1
 * 
 * ERROR: sci-libs/scipy-0.6.0-r4 failed.



uname -a

Linux localhost 2.6.23-gentoo-r4 #1 Wed Dec 19 14:53:22 MSK 2007 i686 AMD Athlon(tm) 64 Processor 3200+ AuthenticAMD GNU/Linux

gcc 4.2.3 (Gentoo 4.2.3 p1.0)

cat /etc/make.conf

CFLAGS=&quot;-O2 -march=i686 -pipe&quot;
CHOST=&quot;i686-pc-linux-gnu&quot;
CXXFLAGS=&quot;${CFLAGS}&quot;
USE=&quot;doc -ipv6  fftw sandbox   qt3 X alsa qt3support nptl bitmap-fonts truetype-fonts type1-fonts  aac a52 encode mmx mp2 mp3 sse sse2 win32codecs xvi&quot;
MAKEOPTS=&quot;-j8&quot;
INPUT_DEVICES=&quot;keyboard mouse&quot;
VIDEO_CARDS=&quot;vesa nv nvidia ati radeon r128 fglrx&quot;
FEATURES=&quot;-distlocks -sandbox&quot;
PORTDIR_OVERLAY=&quot;/usr/local/portage&quot;
LINGUAS=&quot;ru&quot;
ACCEPT_KEYWORDS=&quot;~x86&quot;

emerge -pv scipy

[ebuild  N    ] sci-libs/scipy-0.6.0-r4  USE=&quot;fftw sandbox -debug -umfpack&quot; 0 kB</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>bicatali@gentoo.org</who>
            <bug_when>2008-04-16 14:21:34 0000</bug_when>
            <thetext>Hi Alex,

First, could you try with MAKEOPTS=-j1? If it stills fails, in order to try to
reproduce, I would need: 
1) emerge --info, and could you also provide:

2) result of:
eselect blas show
eselect cblas show
eselect lapack show

3) which fortran compiler are you using.

Thanks.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>markusle@gentoo.org</who>
            <bug_when>2008-04-16 15:12:46 0000</bug_when>
            <thetext>Sébastien,

I can reproduce it here on my opteron with -j1 both
with atlas and reference. This looks like a linking problem 
between some C and Fortran routine. Interestingly, -r2 seems 
to compile so it may well be another one of these issues we had
when dealing with the clapack patch.

Markus</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>alexander.filov@gmail.com</who>
            <bug_when>2008-04-16 15:31:37 0000</bug_when>
            <thetext>Sébastien,

1. scipy-0.6.0-r3 has the same problem
2. scipy-0.6.0-r2 compiling OK
3. with MAKEOPTS=-j1  failed
4. emerge --info

Portage 2.1.5_rc3 (default-linux/x86/2006.1, gcc-4.2.3, glibc-2.7-r2, 2.6.23-gentoo-r4 i686)
=================================================================
System uname: 2.6.23-gentoo-r4 i686 unknown
Timestamp of tree: Tue, 15 Apr 2008 19:30:01 +0000
app-shells/bash:     3.2_p33
dev-java/java-config: 1.3.7, 2.1.4
dev-lang/python:     2.4.4-r9, 2.5.1-r5
dev-python/pycrypto: 2.0.1-r6
sys-apps/baselayout: 1.12.11.1
sys-apps/sandbox:    1.2.18.1-r2
sys-devel/autoconf:  2.13, 2.62
sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2, 1.10.1
sys-devel/binutils:  2.18-r1
sys-devel/gcc-config: 1.4.0-r4
sys-devel/libtool:   1.5.26
virtual/os-headers:  2.6.24
ACCEPT_KEYWORDS=&quot;x86 ~x86&quot;
CBUILD=&quot;i686-pc-linux-gnu&quot;
CFLAGS=&quot;-O2 -march=i686 -pipe&quot;
CHOST=&quot;i686-pc-linux-gnu&quot;
CONFIG_PROTECT=&quot;/etc /usr/kde/3.5/env /usr/kde/3.5/share/config /usr/kde/3.5/shutdown /usr/share/config /var/bind&quot;
CONFIG_PROTECT_MASK=&quot;/etc/env.d /etc/env.d/java/ /etc/fonts/fonts.conf /etc/gconf /etc/php/apache2-php5/ext-active/ /etc/php/cgi-php5
/ext-active/ /etc/php/cli-php5/ext-active/ /etc/terminfo /etc/texmf/web2c /etc/udev/rules.d&quot;
CXXFLAGS=&quot;-O2 -march=i686 -pipe&quot;
DISTDIR=&quot;/usr/portage/distfiles&quot;
FEATURES=&quot;metadata-transfer parallel-fetch sfperms strict unmerge-orphans userfetch&quot;
GENTOO_MIRRORS=&quot;http://distfiles.gentoo.org http://distro.ibiblio.org/pub/linux/distributions/gentoo&quot;
LANG=&quot;ru_RU.UTF-8&quot;
LDFLAGS=&quot;&quot;
LINGUAS=&quot;ru&quot;
MAKEOPTS=&quot;-j1&quot;
PKGDIR=&quot;/usr/portage/packages&quot;
PORTAGE_RSYNC_OPTS=&quot;--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --timeout=180 -
-exclude=/distfiles --exclude=/local --exclude=/packages&quot;
PORTAGE_TMPDIR=&quot;/var/tmp&quot;
PORTDIR=&quot;/usr/portage&quot;
PORTDIR_OVERLAY=&quot;/usr/local/portage&quot;
SYNC=&quot;rsync://rsync.gentoo.org/gentoo-portage&quot;
USE=&quot;X a52 aac alsa berkdb bitmap-fonts cli cracklib crypt cups doc dri encode fftw fortran gdbm gpm iconv isdnlog midi mmx mp2 mp3 m
udflap ncurses nls nptl nptlonly openmp pam pcre perl ppds pppd python qt3 qt3support readline reflection sandbox session spl sse sse
2 ssl tcpd truetype-fonts type1-fonts unicode win32codecs x86 xorg xvi zlib&quot; ALSA_CARDS=&quot;ali5451 als4000 atiixp atiixp-modem bt87x ca
0106 cmipci emu10k1     emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m       maestro3 trident usb-audio vi
a82xx via82xx-modem ymfpci&quot; ALSA_PCM_PLUGINS=&quot;adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa l
float linear meter mulaw multi null plug rate route share shm softvol&quot; APACHE2_MODULES=&quot;actions alias auth_basic authn_alias authn_an
on authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache dav d
av_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime m
ime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias&quot; ELIBC=&quot;glibc&quot; INPUT_DEVICES=&quot;keyboard 
mouse&quot; KERNEL=&quot;linux&quot; LCD_DEVICES=&quot;bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text&quot; LINGUAS=&quot;ru&quot; USERLAND=&quot;GNU&quot;
 VIDEO_CARDS=&quot;vesa nv nvidia ati radeon r128 fglrx&quot;
Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LC_ALL, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_O
PTS


5. eselect blas show
lib: reference

6. eselect cblas show
lib: gsl

7. eselect lapack show
lib: reference

8. /usr/bin/gfortran --version
GNU Fortran (GCC) 4.2.3 (Gentoo 4.2.3 p1.0)</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>bicatali@gentoo.org</who>
            <bug_when>2008-04-17 00:45:38 0000</bug_when>
            <thetext>Should be fixed in cvs. Re-open if you still have the same issues.

[I still don&apos;t understand what changed between version and I suspect a portage update changing behaviour of some global scope settings]

Thanks.
</thetext>
          </long_desc>
      
    </bug>

</bugzilla>