Solved

How to get GCC on Debian

Posted on 2013-10-26
3
517 Views
Last Modified: 2013-10-26
I did:
sudo apt-get install build-essential

Then I did:
whereis gcc make

The output was: /usr/lib/gcc

I then did
cd /usr/lib/gcc

..and tried:
gcc -lX11 prog.c -o prog ./prog.c

And the output was;
Bash: gcc command not found

Please help. I just want to get to the point that I can compile c code (for X).

Thanks,
Amy
0
Comment
Question by:AmyL
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 3

Accepted Solution

by:
netmaster1355 earned 500 total points
ID: 39602934
i think your installation is not complete. if it succeed, you should have have /usr/bin/gcc and other directories as well (in whereis result).

verify installation with gcc -v on command line. it should show you version. if you got "gcc command not found", you should try to install it again and check logs during installation to find problem.
0
 
LVL 13

Expert Comment

by:Daniel Helgenberger
ID: 39603088
Please make sure build-essential is installed:
sudo apt-get install build-essential

Open in new window

0
 

Author Closing Comment

by:AmyL
ID: 39603299
You were correct. It appears as though Debian 5 is officially "dead", and my installation was attempting to contact an ftp server no longer in use. I upgraded Debian and it works fine now.
0

Featured Post

Tutorials alone can't teach real engineering

So we built better training tools.

-Hands-on Labs
-Instructor Mentoring
-Scenario-Based Tests
-Dedicated Cloud Servers

All at your fingertips. What are you waiting for?

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Linux users are sometimes dumbfounded by the severe lack of documentation on a topic. Sometimes, the documentation is copious, but other times, you end up with some obscure "it varies depending on your distribution" over and over when searching for …
I. Introduction There's an interesting discussion going on now in an Experts Exchange Group — Attachments with no extension (http://www.experts-exchange.com/discussions/210281/Attachments-with-no-extension.html). This reminded me of questions tha…
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
Connecting to an Amazon Linux EC2 Instance from Windows Using PuTTY.

729 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question