"Can't run C compiled programs" on clean RH9 install
Hi
I'm trying to install a package called libmad-0.15.0b from source the installation instructions after extracting it from ...tar.gz are: 1. `cd' to the directory containing the package's source code and type `./configure' to configure the package for your system. If you're using `csh' on an old version of System V, you might need to type `sh ./configure' instead to prevent `csh' from trying to execute `configure' itself. Running `configure' takes awhile. While running, it prints some messages telling which features it is checking for. 2. Type `make' to compile the package. 3. Optionally, type `make check' to run any self-tests that come with the package. 4. Type `make install' to install the programs and any data files and documentation. I'm currently running a completely clean RH9 install on an athlon 2.4.20-8 kernel with all development packages installed (afaik). I have no problems compiling simple C code (such as #include <stdio.h> .... main() { printf("etc etc"); } ) with my gcc, so im assuming theres no problem with it. However when i try running $ sh ./configure in the libmad dir, i get the following text: [root@localhost libmad-0.15.0b]# sh ./configure checking for a BSD-compatible install... /usr/bin/install -c checking whether build environment is sane... yes checking for gawk... gawk checking whether make sets $(MAKE)... yes checking build system type... i686-pc-linux-gnu checking host system type... i686-pc-linux-gnu checking for gcc... gcc checking for C compiler default output... a.out checking whether the C compiler works... configure: error: cannot run C compiled programs. If you meant to cross compile, use `--host'. See `config.log' for more details. The coconfigure:2251: $? = 0 configure:2253: gcc -v </dev/null >&5 Reading specs from /usr/lib/gcc-lib/i386-redhat-linux/3.2.2/specs Configured with: ../configure --prefix=/usr --mandir=/usr/share/man --infodir=/usr/share/info --enable-shared --enable-threads=posix --disable-checking --with-system-zlib --enable-__cxa_atexit --host=i386-redhat-linux Thread model: posix gcc version 3.2.2 20030222 (Red Hat Linux 3.2.2-5) configure:2256: $? = 0 configure:2258: gcc -V </dev/null >&5 gcc: argument to `-V' is missing configure:2261: $? = 1 configure:2285: checking for C compiler default output configure:2288: gcc conftest.c >&5 configure:2291: $? = 0 configure:2337: result: a.out configure:2342: checking whether the C compiler works configure:2348: ./a.out ./configure: line 1: ./a.out: Permission denied configure:2351: $? = 126 configure:2360: error: cannot run C compiled programs. If you meant to cross compile, use `--host'. See `config.log' for more details.nfig.log file generated reads: Help? the same happens for the package id3lib-3.8.3 (these are both dependencies i need to install k3b burner), which has identical format as far as source install goes |
Probably haven't installed gcc or haven't got it on your path.
Enter gcc --version To check if I'm right. Enter echo $PATH to see path |
[rob@localhost rob]$ gcc --version
gcc (GCC) 3.2.2 20030222 (Red Hat Linux 3.2.2-5) Copyright (C) 2002 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. [rob@localhost rob]$ echo $PATH /usr/local/j2sdk1.4.0_01/bin:/usr/local/j2sdk1.4.0_01/bin:/usr/local/bin:/usr/bin:/bin:/usr/X11R6/bin:/home/rob/bin Looks like its installed. what is $PATH telling you? I have compiled simple C programs with gcc. |
Quote:
|
ok
does anyone know? |
Sorry, missed that permission denied bit.
Strange. The only other odd things I can see is you running configure as root. That shouldn't be a problem, but generally the sequence is configure, make, su, make install, exit so you are root for less time. ie. Only do what you _have to_ as root, otherwise operate as a normal user. Check that the directory it's working in is writable. cd .. ls -ld libmad-0.15.0b |
got it working by moving the directory to $HOME. Before that it was in a fat32 drive (Could that have made the difference?)
before i moved it, ls - ld libmad-0.15.0b gave [rob@localhost k3b_burner]$ ls -ld libmad-0.15.0b drwxrwxr-x 3 rob rob 16384 Mar 16 17:16 libmad-0.15.0b |
Redhat puts three versions of automake (1.4, 1.5, and 1.6) in RH9. Delete all of them but 1.6 and it'll work perfect.
|
Ah! Fat32, it was the mounted drive. There is a mount option (exec) that says allow binaries to execute on this machine or not. (If you mount a windows box on a Linux machine, you don't want to try execute any .exe's.) If that fat32 partition had been mounted with exec instead of noexec option, it would have worked. (Well, at least you may have had a different problem)
Say "man mount' for more detail. Cat /etc/mtab to see what options are currently used. |
All times are GMT -5. The time now is 05:31 PM. |