OpenBSD configuration for main platforms, framework
Jeffrey A Law
law@hurl.cygnus.com
Sun Feb 28 18:15:00 GMT 1999
In message < 19990216184117.A20285@tetto.liafa.jussieu.fr >you write:
>
> --5vNYLRcllDrimb99
> Content-Type: text/plain; charset=us-ascii
>
> This is the first patch of what's needed to configure egcs on the most
> critical openbsd platforms (i386, m68k, sparc, and alpha),
> plus a config.guess patch so openbsd-*-hppa gets at least recognized...
Thanks.
> Feel free to tweak the comments to reflect FSF copyright and remove
> the $OpenBSD$ tags... I assume you've got some automatic mechanism to do
> that, and I don't want to attach n copies of this.
Please submit the patches with fixed comments and removed the RCS stuff. When
you don't do this, I have to, for each and every one of your files.
> ChangeLog for gcc:
>
> Tue Feb 16 18:30:13 CET 1999 Marc Espie <espie@cvs.openbsd.org>
> * configure.in : configure openbsd platforms
> * config.guess: recognize openbsd-*-hppa
> * config/openbsd.h: New file
> * config/xm-openbsd.h: New file
> * config/t-openbsd: New file
> * config/t-openbsd-thread: New file, experimental thread support
Capitolize and periods appy to ChangeLog entries too.
> /* $OpenBSD: openbsd.h,v 1.13 1999/02/16 17:20:55 espie Exp $ */
Kill.
> There are also a few `default' defines such as ASM_WEAKEN_LABEL,
> intended as common ground for arch that don't provide anything suitable.
> */
Close the comment on the previous line. If it won't fit, put the last word
in the comment on a new line, then close the comment.
>
> /* OPENBSD_NATIVE is defined only when gcc is configured as part of
> the OpenBSD source tree, specifically through Makefile.bsd-wrapper.
>
> In such a case the include path can be trimmed as there is no
> distinction between system includes and gcc includes
> */
> /* This configuration method, namely Makefile.bsd-wrapper and
> OPENBSD_NATIVE is NOT recommended for building cross-compilers
> */
Likewise.
>
> /* Controlling the compilation driver
> ---------------------------------- */
Kill ------------
> /* CPP_SPEC appropriate for OpenBSD. We deal with -posix and -pthread.
> XXX the way threads are handling currently is not very satisfying,
> since all code must be compiled with -pthread to work.
> This two-stage defines makes it easy to pick that for targets that
> have subspecs.
> */
Comment format.
>
> #ifndef OBSD_NO_DYNAMIC_LIBRARIES
> #undef SWITCH_TAKES_ARG
> #define SWITCH_TAKES_ARG(CHAR) \
> (DEFAULT_SWITCH_TAKES_ARG(CHAR) \
> || (CHAR) == 'R')
> #endif
Space before the open paren for the args to DEFAULT_SWITCH_TAKES_ARG.
> /* Runtime target specification
> ---------------------------- */
Fix.
> /* Implicit calls to library routines
> ---------------------------------- */
Fix.
> /* Miscellaneous parameters
> ------------------------ */
> /* tell libgcc2.c that OpenBSD targets support atexit. */
Fix.
> /* Controlling debugging info: dbx options
> --------------------------------------- */
> /* Don't use the `xsTAG;' construct in DBX output; OpenBSD systems that
> use DBX don't support it. */
Fix.
> /* Support of shared libraries, mostly imported from svr4.h through netbsd.
> */
Fix.
> /* Assembler format: output and generation of labels
> ------------------------------------------------- */
Fix.
> /* Storage layout
> -------------- */
Fix.
> /* We don't have to worry about binary compatibility with older C++ code,
> but there is a big known bug with vtable thunks which has not been
> fixed yet, so DON'T activate it by default.
> */
Fix.
> /* Otherwise, since we support weak, gthr.h erroneously tries to use
> #pragma weak
> */
Fix.
> /* `generic' xm-openbsd.h.
> This file gets included by all architectures. It holds stuff
> that ought to be defined when hosting a compiler on an OpenBSD
> machine, independently of the architecture. It's included by
> ${cpu_type}/xm-openbsd.h, not included directly.
> */
Fix.
> /* OpenBSD is trying to be POSIX-compliant, to the point of fixing
> problems that may occur with gcc's interpretation.
> */
Fix.
Overall the patches look pretty good and probably can go in once you get
the copyright headers fixed and the formatting stuff. I guess I won't
scream too much more about the OPENBSD_NATIVE stuff, even though I think
you're still making a long term mistake. A better way to do that is to
use configure options to control more closely what directories are used.
Thanks,
jeff
More information about the Gcc-patches
mailing list