<?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>182904</bug_id>
          
          <creation_ts>2007-06-22 16:28 0000</creation_ts>
          <short_desc>sci-mathematics/octave-2.1.73 compile broken with MPICH2 because mpiCC does not exist</short_desc>
          <delta_ts>2007-12-25 01:52:20 0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>Gentoo Linux</product>
          <component>Applications</component>
          <version>unspecified</version>
          <rep_platform>AMD64</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>adshea@gmail.com</reporter>
          <assigned_to>sci-mathematics@gentoo.org</assigned_to>
          <cc>david.e.pi.3.14@gmail.com</cc>

      

      
          <long_desc isprivate="0">
            <who>adshea@gmail.com</who>
            <bug_when>2007-06-22 16:28:01 0000</bug_when>
            <thetext>When compiling octave, it attempts to use mpiCC as a C++ compiler.  The mpich2 ebuild doesn&apos;t create this file, instead it has mpicxx.

Reproducible: Always

Steps to Reproduce:
1. emerge mpich2
2. emerge octave with USE=&quot;mpi&quot;
3. See the error

Actual Results:  
mpiCC -c  -fPIC -I. -I../.. -I../../liboctave -I../../src -I../../libcruft/misc  -DHAVE_CONFIG_H   -O2 -pipe -march=athlon64 f77-extern.cc -o pic/f77-extern.o
make[3]: mpiCC: Command not found
make[3]: *** [pic/f77-extern.o] Error 127
make[3]: *** Waiting for unfinished jobs....
make[3]: Leaving directory `/var/tmp/portage/sci-mathematics/octave-2.1.73/work/octave-2.1.73/libcruft/misc&apos;
make[2]: *** [misc] Error 2
make[2]: Leaving directory `/var/tmp/portage/sci-mathematics/octave-2.1.73/work/octave-2.1.73/libcruft&apos;
make[1]: *** [libcruft] Error 2
make[1]: Leaving directory `/var/tmp/portage/sci-mathematics/octave-2.1.73/work/octave-2.1.73&apos;
make: *** [all] Error 2

!!! ERROR: sci-mathematics/octave-2.1.73 failed.
Call stack:
  ebuild.sh, line 1615:   Called dyn_compile
  ebuild.sh, line 972:   Called qa_call &apos;src_compile&apos;
  ebuild.sh, line 44:   Called src_compile
  octave-2.1.73.ebuild, line 77:   Called die


Expected Results:  
Octave should have used detected and used mpicxx instead of mpiCC.  Or mpich2 should have made a link to mpiCC in it&apos;s install.

Portage 2.1.2.7 (default-linux/amd64/2007.0, gcc-4.1.2, glibc-2.5-r3, 2.6.20-gentoo-r8 x86_64)
=================================================================
System uname: 2.6.20-gentoo-r8 x86_64 AMD Processor model unknown
Gentoo Base System release 1.12.9
Timestamp of tree: Thu, 21 Jun 2007 16:30:01 +0000
dev-lang/python:     2.4.4-r4
dev-python/pycrypto: 2.0.1-r5
sys-apps/sandbox:    1.2.17
sys-devel/autoconf:  2.13, 2.61
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
sys-devel/binutils:  2.16.1-r3
sys-devel/gcc-config: 1.3.16
sys-devel/libtool:   1.5.22
virtual/os-headers:  2.6.17-r2
ACCEPT_KEYWORDS=&quot;amd64&quot;
AUTOCLEAN=&quot;yes&quot;
CBUILD=&quot;x86_64-pc-linux-gnu&quot;
CFLAGS=&quot;-O2 -pipe -march=athlon64&quot;
CHOST=&quot;x86_64-pc-linux-gnu&quot;
CONFIG_PROTECT=&quot;/etc /usr/share/X11/xkb&quot;
CONFIG_PROTECT_MASK=&quot;/etc/env.d /etc/gconf /etc/revdep-rebuild /etc/terminfo /etc/texmf/web2c&quot;
CXXFLAGS=&quot;-O2 -pipe -march=athlon64&quot;
DISTDIR=&quot;/usr/portage/distfiles&quot;
FEATURES=&quot;collision-protect distlocks metadata-transfer sandbox sfperms strict&quot;
GENTOO_MIRRORS=&quot;http://gentoo.mirrors.pair.com/ http://gentoo.chem.wisc.edu/gentoo/ http://www.gtlib.gatech.edu/pub/gentoo http://gentoo.cites.uiuc.edu/pub/gentoo/ http://distro.ibiblio.org/pub/linux/distributions/gentoo/&quot;
MAKEOPTS=&quot;-j3&quot;
PKGDIR=&quot;/usr/portage/packages&quot;
PORTAGE_RSYNC_OPTS=&quot;--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --delete-after --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages --filter=H_**/files/digest-*&quot;
PORTAGE_TMPDIR=&quot;/var/tmp&quot;
PORTDIR=&quot;/usr/portage&quot;
PORTDIR_OVERLAY=&quot;/usr/portage/local/layman/sunrise /usr/portage/local/layman/science /usr/local/portage&quot;
SYNC=&quot;rsync://rsync.gentoo.org/gentoo-portage&quot;
USE=&quot;X aac aalib acl acpi alsa amd64 avahi bash-completion berkdb bitmap-fonts bzip2 cdr cli cracklib crypt cscope cups curl dbus dri dts dvd dvdr dvi flac fortran gdbm gif glitz gnutls gpm gtk hal iconv imap ipv6 isdnlog jpeg libg++ midi mmx mng mp3 mpeg mpi mudflap ncurses nptl nptlonly nsplugin numeric nvidia offensive ogg opengl openmp pam pcmcia pcre pdf perl png ppds pppd python readline reflection session spl sse sse2 ssl startup-notification svg tcl tcltk tcpd tetex theora tiff tk truetype truetype-fonts type1-fonts unicode vim-syntax vorbis wmf xinerama xorg xvid zeroconf zlib&quot; ALSA_CARDS=&quot;hda-intel&quot; ALSA_PCM_PLUGINS=&quot;adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mulaw multi null plug rate route share shm softvol&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; USERLAND=&quot;GNU&quot; VIDEO_CARDS=&quot;nvidia vesa&quot;
Unset:  CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LANG, LC_ALL, LDFLAGS, LINGUAS, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS

This can be fixed by making a simlink from /usr/bin/mpicxx to /usr/bin/mpiCC

However, both mpich2 and octave are stable versions

sys-cluster/mpich2-1.0.3 USE=&quot;crypt cxx -debug -doc mpe -threads&quot;

sci-mathematics/octave-2.1.73 USE=&quot;blas hdf5 mpi readline zlib -debug -doc -emacs -static&quot;</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>markusle@gentoo.org</who>
            <bug_when>2007-06-23 12:00:48 0000</bug_when>
            <thetext>Hi Adam,

Thanks for the note and you are correct! It is probably even worse
than that because other mpi implementations in virtual/mpi might
use yet another name for their C/C++ wrapper. 
The upcoming octave-2.9.12 has dropped mpi support so the &quot;mpi&quot;
useflag will be phased out soon. I&apos;ll see if I can cover mpich/mpich2/lammpi
without too much effort.

Thanks,
Markus</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>david.e.pi.3.14@gmail.com</who>
            <bug_when>2007-08-29 19:07:47 0000</bug_when>
            <thetext>Created an attachment (id=129573)
A possible correction of the ebuild

I just set CXX=mpicxx instead of mpiCC for the mpich2 case.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>david.e.pi.3.14@gmail.com</who>
            <bug_when>2007-09-28 15:49:03 0000</bug_when>
            <thetext>Created an attachment (id=132096)
This will make octave buildi with mpich2.

Almost the same patch as above, but in an unified format (I think that the previous is almost unusable sorry).</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>nerdboy@gentoo.org</who>
            <bug_when>2007-12-24 19:41:51 0000</bug_when>
            <thetext>Since hdf5 already checks for the mpich2 c++ interface because of compatibility issues, it sounds like octave should do the same if USE=mpi is enabled.  That should take care of this issue, and personally I&apos;d rather see the mpi support stay, even if its only C and Fortran.  Unless upstream is dropping it completely...</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>nerdboy@gentoo.org</who>
            <bug_when>2007-12-25 01:52:20 0000</bug_when>
            <thetext>As stated in bug #202304, the real issue is the header changes induced by the MPI C++ include stuff, so even if you point to the correct mpi wrapper script, it ultimately fails with the error in the above bug.  Since upstream doesn&apos;t seem too interested in dealing with it, I went ahead and &quot;fixed&quot; the octave 1.73 ebuilds so they at least build correctly as long as mpich2 is *not* built with the cxx USE flag.</thetext>
          </long_desc>
      
          <attachment
              isobsolete="1"
              ispatch="1"
              isprivate="0"
          >
            <attachid>129573</attachid>
            <date>2007-08-29 19:07 0000</date>
            <desc>A possible correction of the ebuild</desc>
            <filename>patch.txt</filename>
            <type>text/plain</type>
            <data encoding="base64">NTcsNThkNTYKPCAJCUNDPSJtcGljYyIgJiYgQ1hYPSJtcGlDQyIKPCAJCUNDPSJtcGljYyIgJiYg
Q1hYPSJtcGlDQyIKNTlhNTgKPiAJCQlDQz0ibXBpY2MiICYmIENYWD0ibXBpQ0MiCjYwYTYwLDYx
Cj4gCQllbGlmIGhhc192ZXJzaW9uICdzeXMtY2x1c3Rlci9tcGljaDInOyB0aGVuCj4gCQkJQ0M9
Im1waWNjIiAmJiBDWFg9Im1waWN4eCIKNjFhNjMKPiAJCQlDQz0ibXBpY2MiICYmIENYWD0ibXBp
Q0MiCg==
</data>        

          </attachment>
          <attachment
              isobsolete="0"
              ispatch="1"
              isprivate="0"
          >
            <attachid>132096</attachid>
            <date>2007-09-28 15:49 0000</date>
            <desc>This will make octave build with mpich2.</desc>
            <filename>patch.txt</filename>
            <type>text/plain</type>
            <data encoding="base64">LS0tIC91c3IvcG9ydGFnZS9zY2ktbWF0aGVtYXRpY3Mvb2N0YXZlL29jdGF2ZS0yLjEuNzMuZWJ1
aWxkCTIwMDctMDctMTMgMDc6MzY6MDQuMDAwMDAwMDAwICswMjAwCisrKyAvdXNyL2xvY2FsL3Bv
cnRhZ2Uvc2NpLW1hdGhlbWF0aWNzL29jdGF2ZS9vY3RhdmUtMi4xLjczLmVidWlsZAkyMDA3LTA5
LTI4IDE3OjMyOjM0LjAwMDAwMDAwMCArMDIwMApAQCAtNTQsMTAgKzU0LDE0IEBACiAJIyBvY3Rh
dmUgbGlua3MgYWdhaW5zIC1sbXBpIGJ5IGRlZmF1bHQKIAkjIG1waWNoIG5lZWRzIC1sbXBpY2gg
aW5zdGVhZAogCWlmIHVzZSBtcGk7IHRoZW4KLQkJQ0M9Im1waWNjIiAmJiBDWFg9Im1waUNDIgog
CQlpZiBoYXNfdmVyc2lvbiAnc3lzLWNsdXN0ZXIvbXBpY2gnOyB0aGVuCisJCQlDQz0ibXBpY2Mi
ICYmIENYWD0ibXBpQ0MiCisJCQlteWNvbmY9IiR7bXljb25mfSAtLXdpdGgtbXBpPW1waWNoIgor
CQllbGlmIGhhc192ZXJzaW9uICdzeXMtY2x1c3Rlci9tcGljaDInOyB0aGVuCisJCQlDQz0ibXBp
Y2MiICYmIENYWD0ibXBpY3h4IgogCQkJbXljb25mPSIke215Y29uZn0gLS13aXRoLW1waT1tcGlj
aCIKIAkJZWxzZQorCQkJQ0M9Im1waWNjIiAmJiBDWFg9Im1waUNDIgogCQkJbXljb25mPSIke215
Y29uZn0gLS13aXRoLW1waT1tcGkiCiAJCWZpCiAJZWxzZQo=
</data>        

          </attachment>
    </bug>

</bugzilla>