Solaris Freewhere Packages
Rupert Wood
me@rupey.net
Mon Apr 7 11:59:00 GMT 2003
Zinnie Jones wrote:
> When I test gcc with gcc -v -x c /dev/null to see if gcc is working,
> I get
>
> ld: Software Generation Utilities - Solaris Link Editors: 5.8-1.279
> Undefined first referenced
> symbol in file
> main
That's correct, isn't it? You're asking it to compile and link an empty
source file. You're not providing it a main() function so it can't link.
You could try compiling and linking:
int main(void) { return 0; }
or similar, or more traditionally
#include <stdio.h>
int main(void) { printf("Hello, World\n"); return 0; }
Alternatively, you could tell your command not to link with -c,
gcc -v -c -x c /dev/null
and you'll null.o produced.
> I can not get any of the gcc packages to install.
Which packages? Everything looks OK to me from the above, or do you need
help rebuilding GCC from source? If you've got prebuilt binary GCC from
Sunfreeware or similar you'll probably have to ask them for help but
it's generally just
gzip -d gcc-package-local.gz
pkgadd -d gcc-package-local.gz
Good luck,
Rup.
More information about the Gcc-help
mailing list