You are not logged in.
Pages: 1
I need to compile some MEX stuff with Matlab but it requires gcc 4.1 or 4.2 but arch is running 4.5.
Is it possible to have two versions of gcc installed? If so, is there a guide for doing it without breaking my system...
Offline
Go to aur.archlinux.org, search for "gcc4", pick whichever you want, follow the instructions on how to install from aur, set CC/CXX as needed, done.
Evil #archlinux@libera.chat channel op and general support dude.
. files on github, Screenshots, Random pics and the rest
Online
set CC/CXX as needed, done.
Can you elaborate on this part?
Thanks.
Offline
in the PKGBUILD export CC / CXX to whatever version of gcc that you want to use. Eg:
.
.
export CC=/usr/bin/x86_64-unknown-linux-gnu-gcc-4.2.4
./configure prefix=/usr
make
.
.
.
Evil #archlinux@libera.chat channel op and general support dude.
. files on github, Screenshots, Random pics and the rest
Online
While compiling gcc 4.1 I get this error:
configure: error: C++ preprocessor "/lib/cpp" fails sanity check
See `config.log' for more details.
make[1]: *** [configure-target-libstdc++-v3] Error 1
contents of src/gcc-4.1.2/build/x86_64-unknown-linux-gnu/libstdc++-v3/config.log (last lines)
#ifdef __cplusplus
extern "C" void exit (int) throw ();
configure: exit 1
Last edited by dabd (2010-06-09 22:05:47)
Offline
I assume you are using gcc41 from the AUR. You probably only need "CC=gcc-4.1 CXX=g++-4.1 ./configure..."
Offline
Search the forums, in an old thread I indicate how to replace Matlab's built-in GCC with the system one. The only utility affected is mex, Matlab itself is not tied to your gcc, so I recommend you do that instead of installing old gcc.
Allan-Volunteer on the (topic being discussed) mailn lists. You never get the people who matters attention on the forums.
jasonwryan-Installing Arch is a measure of your literacy. Maintaining Arch is a measure of your diligence. Contributing to Arch is a measure of your competence.
Griemak-Bleeding edge, not bleeding flat. Edge denotes falls will occur from time to time. Bring your own parachute.
Offline
I managed to install gcc41 from AUR and change MATLAB's mexopts.sh to point to it and now everything works fine.
Hopefully gcc41 and the gcc-4.5 can coexist without problems. Should I watch out for any conflicts?
Offline
Pages: 1