> I suspect that "gcc" isn't the standard FreeBSD C compiler in your
> case.  Try "which gcc" and find out.  It works fine for me on both
> -stable and -current with "cc":

It is an older one indeed.

> blake$ cc -v -nostdlib hello.c
> Using builtin specs.
> gcc version 2.95.2 19991024 (release)
>  /usr/libexec/cpp -lang-c -v -D__GNUC__=2 -D__GNUC_MINOR__=95 -Di386 -Dunix 
>-D__FreeBSD__=4 -D__FreeBSD_cc_version=400004 -D__i386__ -D__unix__ -D__FreeBSD__=4 
>-D__FreeBSD_cc_version=400004 -D__i386 -D__unix -Acpu(i386) -Amachine(i386) 
>-Asystem(unix) -Asystem(FreeBSD) -Acpu(i386) -
Amachine(i386) -Di386 -D__i386 -D__i386__ -D__ELF__ hello.c /tmp/cciRD216.i
> GNU CPP version 2.95.2 19991024 (release) (i386 FreeBSD/ELF)
> #include "..." search starts here:
> #include <...> search starts here:
>  /usr/include
>  /usr/include
> End of search list.
> The following default directories have been omitted from the search path:
>  /usr/include/g++
> End of omitted list.
>  /usr/libexec/cc1 /tmp/cciRD216.i -quiet -dumpbase hello.c -version -o 
>/tmp/ccbyU216.s
> GNU C version 2.95.2 19991024 (release) (i386-unknown-freebsd) compiled by GNU C 
>version 2.95.2 19991024 (release).
>  /usr/libexec/elf/as -v -o /tmp/ccWvs216.o /tmp/ccbyU216.s
> GNU assembler version 2.9.1 (i386-unknown-freebsdelf), using BFD version 2.9.1
>  /usr/libexec/elf/ld -m elf_i386 -dynamic-linker /usr/libexec/ld-elf.so.1 
>-L/usr/libexec/elf -L/usr/libexec -L/usr/lib /tmp/ccWvs216.o
> /usr/libexec/elf/ld: warning: cannot find entry symbol _start; defaulting to 08048074
> /tmp/ccWvs216.o: In function `main':
> /tmp/ccWvs216.o(.text+0xf): undefined reference to `printf'

Still doesn't work though with the newer one :-)
(try some arithmetic to see if that works.
Marco van de Voort ([EMAIL PROTECTED])
<http://www.stack.nl/~marcov/xtdlib.htm>


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message

Reply via email to