GiNaC build error (non-local fct uses anonymous type)
Hello GiNaC! I downloaded GiNaC-0.8.3.tar.bz2, but I'm having trouble building it on my system. My computer has SuSE 7.1 with gcc version 2.96 20000731. Here's the build error: make[2]: Entering directory `/home/gg/down2/math/GiNaC-0.8.3/ginac' /bin/sh ../libtool --mode=compile c++ -DHAVE_CONFIG_H -I. -I. -I.. -I/usr/local/include -g -O2 -c inifcns.cpp rm -f .libs/inifcns.lo c++ -DHAVE_CONFIG_H -I. -I. -I.. -I/usr/local/include -g -O2 -c inifcns.cpp -fPIC -DPIC -o .libs/inifcns.lo In file included from inifcns.cpp:31: matrix.h:125: non-local function `GiNaC::ex GiNaC::determinant (const GiNaC::matrix &, unsigned int = GiNaC::determinant_algo::automatic)' uses anonymous type make[2]: *** [inifcns.lo] Error 1 make[2]: Leaving directory `/home/gg/down2/math/GiNaC-0.8.3/ginac' make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory `/home/gg/down2/math/GiNaC-0.8.3' make: *** [all-recursive-am] Error 2 Thanks for any help, /george moudry los angeles PS. I saw on the ginac.de website that some people were installing an RPM. Would you know where to download it from? PPS. The GiNaC screenshot is incredible! I really did think it crashed my browser. - To UNSUBSCRIBE, email to ginac-list@ginac.de with a subject of "unsubscribe".
Hi, On Tue, 15 May 2001, george moudry wrote:
My computer has SuSE 7.1 with gcc version 2.96 20000731.
Here's the build error:
make[2]: Entering directory `/home/gg/down2/math/GiNaC-0.8.3/ginac' /bin/sh ../libtool --mode=compile c++ -DHAVE_CONFIG_H -I. -I. -I.. -I/usr/local/include -g -O2 -c inifcns.cpp rm -f .libs/inifcns.lo c++ -DHAVE_CONFIG_H -I. -I. -I.. -I/usr/local/include -g -O2 -c inifcns.cpp -fPIC -DPIC -o .libs/inifcns.lo In file included from inifcns.cpp:31: matrix.h:125: non-local function `GiNaC::ex GiNaC::determinant (const GiNaC::matrix &, unsigned int = GiNaC::determinant_algo::automatic)' uses anonymous type make[2]: *** [inifcns.lo] Error 1 make[2]: Leaving directory `/home/gg/down2/math/GiNaC-0.8.3/ginac' make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory `/home/gg/down2/math/GiNaC-0.8.3' make: *** [all-recursive-am] Error 2
Known bug in GCC. Upgrade your compiler. BTW, did that compiler ship with SuSE? I don't believe they are so dumb after the fiasco happened to RedHat: <http://gcc.gnu.org/gcc-2.96.html>. Alternatively you may try to remove the default argument in the declaration of GiNaC::determinant() that causes the trouble. But I don't know what is going to hit you next...
PS. I saw on the ginac.de website that some people were installing an RPM. Would you know where to download it from?
<ftp://ftpthep.physik.uni-mainz.de/pub/GiNaC/rpm/>
PPS. The GiNaC screenshot is incredible! I really did think it crashed my browser. :-)
Regards -richy. -- Richard Kreckel <Richard.Kreckel@Uni-Mainz.DE> <http://wwwthep.physik.uni-mainz.de/~kreckel/> - To UNSUBSCRIBE, email to ginac-list@ginac.de with a subject of "unsubscribe".
Thanks for your help. I installed the "2.96" version because I am using the java front end (gcj). SuSE 7.1 personal did not come with gcj, so I grabbed this strange version from rpmfind.net. Today, I grabbed a new gcc version from http://www.codesourcery.com/gcc-snapshots, but the GiNaC build still fails - in a different place. Instead of the build, would you know where I can find the RPM? thanks, george PS. in case someone is interested in results of compilation with gcc pre-3.0, here is gcc version and ginac build error: ################################################### gcc -v Reading specs from /usr/local/bin/../lib/gcc-lib/i386-pc-linux-gnu/3.0/specs Configured with: ../configure --prefix=/tmp/gcc-20010514-root/usr/local --enable-shared --enable-threads --disable-checking i386-pc-linux-gnu : (reconfigured) Thread model: posix gcc version 3.0 20010514 (prerelease) ################################################### make[2]: Entering directory `/home/gg/down2/math/GiNaC-0.8.3/ginac' /bin/sh ../libtool --mode=compile c++ -DHAVE_CONFIG_H -I. -I. -I.. -I/usr/local/include -g -O2 -c numeric.cpp rm -f .libs/numeric.lo c++ -DHAVE_CONFIG_H -I. -I. -I.. -I/usr/local/include -g -O2 -c numeric.cpp -fPIC -DPIC -o .libs/numeric.lo /usr/local/include/g++-v3/bits/stl_construct.h: In function `void std::_Construct(_T1*, const _T2&) [with _T1 = cln::cl_RA, _T2 = cln::cl_RA]': numeric.cpp:100: instantiated from here /usr/local/include/g++-v3/bits/stl_construct.h:48: no matching function for call to `cln::cl_RA::operator new(unsigned int, void*&)' /usr/local/include/cln/rational_class.h:35: candidates are: static void* cln::cl_RA::operator new(unsigned int) /usr/local/include/cln/rational_class.h:36: static void* cln::cl_RA::operator new(unsigned int, cln::cl_RA*) make[2]: *** [numeric.lo] Error 1 make[2]: Leaving directory `/home/gg/down2/math/GiNaC-0.8.3/ginac' On Monday 14 May 2001 11:59, you wrote:
Known bug in GCC. Upgrade your compiler. BTW, did that compiler ship with SuSE? I don't believe they are so dumb after the fiasco happened to RedHat: <http://gcc.gnu.org/gcc-2.96.html>. Alternatively you may try to remove the default argument in the declaration of GiNaC::determinant() that causes the trouble. But I don't know what is going to hit you next...
PS. I saw on the ginac.de website that some people were installing an RPM. Would you know where to download it from?
<ftp://ftpthep.physik.uni-mainz.de/pub/GiNaC/rpm/>
PPS. The GiNaC screenshot is incredible! I really did think it crashed my browser.
:-)
Regards -richy.
- To UNSUBSCRIBE, email to ginac-list@ginac.de with a subject of "unsubscribe".
Hi George, On Tue, 15 May 2001, george moudry wrote:
I installed the "2.96" version because I am using the java front end (gcj). SuSE 7.1 personal did not come with gcj, so I grabbed this strange version from rpmfind.net.
Today, I grabbed a new gcc version from http://www.codesourcery.com/gcc-snapshots, but the GiNaC build still fails - in a different place.
More below...
Instead of the build, would you know where I can find the RPM?
Er, what? The URL I sent you has 3 GiNaC RPMs, one for source, one for binary and one for devel. They were, however, built on RedHat. Your mileage may vary of course.
thanks, george
PS. in case someone is interested in results of compilation with gcc pre-3.0, here is gcc version and ginac build error:
################################################### gcc -v Reading specs from /usr/local/bin/../lib/gcc-lib/i386-pc-linux-gnu/3.0/specs Configured with: ../configure --prefix=/tmp/gcc-20010514-root/usr/local --enable-shared --enable-threads --disable-checking i386-pc-linux-gnu : (reconfigured) Thread model: posix gcc version 3.0 20010514 (prerelease)
################################################### make[2]: Entering directory `/home/gg/down2/math/GiNaC-0.8.3/ginac' /bin/sh ../libtool --mode=compile c++ -DHAVE_CONFIG_H -I. -I. -I.. -I/usr/local/include -g -O2 -c numeric.cpp rm -f .libs/numeric.lo c++ -DHAVE_CONFIG_H -I. -I. -I.. -I/usr/local/include -g -O2 -c numeric.cpp -fPIC -DPIC -o .libs/numeric.lo /usr/local/include/g++-v3/bits/stl_construct.h: In function `void std::_Construct(_T1*, const _T2&) [with _T1 = cln::cl_RA, _T2 = cln::cl_RA]': numeric.cpp:100: instantiated from here /usr/local/include/g++-v3/bits/stl_construct.h:48: no matching function for call to `cln::cl_RA::operator new(unsigned int, void*&)' /usr/local/include/cln/rational_class.h:35: candidates are: static void* cln::cl_RA::operator new(unsigned int) /usr/local/include/cln/rational_class.h:36: static void* cln::cl_RA::operator new(unsigned int, cln::cl_RA*) make[2]: *** [numeric.lo] Error 1 make[2]: Leaving directory `/home/gg/down2/math/GiNaC-0.8.3/ginac'
Ah, this is a particularly annoying "feature" of C++! Since libstdc++-v3 we need that member operator new(uint, void*) now in all of CLN's classes in order to instantiate STL containers with them. Which means that unfortunately we have some less compile-time checking for type-safety. This is one of the dark sides of C++: In lesson one you learn that you can overload on function arguments. In lesson two you learn that you can derive classes from other classes, inheriting their public/protected members. And then you learn that overloaded functions are not at all inherited once you specify one other such function with a different signature in the derived class. Every programmer is bitten by this at least once in his/her life. I was even hit twice: had to realize first that the problem is the same for overloaded operator member functions... :-( You need to check out the current CLN from CVS. It fixes this problem. Apart from that it nothing significant has changed in CLN 1.1.1. It's just meant to be a bugfix release for the new GCC. But I am waiting with the release till GCC 3.0 has really hit the streets so I can be 100% certain that it works. Here is how to access CLN's CVS repository: $ cvs -d :pserver:anoncvs@cvsthep.physik.uni-mainz.de:/home/cvs login enter the password `anoncvs' $ cvs -d :pserver:anoncvs@cvsthep.physik.uni-mainz.de:/home/cvs -z 9 co cln Regards -richy. -- Richard Kreckel <Richard.Kreckel@Uni-Mainz.DE> <http://wwwthep.physik.uni-mainz.de/~kreckel/> - To UNSUBSCRIBE, email to ginac-list@ginac.de with a subject of "unsubscribe".
participants (2)
-
george moudry
-
Richard B. Kreckel