Page 1 of 1
Installing GCC and other Utils
Posted: Fri Feb 20, 2009 7:55 am
by radiatejava
I have a platform whose base is Linux but not everything is available on that. Only necessary executables are available and any individual executable can run on that. It is 32-bit and uname -a shows Linux 2.6.11.11.
Problem is I am trying to install gcc compiler on that to debug an issue. Even RPM utility is not there. Can anyone guide me how to install gcc on such a platform ?
Appreciate your response.
Re: Installing GCC and other Utils
Posted: Fri Feb 20, 2009 8:05 am
by yemista
Whats the platform?
Re: Installing GCC and other Utils
Posted: Fri Feb 20, 2009 8:21 am
by Solar
Is there some other package manager? Try rpm, apt-get, yast.
Re: Installing GCC and other Utils
Posted: Fri Feb 20, 2009 9:03 am
by AntiRush
yum? I can't imagine a linux distro that has neither a package manager or a prebuilt binary available somewhere. What platform is it?
Re: Installing GCC and other Utils
Posted: Fri Feb 20, 2009 12:33 pm
by radiatejava
This is a customised Linux - basically Cisco blades (used in switches). They normally have only executables and only those which are needed. These blades are never for any dev work.
Re: Installing GCC and other Utils
Posted: Fri Feb 20, 2009 1:14 pm
by narke
You can try to download Slackware package (gcc-4.2.4-i486-1.tgz) from here:
http://carroll.cac.psu.edu/pub/linux/di ... ackware/d/ .
Then do:
gunzip gcc-4.2.4-i486-1.tgz
tar -xvf gcc-4.2.4-i486-1.tgz
And move the binaries which will be in the untared directory to your system /usr/bin etc...
Re: Installing GCC and other Utils
Posted: Fri Feb 20, 2009 7:22 pm
by radiatejava
I can give your approach a try but not sure if that will work. Meanwhile, I have these 2 ques:
1. how does a user install first install gcc, rpm, make on a system where these are not available ?
2. I am sure there are other ways. I basically think there may be self installation files for these eg something like gcc_install.bin. Any self installer files for gcc etc on linux ?
Re: Installing GCC and other Utils
Posted: Fri Feb 20, 2009 8:51 pm
by Steve the Pirate
radiatejava wrote:I can give your approach a try but not sure if that will work. Meanwhile, I have these 2 ques:
1. how does a user install first install gcc, rpm, make on a system where these are not available ?
Two ways: If the system doesn't have these utilities at all, they would have to do it using a cross-compiler. This is a compiler that runs on one system, but makes binaries that run on another.
The other way is that someone can just make a package of them, and distribute that - this is generally how most software is distributed on Linux.
radiatejava wrote:2. I am sure there are other ways. I basically think there may be self installation files for these eg something like gcc_install.bin. Any self installer files for gcc etc on linux ?
It's possible, but very unlikely - as I said, most software is distributed as packages or source code, which would require either a package manager or a compiler, which you don't seem to have.
I think that the only way you're going to be able to do it is the way narke suggests.
Re: Installing GCC and other Utils
Posted: Mon Feb 23, 2009 5:12 am
by radiatejava
As suggested, I have built and copied gcc and binutils to my platform. But I get this error now in a gcc program:
i686-pc-linux-gnu/bin/ld: cannot open crt1.o: No such file or directory
Any package still missing ?
Re: Installing GCC and other Utils
Posted: Mon Feb 23, 2009 8:10 am
by radiatejava
This was because I did not have full version of glibc installed. I created the glibc but then I get this err for which I do not see any satisfactory response on the net:
/home/sburnwal/glibc-2.3.2-build/lib/libc.so.6: undefined reference to `_dl_lookup_versioned_symbol_skip@GLIBC_PRIVATE'
/home/sburnwal/glibc-2.3.2-build/lib/libc.so.6: undefined reference to `_dl_lookup_versioned_symbol@GLIBC_PRIVATE'
/home/sburnwal/glibc-2.3.2-build/lib/libc.so.6: undefined reference to `_dl_start_profile@GLIBC_PRIVATE'
/home/sburnwal/glibc-2.3.2-build/lib/libc.so.6: undefined reference to `_dl_check_map_versions@GLIBC_PRIVATE'
/home/sburnwal/glibc-2.3.2-build/lib/libc.so.6: undefined reference to `_dl_get_origin@GLIBC_PRIVATE'
/home/sburnwal/glibc-2.3.2-build/lib/libc.so.6: undefined reference to `_dl_dst_substitute@GLIBC_PRIVATE'
/home/sburnwal/glibc-2.3.2-build/lib/libc.so.6: undefined reference to `_dl_init@GLIBC_PRIVATE'
/home/sburnwal/glibc-2.3.2-build/lib/libc.so.6: undefined reference to `_dl_dst_count@GLIBC_PRIVATE'
/home/sburnwal/glibc-2.3.2-build/lib/libc.so.6: undefined reference to `_dl_signal_error@GLIBC_PRIVATE'
/home/sburnwal/glibc-2.3.2-build/lib/libc.so.6: undefined reference to `_dl_debug_printf@GLIBC_PRIVATE'
/home/sburnwal/glibc-2.3.2-build/lib/libc.so.6: undefined reference to `_dl_map_object_deps@GLIBC_PRIVATE'
Re: Installing GCC and other Utils
Posted: Mon Feb 23, 2009 9:10 am
by narke
radiatejava wrote:This was because I did not have full version of glibc installed. I created the glibc but then I get this err for which I do not see any satisfactory response on the net:
/home/sburnwal/glibc-2.3.2-build/lib/libc.so.6: undefined reference to `_dl_lookup_versioned_symbol_skip@GLIBC_PRIVATE'
/home/sburnwal/glibc-2.3.2-build/lib/libc.so.6: undefined reference to `_dl_lookup_versioned_symbol@GLIBC_PRIVATE'
/home/sburnwal/glibc-2.3.2-build/lib/libc.so.6: undefined reference to `_dl_start_profile@GLIBC_PRIVATE'
/home/sburnwal/glibc-2.3.2-build/lib/libc.so.6: undefined reference to `_dl_check_map_versions@GLIBC_PRIVATE'
/home/sburnwal/glibc-2.3.2-build/lib/libc.so.6: undefined reference to `_dl_get_origin@GLIBC_PRIVATE'
/home/sburnwal/glibc-2.3.2-build/lib/libc.so.6: undefined reference to `_dl_dst_substitute@GLIBC_PRIVATE'
/home/sburnwal/glibc-2.3.2-build/lib/libc.so.6: undefined reference to `_dl_init@GLIBC_PRIVATE'
/home/sburnwal/glibc-2.3.2-build/lib/libc.so.6: undefined reference to `_dl_dst_count@GLIBC_PRIVATE'
/home/sburnwal/glibc-2.3.2-build/lib/libc.so.6: undefined reference to `_dl_signal_error@GLIBC_PRIVATE'
/home/sburnwal/glibc-2.3.2-build/lib/libc.so.6: undefined reference to `_dl_debug_printf@GLIBC_PRIVATE'
/home/sburnwal/glibc-2.3.2-build/lib/libc.so.6: undefined reference to `_dl_map_object_deps@GLIBC_PRIVATE'
It seems like the glibc shared library is not compatible with you gcc binary.
Maybe the gcc binary which you have was not compiled with the same glibc version which is installed on your system.