[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Glibc-bsd-hackers] Re: [PATCH] GNU/k*BSD support (with ChangeLog) for g
From: |
David O'Brien |
Subject: |
[Glibc-bsd-hackers] Re: [PATCH] GNU/k*BSD support (with ChangeLog) for gcc |
Date: |
Fri, 19 Mar 2004 08:13:14 -0800 |
User-agent: |
Mutt/1.4.1i |
On Mon, Mar 15, 2004 at 03:21:55AM +0100, Robert Millan wrote:
> The attached patch rewrites GNU/kFreeBSD support so that it shares common
> definitions with GNU/Linux and only adds minimal changes, resulting in
> much better integration (both externaly and wrt gcc internals). It does
> also add GNU/kNetBSD.
...
> diff -Nur gcc.old/gcc/config/freebsd-spec.h gcc/gcc/config/freebsd-spec.h
> --- gcc.old/gcc/config/freebsd-spec.h 2004-02-04 21:00:52.000000000 +0100
> +++ gcc/gcc/config/freebsd-spec.h 2004-03-13 23:03:41.000000000 +0100
> @@ -61,6 +61,7 @@
> builtin_define ("__FreeBSD__=3"); \
> else \
> builtin_define ("__FreeBSD__"); \
> + builtin_define ("__FreeBSD_kernel__"); \
> builtin_define_std ("unix"); \
> builtin_define ("__KPRINTF_ATTRIBUTE__"); \
> builtin_assert ("system=unix"); \
I respectfully really, really don't like this. This is a
FreeBSD-specific file and the FreeBSD developers shouldn't have to be
careful about what symbols we start using in our kernel. The
GNU/kFreeBSD bits should remain in separate files that won't get in the
way of FreeBSD's evolution. Is it is really too hard to maintain things
they way they are now?
> -#define LINK_SPEC "-m elf_i386 %{shared:-shared} \
> +#define LINK_SPEC "-m " LINK_EMULATION " %{shared:-shared} \
Rather than depend on ANSI-C string concatenation, why not do it right
and create %(link_emulation).
> - %{!dynamic-linker:-dynamic-linker /lib/ld-linux.so.2}} \
> + %{!dynamic-linker:-dynamic-linker " LINK_LDPATH "}} \
Ditto. See how I already implemented this in gcc/config/freebsd-spec.h
and gcc/config/i386/freebsd.h with %(fbsd_dynamic_linker). We could
easily change this to just %(dynamic_linker) for constancy w/in GCC.
--
-- David (address@hidden)
- [Glibc-bsd-hackers] Re: [PATCH] GNU/k*BSD support (with ChangeLog) for gcc,
David O'Brien <=