LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Putting cc Compiler into $PATH (https://www.linuxquestions.org/questions/linux-newbie-8/putting-cc-compiler-into-%24path-841539/)

Davethesnake 10-31-2010 10:53 AM

Putting cc Compiler into $PATH
 
Im running Xandros,default system on a eeepc 701,seems a few versions of gcc are on it including the base gcc-3.3.I need to put cc compiler into $PATH,i can get into mc to change file but what exactly do i change?Currently is says:(bashrc.profile)

set path so it includes users private bin if it exists
if [-d ~/bin ] ;then
PATH=~/bin:"${PATH}"
fi

------------What do i change and to what?-------------------

arizonagroovejet 10-31-2010 11:09 AM

Where is cc located?

Though if you know the answer to that you should know what you need to add to $PATH...

If you don't know the answer, then are you sure cc is actually installed?

In my experience cc is always in the same directory as gcc.

Davethesnake 10-31-2010 11:17 AM

look im a bit baffeled:
if i do "whereis gcc"-------------i get /usr/lib/gcc
if i do apt-cache search gcc----i get:
libgcc 1---GCC support lib
gcc-4.1 base
gcc-3.4 base
cpp
gcc-3.3 base
gcj-4.1 base
cpp-4.1 base
libgcj 7-0
dpkg-dev

so now what?

Tinkster 10-31-2010 12:07 PM

Correct me if I'm wrong ...

"apt-cache search" searches ALL packages, not just installed ones?

What whereis found is just libs.

Try "apt-get install buildessential" (or is it buildessentials? I don't
use debian and friends)

arizonagroovejet 10-31-2010 12:49 PM

Oh hang on, it's that Asus customised Xandros install that they put on the EeePC isn't it. The one about which people tend to complain when they assume it's the sort of install you get if you had installed Xandros/openSuSE/Fedora or whatever from a DVD buy then find they can't do what they want to do because the Linux build that the EeePC ships with is designed on the assumption that you use what's on there, not that you will want to start compiling your own software on it. You might well not even have a build-essentials package available to install.

I forget to say before that in my experience not only is cc in the same directory as gcc but it's in the same package. So if gcc is installed so is cc. Also they're both in /usr/bin which is in $PATH by default. That may not be the case with Xandros though. Do you actually have gcc installed? What does
Code:

$ which gcc
say? If it doesn't say anything then you probably don't have gcc installed.


If I were you I'd put 'eeepc forum' in to Google and look for info on how to do what you're trying to do. That or replace the Linux install entirely with Aurora/Eeebuntu.

Davethesnake 10-31-2010 01:39 PM

yeah i guess i dont want wireless driver uncompatability with any of the other ubuntu derivitives,xandros does auto configure wireless connectivity also.
using sudo synaptic package manager says gcc3.3.base is installed but whenever i try to unpack ,it does untar ok but just wont ./configure anything coming back put cc compiler into $PATH.
bashrc.profile is the right file to change?is it?For to do this correctly?

arizonagroovejet 10-31-2010 05:08 PM

Quote:

Originally Posted by Davethesnake (Post 4145140)
using sudo synaptic package manager says gcc3.3.base is installed but whenever i try to unpack ,it does untar ok but just wont ./configure

Erm... What are you unpacking and why are you trying to use ./configure on it?

Packages install pre-compiled binaries. That's sort of the point of them. E.g. you install the MozillaFirefox package and you have Firefox installed and ready to use, there's nothing to configure and build.


Perhaps it would help if you post the commands you are running and the output of them.


Quote:

Originally Posted by Davethesnake (Post 4145140)
anything coming back put cc compiler into $PATH.
bashrc.profile is the right file to change?is it?For to do this correctly?

Yes, that's the place to set a value for $PATH.


All times are GMT -5. The time now is 01:07 PM.