With gcc 4.1, I can't build octave-forge 2006.03.17. Apparently the patch mentioned here is appled upstream: http://sourceforge.net/mailarchive/forum.php?thread_id=10090390&forum_id=4874 (I haven't tried the patch yet) The errors I'm seeing are the same as the ones mention in the URL above, things like: mkoctfile -Doctave_idx_type=int -DHAVE_OCTAVE_21 -v -c make_sparse.cc -ISuperLU/SRC/ -ISuperLU/CBLAS -DNDEBUG -DHAVE_ND_ARRAYS -DTYPEID_HAS_CLASS -DCLASS_HAS_LOAD_SAVE -DHAVE_OCTAVE_CONCAT -DHAVE_OCTAVE_UPLUS -o make_sparse.o i686-pc-linux-gnu-g++ -c -fPIC -I/usr/include/octave-2.1.72 -I/usr/include/octave-2.1.72/octave -mieee-fp -march=i686 -O3 -pipe -fomit-frame-pointer -ISuperLU/SRC/ -ISuperLU/CBLAS -Doctave_idx_type=int -DHAVE_OCTAVE_21 -DNDEBUG -DHAVE_ND_ARRAYS -DTYPEID_HAS_CLASS -DCLASS_HAS_LOAD_SAVE -DHAVE_OCTAVE_CONCAT -DHAVE_OCTAVE_UPLUS make_sparse.cc -o make_sparse.o i686-pc-linux-gnu-g++ -shared -Wl,-Bsymbolic -o finitedifference.oct finitedifference.o -L/usr/lib/octave-2.1.72 -loctinterp -loctave -lcruft -lz -llapack -lblas -lfftw3 -lreadline -lncurses -ldl -lm -L/usr/lib/gcc/i686-pc-linux-gnu/4.1.0 -L/usr/lib/gcc/i686-pc-linux-gnu/4.1.0/../../../../i686-pc-linux-gnu/lib -L/usr/lib/gcc/i686-pc-linux-gnu/4.1.0/../../.. -lz -lgfortranbegin -lgfortran -lm -lgcc_s mkoctfile -Doctave_idx_type=int -DHAVE_OCTAVE_21 -v newtonstep.cc i686-pc-linux-gnu-g++ -c -fPIC -I/usr/include/octave-2.1.72 -I/usr/include/octave-2.1.72/octave -mieee-fp -march=i686 -O3 -pipe -fomit-frame-pointer -Doctave_idx_type=int -DHAVE_OCTAVE_21 newtonstep.cc -o newtonstep.o /usr/include/octave-2.1.72/octave/ArrayN.h: In constructor 'ArrayN<T>::ArrayN(const dim_vector&, const T&) [with T = bool]': /usr/include/octave-2.1.72/octave/boolNDArray.h:49: instantiated from here /usr/include/octave-2.1.72/octave/ArrayN.h:66: error: no matching function for call to 'fill(const bool&)' /usr/lib/gcc/i686-pc-linux-gnu/4.1.0/include/g++-v4/bits/stl_algobase.h:573: note: candidates are: void std::fill(unsigned char*, unsigned char*, const unsigned char&) /usr/lib/gcc/i686-pc-linux-gnu/4.1.0/include/g++-v4/bits/stl_algobase.h:581: note: void std::fill(signed char*, signed char*, const signed char&) /usr/lib/gcc/i686-pc-linux-gnu/4.1.0/include/g++-v4/bits/stl_algobase.h:589: note: void std::fill(char*, char*, const char&) /usr/include/octave-2.1.72/octave/ArrayN.h: In constructor 'ArrayN<T>::ArrayN(const dim_vector&, const T&) [with T = long long int]': /usr/include/octave-2.1.72/octave/so-array.h:48: instantiated from here /usr/include/octave-2.1.72/octave/ArrayN.h:66: error: no matching function for call to 'fill(const long long int&)' /usr/lib/gcc/i686-pc-linux-gnu/4.1.0/include/g++-v4/bits/stl_algobase.h:573: note: candidates are: void std::fill(unsigned char*, unsigned char*, const unsigned char&) /usr/lib/gcc/i686-pc-linux-gnu/4.1.0/include/g++-v4/bits/stl_algobase.h:581: note: void std::fill(signed char*, signed char*, const signed char&) /usr/lib/gcc/i686-pc-linux-gnu/4.1.0/include/g++-v4/bits/stl_algobase.h:589: note: void std::fill(char*, char*, const char&) /usr/include/octave-2.1.72/octave/DiagArray2.h: In constructor 'DiagArray2<T>::DiagArray2(int, int, const T&) [with T = double]': /usr/include/octave-2.1.72/octave/MDiagArray2.h:57: instantiated from 'MDiagArray2<T>::MDiagArray2(int, int, const T&) [with T = double]' /usr/include/octave-2.1.72/octave/dDiagMatrix.h:50: instantiated from here /usr/include/octave-2.1.72/octave/DiagArray2.h:128: error: no matching function for call to 'fill(const double&)' /usr/lib/gcc/i686-pc-linux-gnu/4.1.0/include/g++-v4/bits/stl_algobase.h:573: note: candidates are: void std::fill(unsigned char*, unsigned char*, const unsigned char&) /usr/lib/gcc/i686-pc-linux-gnu/4.1.0/include/g++-v4/bits/stl_algobase.h:581: note: void std::fill(signed char*, signed char*, const signed char&) /usr/lib/gcc/i686-pc-linux-gnu/4.1.0/include/g++-v4/bits/stl_algobase.h:589: note: void std::fill(char*, char*, const char&) /usr/include/octave-2.1.72/octave/DiagArray2.h: In constructor 'DiagArray2<T>::DiagArray2(int, int, const T&) [with T = std::complex<double>]': /usr/include/octave-2.1.72/octave/MDiagArray2.h:57: instantiated from 'MDiagArray2<T>::MDiagArray2(int, int, const T&) [with T = std::complex<double>]' /usr/include/octave-2.1.72/octave/CDiagMatrix.h:50: instantiated from here /usr/include/octave-2.1.72/octave/DiagArray2.h:128: error: no matching function for call to 'fill(const std::complex<double>&)' /usr/lib/gcc/i686-pc-linux-gnu/4.1.0/include/g++-v4/bits/stl_algobase.h:573: note: candidates are: void std::fill(unsigned char*, unsigned char*, const unsigned char&) /usr/lib/gcc/i686-pc-linux-gnu/4.1.0/include/g++-v4/bits/stl_algobase.h:581: note: void std::fill(signed char*, signed char*, const signed char&) /usr/lib/gcc/i686-pc-linux-gnu/4.1.0/include/g++-v4/bits/stl_algobase.h:589: note: void std::fill(char*, char*, const char&) /usr/include/octave-2.1.72/octave/ArrayN.h: In constructor 'ArrayN<T>::ArrayN(const dim_vector&, const T&) [with T = char]': /usr/include/octave-2.1.72/octave/MArrayN.h:58: instantiated from 'MArrayN<T>::MArrayN(const dim_vector&, const T&) [with T = char]' /usr/include/octave-2.1.72/octave/chNDArray.h:46: instantiated from here /usr/include/octave-2.1.72/octave/ArrayN.h:66: error: no matching function for call to 'fill(const char&)' /usr/lib/gcc/i686-pc-linux-gnu/4.1.0/include/g++-v4/bits/stl_algobase.h:573: note: candidates are: void std::fill(unsigned char*, unsigned char*, const unsigned char&) /usr/lib/gcc/i686-pc-linux-gnu/4.1.0/include/g++-v4/bits/stl_algobase.h:581: note: void std::fill(signed char*, signed char*, const signed char&) /usr/lib/gcc/i686-pc-linux-gnu/4.1.0/include/g++-v4/bits/stl_algobase.h:589: note: void std::fill(char*, char*, const char&) /usr/include/octave-2.1.72/octave/ArrayN.h: In constructor 'ArrayN<T>::ArrayN(const dim_vector&, const T&) [with T = double]': /usr/include/octave-2.1.72/octave/MArrayN.h:58: instantiated from 'MArrayN<T>::MArrayN(const dim_vector&, const T&) [with T = double]' /usr/include/octave-2.1.72/octave/dNDArray.h:48: instantiated from here /usr/include/octave-2.1.72/octave/ArrayN.h:66: error: no matching function for call to 'fill(const double&)' /usr/lib/gcc/i686-pc-linux-gnu/4.1.0/include/g++-v4/bits/stl_algobase.h:573: note: candidates are: void std::fill(unsigned char*, unsigned char*, const unsigned char&) /usr/lib/gcc/i686-pc-linux-gnu/4.1.0/include/g++-v4/bits/stl_algobase.h:581: note: void std::fill(signed char*, signed char*, const signed char&) /usr/lib/gcc/i686-pc-linux-gnu/4.1.0/include/g++-v4/bits/stl_algobase.h:589: note: void std::fill(char*, char*, const char&) /usr/include/octave-2.1.72/octave/ArrayN.h: In constructor 'ArrayN<T>::ArrayN(const dim_vector&, const T&) [with T = std::complex<double>]': /usr/include/octave-2.1.72/octave/MArrayN.h:58: instantiated from 'MArrayN<T>::MArrayN(const dim_vector&, const T&) [with T = std::complex<double>]' /usr/include/octave-2.1.72/octave/CNDArray.h:47: instantiated from here /usr/include/octave-2.1.72/octave/ArrayN.h:66: error: no matching function for call to 'fill(const std::complex<double>&)' /usr/lib/gcc/i686-pc-linux-gnu/4.1.0/include/g++-v4/bits/stl_algobase.h:573: note: candidates are: void std::fill(unsigned char*, unsigned char*, const unsigned char&) /usr/lib/gcc/i686-pc-linux-gnu/4.1.0/include/g++-v4/bits/stl_algobase.h:581: note: void std::fill(signed char*, signed char*, const signed char&) /usr/lib/gcc/i686-pc-linux-gnu/4.1.0/include/g++-v4/bits/stl_algobase.h:589: note: void std::fill(char*, char*, const char&) distcc[12765] ERROR: compile make_sparse.cc on localhost failed make[2]: *** [make_sparse.o] Error 1
Created attachment 86780 [details, diff] octave-2.1.72-gcc4.1-templates-octave-forge.patch I tested the patch mentioned above. It fixes the problem for me. *NOTE*: patch is to be applied to *octave* not octave-forge. After rebuilding octave with this patch, the in-tree octave-forge builds correctly.
I have the same problem. But how should I use your patch? Should I skate over portage and compile octave by my own? I'm not used to the details of portage, so I don't know how to modify the octave ebuild to use your patch. :(
Created attachment 88786 [details] octave-2.1.72.ebuild Devs: please ignore this attachment, it has nothing but a epatch line added to it. I'm just attaching it for the benefit of Comment #2, for others, sorry for the bug noise. Re: Comment #2: Bug reports are not the right place for tech support but here goes: No you don't need to compile octave yourself. You will need to learn a little bit about "overlays" (there must be some good docs on overlays, use google). Basically you need to create the following directory: /usr/local/portage/sci-mathematics/octave Then put the octave-2.1.72.ebuild that I just attached in there. Then create /usr/local/portage/sci-mathematics/octave/files and put the octave-2.1.72-gcc4.1-templates-octave-forge.patch in there. Now cd to /usr/local/portage/sci-mathematics/octave and run "ebuild octave-2.1.72.ebuild digest" Finally, add or modify the following line in your /etc/make.conf: PORTDIR_OVERLAY="/usr/local/portage" Then you can "emerge -vp octave", from which you should see: [ebuild R ] sci-mathematics/octave-2.1.72 USE="blas emacs readline zlib -debug -doc -hdf5 -mpi -static" 0 kB [1] Total size of downloads: 0 kB Portage overlays: [1] /usr/local/portage Note the [1] telling you that it is using the overlay. If it works, let us know. If all this sounds too complicated then just wait for a friendly dev to add this patch to the tree!
Hi Colin, Thank you very much for your report and the patch. I just bumped octave to version 2.1.73 including the patch and octave-forge now compiles fine. Best, Markus
Hi, first thanks to comment #3 for your explanation! octave-forge now also compiles for me with octave-2.1.73 installed, but emerge octave-forge wants to downgrade octave to 2.1.72. I used --nodeps and it worked. Synced an hour ago.