LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 10-22-2007, 06:04 PM   #1
ElectroLinux
Member
 
Registered: Feb 2004
Posts: 74

Rep: Reputation: 15
Changing compiler version for a make


Right now /usr/bin/gcc is old. How can I force a make to use a specific verion of gcc. Assuming I have several different versions installed in /usr/bin?

For example:

/usr/bin/gcc
/usr/bin/gcc-2.2.2
/usr/bin/gcc-2.1.3


I need to use gcc-2.2.2...can i specify that in make command or..?
 
Old 10-23-2007, 07:13 AM   #2
Nick_Battle
Member
 
Registered: Dec 2006
Location: Bracknell, UK
Distribution: SUSE 13.1
Posts: 159

Rep: Reputation: 33
If you set the CC variable to the pathname of the compiler, I believe it will do what you ant. Either set CC in your Makefile, or "make CC=/usr/bin/gcc-2.2.2 [target]".

HTH,
-nick
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
New LILO version automatically make windows partitions hidden changing it with cfdisk TroelsSmit Linux - General 5 02-21-2004 01:50 AM
problem with compiler version?? miha Linux - General 4 01-03-2004 12:08 PM
compiler version albean Linux - Newbie 1 11-22-2002 03:33 PM
Compiler version max2878 Linux - Software 0 03-01-2002 09:58 AM
compiler version max2878 Linux - General 0 02-27-2002 04:33 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 11:21 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration