PDA

View Full Version : how to compile with gcc 2.95



mu664life
04-13-2004, 04:54 AM
hi all, i just installed knoppix 3.3
i'm very new at this so please forgive me for asking stupid questions...

one of my projects need to use the gcc 2.95 version, now when i look in the kpackage, it said that version 2.95 is already installed, but when i check it with gcc -v, it said it's version 3.3.3

so is 2.95 really already installed?
if so, how can i use it?

i'm new at this so please show me some examples

thank you

bxitknop
04-19-2004, 06:28 PM
Your question has no doubt been answered I hope but perhaps not posted. I will post an answer because the question will help me towards finding my problem( why gcc version 3.3 compiles my simplle program but bash will not execute it stating that it can't find ELF 'executable library format' so I am stuck.)
Here's what you do to find different versions of 'gcc'
In the shell(bash by default) give the command:
cd /
#goto root directory
find / -name *gcc*
#find all files containing 'gcc'

#in filename

#or
find / -name *gcc* | more
#if the list is too long

#in my version of knoppix Jan/Feb 04

#there are some in /usr/bin
cd /usr/bin
#goto the /usr/bin directory
ls *gcc*
#will list the 'gcc' files
*************************************************

results in green(executables)
gcc-2.95
gcc-3.3
colorgcc
gccbug3.3

results in cyan(???)
various links to the above

************************************************** ****

mazaal
04-20-2004, 12:27 PM
so is 2.95 really already installed?
if so, how can i use it?

just type the command "gcc-2.95" instead of "gcc"
if you are using a makefile you can easily define the compiler as gcc-2.95