Results 1 to 5 of 5

Thread: Need older version of gcc

  1. #1
    Join Date
    Mar 2009
    Beans
    9

    Need older version of gcc

    Hi,

    This is my first posting to Ubuntu Forums... apologies if I guessed the wrong forum to post to...

    The Ubuntu I've installed has gcc version 4.3.2. I need to install an earlier version (gcc 3.4) somewhere without replacing the 4.3.2 version that's there, so that I can create programs that run on other systems with older Linuxes. I'd have to run the older version specially---that's OK; I don't want the older version to be the default. I'm assuming something would have to be done to keep glibc libraries separate also.

    Is there a fairly easy way to get this done from the repositories, or do I just need to go to the Gnu site and build this all by hand?

    Thanks.

  2. #2
    Join Date
    Sep 2006
    Location
    France.
    Beans
    Hidden!
    Distro
    Ubuntu Mate 16.04 Xenial Xerus

    Re: Need older version of gcc

    Moved to Installation & Upgrades.

    From the repos, no, as the gcc version number is tied to the release you are using.
    I have done it already, long ago, and do not remember how (I used a CC option before compiling).

    I found this old link and think this is the way I did it:
    http://www.linuxforums.org/forum/ins...c-3-3-3-a.html
    | My old and mostly abandoned blog |
    Linux user #413984 ; Ubuntu user #178
    J'aime les fraises.
    Nighty night me lovelies!

    | Reinstalling Ubuntu ? Please check this bug first ! |
    | Using a ppa ? Please install ppa-purge from universe, you may need it should you want to revert packages back |
    | No support requests / username changes by PM, thanks. |
    [SIGPIC][/SIGPIC]

  3. #3
    Join Date
    Jun 2007
    Beans
    17,337

    Re: Need older version of gcc

    You can install lower versions from synaptic, in most cases with no issue.

    The few times I need 3.4 I go
    CC=gcc-3.4 ./configure ...ect.,ect.

  4. #4
    Join Date
    Sep 2006
    Location
    France.
    Beans
    Hidden!
    Distro
    Ubuntu Mate 16.04 Xenial Xerus

    Re: Need older version of gcc

    Quote Originally Posted by mc4man View Post
    You can install lower versions from synaptic, in most cases with no issue.

    The few times I need 3.4 I go
    CC=gcc-3.4 ./configure ...ect.,ect.
    I just looked, yes, and this is probably the way I did in my very first moments with Linux (had to compile that driver for my usb modem back then..). I'm running Hardy and installed gcc is 4.2.4. gcc 3.3 and 3.4 are available from synaptic.

    Sorry for the misleading info. I quickly checked with aptitude, and it only showed the version I have installed.
    | My old and mostly abandoned blog |
    Linux user #413984 ; Ubuntu user #178
    J'aime les fraises.
    Nighty night me lovelies!

    | Reinstalling Ubuntu ? Please check this bug first ! |
    | Using a ppa ? Please install ppa-purge from universe, you may need it should you want to revert packages back |
    | No support requests / username changes by PM, thanks. |
    [SIGPIC][/SIGPIC]

  5. #5
    Join Date
    Mar 2009
    Beans
    9

    Re: Need older version of gcc

    Thanks---that worked great! I guess I could have just tried this myself, but I didn't really know what it might screw up, so it was very helpful to hear from a more experienced user that there shouldn't be any issues. Thanks again, mc4man & bapoumba.

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •