Author Topic: suse 10.1 gcc problem  (Read 5096 times)

Offline TeddyKrulewich

  • Multiple posting newcomer
  • *
  • Posts: 32
suse 10.1 gcc problem
« on: July 26, 2006, 02:36:57 am »
How do i get an older version of gcc for suse? I tried downloading an older version and installing it but that didnt woark and yast wont let me remove the current gcc.

Offline mdelfede

  • Multiple posting newcomer
  • *
  • Posts: 84
Re: suse 10.1 gcc problem
« Reply #1 on: July 26, 2006, 11:58:05 am »
How do i get an older version of gcc for suse? I tried downloading an older version and installing it but that didnt woark and yast wont let me remove the current gcc.

Look here : http://forums.codeblocks.org/index.php?topic=3481.0
There is a post of mine with explanations and a link on how to setup more GCC versions on linux.
I've done it with SuSe 10.1, installing GCC 4.0.3 and it works perfectly.

Ciao

Max

p.s. Of course, that must be done by hand, forget Yast for this task....

Offline TeddyKrulewich

  • Multiple posting newcomer
  • *
  • Posts: 32
Re: suse 10.1 gcc problem
« Reply #2 on: July 26, 2006, 04:30:51 pm »
I was able to compile gcc but somehitng didnt work :( .  When i typed:
which gcc43     it returned nothing

when i typed gcc43 it said it didnt exist

ps is there a way to uninstall like:
make install
installs
« Last Edit: July 26, 2006, 04:34:07 pm by TeddyKrulewich »

Offline TeddyKrulewich

  • Multiple posting newcomer
  • *
  • Posts: 32
Re: suse 10.1 gcc problem
« Reply #3 on: July 26, 2006, 06:04:28 pm »
I am able to use the compiler now, bit i have to type the compielrs directory and i dont know hwo to build and rpm with my new compiler please please help

Offline mdelfede

  • Multiple posting newcomer
  • *
  • Posts: 84
Re: suse 10.1 gcc problem
« Reply #4 on: July 26, 2006, 07:44:06 pm »
I am able to use the compiler now, bit i have to type the compielrs directory and i dont know hwo to build and rpm with my new compiler please please help

From the link I posted :

--------------------------------------------------------------------------
After installing the new GCC, codeblocks can be built using it with these steps

export CC=/opt/gcc/4.0.3/gcc403
export CXX=/opt/gcc/4.0.3/g++403
./configure --enable-contrib
make
--------------------------------------------------------------------------

this of course if your new compiler is  /opt/gcc/4.0.3/gcc403
You can also add "make install" to install c::b if you want.

RPM has nothing to do with it, you're compiling from sources, not installing a RPM.

Ciao

Max

Offline TeddyKrulewich

  • Multiple posting newcomer
  • *
  • Posts: 32
Re: suse 10.1 gcc problem
« Reply #5 on: July 27, 2006, 05:07:08 am »
I was trying to make an rpm not install it but i gues i will just do what you said

Offline mdelfede

  • Multiple posting newcomer
  • *
  • Posts: 84
Re: suse 10.1 gcc problem
« Reply #6 on: July 27, 2006, 12:19:48 pm »
I was trying to make an rpm not install it but i gues i will just do what you said

Better.... compile from source, make an RPM and install it makes not much sense...  RPM are useful only to distribuite it.

Ciao

Max

Offline Game_Ender

  • Lives here!
  • ****
  • Posts: 551
Re: suse 10.1 gcc problem
« Reply #7 on: July 27, 2006, 10:25:04 pm »
By using a package you make it very easy to uninstall something later.  I use checkinstall on the time to generate packages for custom compilied programs.  Then I all I have to do to uninstall the program is check a box in the package manager.  Checkinstall runs "make install" then generates a debian package and installs it.  There might be something similar for rpms.

Offline TheTuxKeeper

  • Regular
  • ***
  • Posts: 293
  • daniel2000
Re: suse 10.1 gcc problem
« Reply #8 on: July 28, 2006, 11:41:07 am »
By using a package you make it very easy to uninstall something later.  I use checkinstall on the time to generate packages for custom compilied programs.  Then I all I have to do to uninstall the program is check a box in the package manager.  Checkinstall runs "make install" then generates a debian package and installs it.  There might be something similar for rpms.
checkinstall works same for RPMs ;)

I've uploaded a source RPM of gcc 4.0 that will be installed to /opt/gcc_40 the executables all have "_40" as suffix. It will create two packages gcc_40 and gcc_40-fortran. I didn't create the package myself, I took the gcc 4.0 package for Suse 9.3 from another packager. I didn't test whether it builds completely (no time yet, will do it today), but since nor suse 9.3 specific neither I did big changes (added some essential buildrequires and disabled gcc-gnat and gcc-java build) it should build correctly.
Here is the link: http://www.uploading.com/?get=O5PPGVII

To build the package do these steps:
1. run sudo rpmbuild --rebuild --target=$ARCH gcc_40-4.0.2-0.daniel2000.1.src.rpm (replace $ARCH by x86_64, i586 or whatever you have :))
2. the install the package /usr/src/packages/RPMS/$ARCH/gcc_40-4.0.2-0.daniel2000.1.$ARCH.rpm
Nightly builds for openSUSE

Offline TeddyKrulewich

  • Multiple posting newcomer
  • *
  • Posts: 32
Re: suse 10.1 gcc problem
« Reply #9 on: August 02, 2006, 07:20:35 pm »
thanks for all of the help and i did sucsesfully build a working rpm

Offline Death Knight

  • Multiple posting newcomer
  • *
  • Posts: 18
  • Death here
    • DivFix++
Re: suse 10.1 gcc problem
« Reply #10 on: August 08, 2006, 03:55:13 am »
Could you upload last nighlty snapshot to rapidshare.de if you using x86_64 arthitecture?
Thank you :)