how to compile with g++44

Hi,

I am using PGI 12.10 on CentOS 5.8 .

There is two version of GCC 4.1.2 and 4.4.7 . The default is 4.1.2.

I am looking for compiling with g++44( secondary GCC 4.4.7) .

Are there any suggestions to switch the secondary GCC (excluding to upgrade OS, to uninstall GCC 4.1.2, or to reinstall PGI) ?

Thanks in advance.

$ cat /etc/redhat-release
CentOS release 5.8 (Final)

$ g++ --version
g++ (GCC) 4.1.2 20080704 (Red Hat 4.1.2-54)
Copyright (C) 2006 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

$ g++44 --version
g++44 (GCC) 4.4.7 20120313 (Red Hat 4.4.7-1)
Copyright (C) 2010 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

Hi mhasumi,

The quick method is to edit your installation’s “localrc” file to point to the new GCC installation. The caveat is that for compatibility reasons, we provide some system header files which can change depending upon the GCC version. Also, older PGI versions may not be compatable with newer GCC installations.

Hence, the preferred method is to re-install after you have switched to using GCC 4.4.7 by default. We don’t have a method to switch between GCC installation on a single host.

  • Mat

Thank you, Mat.

I will negotiate it to our administrator with your information.