LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 08-16-2006, 02:32 PM   #1
me!
Member
 
Registered: Feb 2006
Distribution: Ubuntu Feisty, BeaFanatIX
Posts: 36

Rep: Reputation: 15
Make problem with installing foremost


Hello:

I found that my usbdrive had a trash bin on it and several times tried to delete it unsuccessfully. When I did manage it deleted the entire contents of the drive!

I'm going to try and get it back using 'foremost'. However, I'm already having problems trying to install foremost.

I have uncompressed the foremost tar but when I try and install using make, I get the following error:
[root@localhost foremost-1.1]# make
gcc -Wall -O2 -DVERSION=\"1.1\" -D__UNIX -D__LINUX -DLARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -c main.c
make: gcc: Command not found
make: *** [main.o] Error 127

I ‘whereis’d gcc and it is in:
/ur/libexec/gcc

Is gcc in the wrong place? It shouldn’t be as my Linux is a fresh install off a commercially produced CD …

Any ideas

me!
 
Old 08-16-2006, 02:46 PM   #2
kaz2100
Senior Member
 
Registered: Apr 2005
Location: Penguin land, with apple, no gates
Distribution: SlackWare > Debian testing woody(32) sarge etch lenny squeeze(+64) wheezy jessie stretch buster
Posts: 1,769

Rep: Reputation: 107Reputation: 107
check your PATH!

What happens if you
Code:
gcc -v
?
 
Old 08-17-2006, 02:08 AM   #3
me!
Member
 
Registered: Feb 2006
Distribution: Ubuntu Feisty, BeaFanatIX
Posts: 36

Original Poster
Rep: Reputation: 15
It gives:
bash: gcc: command not found

What is PATH?

Thanks!

me!
 
Old 08-17-2006, 02:50 AM   #4
titopoquito
Senior Member
 
Registered: Jul 2004
Location: Lower Rhine region, Germany
Distribution: Slackware64 14.2 and current, SlackwareARM current
Posts: 1,634

Rep: Reputation: 144Reputation: 144
PATH is an environment variable that tells in which folders your system will search for executable files (commands).
You can view it with "echo $PATH". To set it do "export PATH=/path1:/path/number2" with the paths divided by colons ":". To append a path to the existing PATH do "export PATH=$PATH:/new/path".

But it seems you have to install some development packages from your distribution, at least the gcc or g++ package (don't know how it is named in FC).

Edit: Type "yum install gcc" as root to install the gcc compiler package.

Last edited by titopoquito; 08-17-2006 at 03:06 AM.
 
Old 08-18-2006, 04:16 AM   #5
me!
Member
 
Registered: Feb 2006
Distribution: Ubuntu Feisty, BeaFanatIX
Posts: 36

Original Poster
Rep: Reputation: 15
I don't know what gcc -v is supposed to do but when I whereis gcc I get:
gcc: /usr/libexec/gcc

So it is there!

I guess I need to do something with PATH but I don't knwo what. I tried PATH=$PATH:/usr/libexec but it gave no positive or negative feedback.

I did try again with Make and got a slightly different error message:

gcc -Wall -O2 -DVERSION=\"1.1\" -D__UNIX -D__LINUX -DLARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -c main.c
make: execvp: gcc: Permission denied
make: *** [main.o] Error 127

Very strange it gives 'permission denied'. I am logged in as root ...

me!
 
Old 08-18-2006, 07:11 AM   #6
titopoquito
Senior Member
 
Registered: Jul 2004
Location: Lower Rhine region, Germany
Distribution: Slackware64 14.2 and current, SlackwareARM current
Posts: 1,634

Rep: Reputation: 144Reputation: 144
How did you become root? If you typed "su" you could also try "su -" (<s><u> <space><dash>). The PATH variable will be set different depending on which one you choose, although I don't now about possible differences between FC and Slackware (for example about the SELinux configuration).
 
Old 08-18-2006, 10:45 AM   #7
kaz2100
Senior Member
 
Registered: Apr 2005
Location: Penguin land, with apple, no gates
Distribution: SlackWare > Debian testing woody(32) sarge etch lenny squeeze(+64) wheezy jessie stretch buster
Posts: 1,769

Rep: Reputation: 107Reputation: 107
I guess question you have to answer is:

"Is your gcc package installed correct?"

re-install it (package) and see what happens.

also try
Code:
file /usr/libexec/gcc
may give you some clue.
 
Old 08-25-2006, 10:08 AM   #8
me!
Member
 
Registered: Feb 2006
Distribution: Ubuntu Feisty, BeaFanatIX
Posts: 36

Original Poster
Rep: Reputation: 15
I became root by entering root as 'user' at the login screen.

What is the difference between su and su-?

me!
 
Old 08-25-2006, 10:13 AM   #9
Matir
LQ Guru
 
Registered: Nov 2004
Location: San Jose, CA
Distribution: Ubuntu
Posts: 8,507

Rep: Reputation: 128Reputation: 128
'su -' reads in the login/startup files for root (/root/.bash_profile, etc.) so that you have root's environment rather than your own. This generally avoids needing to prefix commands with /usr/sbin or /sbin and similar things.
 
Old 08-25-2006, 10:38 AM   #10
reddazz
LQ Guru
 
Registered: Nov 2003
Location: N. E. England
Distribution: Fedora, CentOS, Debian
Posts: 16,298

Rep: Reputation: 77
Like I mentioned in your other thread, it does not seem like gcc is installed. If it were, it would be in /usr/bin and not /usr/libexec.
 
  


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
Make problem with installing foremost me! Linux - Software 5 07-24-2006 06:49 AM
Recovering Data Using Foremost and Knoppix Nuvious Linux - Security 1 05-17-2006 04:36 PM
Recoveing Data Using Foremost and Knoppix Nuvious Linux - Software 1 05-17-2006 08:54 AM
LXer: Foremost for Data Recovery LXer Syndicated Linux News 0 12-23-2005 12:31 AM
installing make - problem terry.trent Linux - Newbie 3 08-07-2004 05:47 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 11:08 AM.

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