Add GNU userspace options from specs to new gnu-user.opt

Message ID
State New
Headers show

Commit Message

Joseph Myers Jan. 27, 2011, 4:45 p.m.
In preparation for the driver only accepting options listed in .opt
files, and not other options that simply happen to match some spec,
this patch adds options generally accepted by specs for GNU-userspace
targets to a new gnu-user.opt file.  Note that even where these
targets do not use gnu-user.h, the subdirectory specs generally accept
these options, and where the specs do not accept the options that can
reasonably be considered a bug in those specs (except for some uClinux
targets where some of the options may be inapplicable - however, if
the options are inapplicable and not in specs the driver will continue
to reject them as before by the logic for rejecting options not
matched by a spec; that logic is intended to stay, with only the
converse logic of accepting an otherwise unknown option matched by
some spec intended to go).

Bootstrapped with no regressions on x86_64-unknown-linux-gnu.  OK to

2011-01-27  Joseph Myers  <>

	* config/gnu-user.opt: New.
	* config.gcc (*-*-linux* | frv-*-*linux* | *-*-kfreebsd*-gnu |
	*-*-knetbsd*-gnu | *-*-gnu* | *-*-kopensolaris*-gnu,
	*-*-uclinux*): Use gnu-user.opt.


Joseph Myers Feb. 3, 2011, 4:13 p.m. | #1
Ping.  This patch 
<> is pending 
Joseph Myers Feb. 8, 2011, 8:37 p.m. | #2
I have committed this patch.


Index: gcc/config.gcc
--- gcc/config.gcc	(revision 169317)
+++ gcc/config.gcc	(working copy)
@@ -543,6 +543,7 @@  case ${target} in
 *-*-linux* | frv-*-*linux* | *-*-kfreebsd*-gnu | *-*-knetbsd*-gnu | *-*-gnu* | *-*-kopensolaris*-gnu)
+  extra_options="$extra_options gnu-user.opt"
   extra_parts="crtbegin.o crtbeginS.o crtbeginT.o crtend.o crtendS.o"
@@ -657,6 +658,7 @@  case ${target} in
+  extra_options="$extra_options gnu-user.opt"
   tm_defines="$tm_defines DEFAULT_LIBC=LIBC_UCLIBC SINGLE_LIBC"
Index: gcc/config/gnu-user.opt
--- gcc/config/gnu-user.opt	(revision 0)
+++ gcc/config/gnu-user.opt	(revision 0)
@@ -0,0 +1,39 @@ 
+; Options for systems using gnu-user.h.
+; Copyright (C) 2011
+; Free Software Foundation, Inc.
+; This file is part of GCC.
+; GCC is free software; you can redistribute it and/or modify it under
+; the terms of the GNU General Public License as published by the Free
+; Software Foundation; either version 3, or (at your option) any later
+; version.
+; GCC is distributed in the hope that it will be useful, but WITHOUT ANY
+; WARRANTY; without even the implied warranty of MERCHANTABILITY or
+; FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+; for more details.
+; You should have received a copy of the GNU General Public License
+; along with GCC; see the file COPYING3.  If not see
+; <>.
+; See the GCC internals manual (options.texi) for a description of
+; this file's format.
+; Please try to keep this file in ASCII collating order.
+; This comment is to ensure we retain the blank line above.