PATH problem
I'm following directions for compiling and making a printer driver from source files (never did THAT in Windows!), and all goes well until I issue the './configure' command. When I do, the first few lines appear OK, then this shows up:
checking for gcc... no checking for cc... no checking for cc... no checking for cl... no configure: error: no acceptable C compiler found in $PATH Now, I know gcc is on the system, 'cause I found it using locate, but now what? Do I need to edit my PATH to include the gcc folder in it, or what? The folder all the to-be-compiled files are in the folder /HOME/JEFF/HPIJS-1.4 , so how do I get the compiler and these bad boys together? TIA! |
Wheres gcc? Usually its /bin or /usr/bin
Type $PATH at the command prompt to list what paths the configure script is searching. I get /bin:/usr/bin:/usr/X11R6/bin:/usr/local/bin You can add Directories to the PATH with the command export PATH=$PATH:/your/new/path But it sounds as if your gcc has been installed to the wrong place. |
if you want you can set a symbolic link to gcc. just link th edirectory where it is to the directory you need it in. if you decide to do that let me know and i will try to help you. like in mandrake sometimes the rpms look for a path unique to mandrake. i set links to the programs location on my redhat system and things seemed fine.
|
OK, logged in as root (su), and cd to the folder with the files I want to compile. Did 'locate' to find gcc, which is in the /usr/bin folder. Checked the path to verify that /usr/bin is in fact in it. Ran ./configure again, and got the same message. Does this make sense? gcc296 is there in /usr/bin, so shouldn't 'configure' find it and use it however it needs to? Suffering major newbie confusion here.....
BTW, using RH9. Nice to work with an OS that presents some challenges :cool: |
Me too, do you have a symlink from gcc to the current version of gcc.
type: Code:
ls -l /usr/bin/gcc* Code:
lrwxrwxrwx 1 root root 7 Aug 18 07:21 gcc -> gcc-3.3 |
Here's what I get when I type that in:
[jeff@localhost jeff]$ ls -l /usr/bin/gcc* -rwxr-xr-x 2 root root 81864 Feb 11 2003 /usr/bin/gcc296 And, this means what? And, what in God's name is a 'symlink'? |
We've found your problem :)
Symlink is a way of linking a filename or directory name to another. There is diffrent versions of gcc, as you can see I've got a few installed as it is, So programs just call gcc. the symlink then points the computer towards the correct version. becauase you don't have that symlink we'll have to create it. su to root and type: Code:
cd /usr/bin Everthing should work now. |
Sorry, not quite (I think). What I get back is:
ln: `gcc296': File exists Which squares with what I get when I locate gcc*. gcc296 is sitting in /usr/bin Is it that this version of the compiler can't handle the job, or what? Among other things that show up in gcc* locate is this: /usr/lib/gcc-lib/i386-redhat-linux/3.2.2 Is this a reference to a newer version of gcc on the system, and if so, how to find it? |
Sorry I got the command options the wrong way round. (I'm always doing that!)
ln -s gcc296 gcc Should of been the command. --- I think thats the glibc lib, Although it usually match's the version of gcc. Once you've done the above try gcc -v |
Well, partial success. The configure worked, but the make didn't. I'm doubting whether this all will work. I may just have to live without the HP printer on RH. Thanks to leonscape for getting me as far as he did!
|
Which printer?
I've got a HP Deskjet 3822 all set up and working correctly so I could try and help you through it. |
leonscape, if you want to give it a shot, here's the URL with all the HP OpenSource driver info:
http://hpinkjet.sourceforge.net/install.php Let me know if you have any more success than I did. |
1) remove LPRng:
rpm -e LPRng redhat-config-printer redhat-config-printer-gui 2) install cups, cups-drivers, cups-drivers-hpijs, gimp-print-cups up2date -i cups cups-drivers cups-drivers-hpijs gimp-print-cups 3) start cups: /sbin/service cups start /sbin/chkconfig cups on 4) point your web browser to http://localhost:631 Click on "Printers" and then "Add Printer", login with the root password and follow the configuration menus. This is rather than compiling hpijs your self. |
Sorry to bust in, but I'm having the same *@!# problem.
I'm running SuSE 8.1 and did not have gcc installed correctly as far as I can tell. I downloaded version gcc-3.3.1 and ran the tar gcc-3.3.1.tar.gz command in my /usr/bin directory to unpack it all. My problem is, when I run: ls -l /user/bin/gcc* I get a laundry list of files, not just files starting with gcc. I can't seem to nail down where the compiler executable is located for linking for running the Samba config command. Any ideas? |
Try which gcc
|
Well, I'll fess up to the fact that I'm an idiot at this.
I can't find an executable. I ran "tar xvfz gcc-3.3.1.tar.gz" and it dumped all of the files into the /usr/bin/gcc-3.3.1/ directory, which includes a /gcc-3.3.1/gcc directory, but no gcc executable as far as I can tell. I've added PATHS to both directories in the blind hope that I'm missing something, and when I run ./configure I still get checking for gcc... no checking for cc... no configure: error: no acceptable cc found in $PATH This may not be something you can tell, but am I missing some key files? There's a ton of files in the /usr/bin/gcc-3.3.1. and /usr/bin/gcc-3.3.1/gcc, but no gcc executable as far as I can tell. |
The best thing to do would be to install a version of gcc from binary rpms first. Also chek around a package may already exist. gcc can boot strap it self to compile, but your into diffcult territory, its not something I'd look forward too.
|
Ahhh, shit. So basically you're saying I need a compiler to set up the compiler.
Yeah, doesn't sound like fun. Maybe the best thing to do is get my SuSe disks back and run it off the CD. Thanks for the input. |
|
All times are GMT -5. The time now is 03:19 AM. |