diff options
author | Manuel López-Ibáñez <manu@gcc.gnu.org> | 2010-04-08 17:21:26 +0000 |
---|---|---|
committer | Manuel López-Ibáñez <manu@gcc.gnu.org> | 2010-04-08 17:21:26 +0000 |
commit | 1401cf37c0f4bd9e35d9a3abc1e4e69ee0c0ebeb (patch) | |
tree | 433be0dd043095ee2230d5a9c8a65c2293a07451 | |
parent | 40ac4f73faa256e049279c1611d47a685ff7f370 (diff) | |
download | gcc-1401cf37c0f4bd9e35d9a3abc1e4e69ee0c0ebeb.zip gcc-1401cf37c0f4bd9e35d9a3abc1e4e69ee0c0ebeb.tar.gz gcc-1401cf37c0f4bd9e35d9a3abc1e4e69ee0c0ebeb.tar.bz2 |
re PR driver/42485 (-V switch broken)
2010-04-08 Manuel López-Ibáñez <manu@gcc.gnu.org>
PR 42485
* doc/invoke.texi (-b,-V): Delete.
* doc/tm.texi: Do not mention -b.
* gcc.c (display_help): Delete -b and -V.
(process_command): Delete -b and -V.
* gcc.h (DEFAULT_SWITCH_TAKES_ARG): Delete -b and -V.
From-SVN: r158134
-rw-r--r-- | gcc/ChangeLog | 9 | ||||
-rw-r--r-- | gcc/doc/invoke.texi | 39 | ||||
-rw-r--r-- | gcc/doc/tm.texi | 9 | ||||
-rw-r--r-- | gcc/gcc.c | 90 | ||||
-rw-r--r-- | gcc/gcc.h | 2 |
5 files changed, 18 insertions, 131 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index ecf1f26..4b7d1e2 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,12 @@ +2010-04-08 Manuel López-Ibáñez <manu@gcc.gnu.org> + + PR 42485 + * doc/invoke.texi (-b,-V): Delete. + * doc/tm.texi: Do not mention -b. + * gcc.c (display_help): Delete -b and -V. + (process_command): Delete -b and -V. + * gcc.h (DEFAULT_SWITCH_TAKES_ARG): Delete -b and -V. + 2010-04-08 Christian Borntraeger <borntraeger@de.ibm.com> Wolfgang Gellerich <gellerich@de.ibm.com> diff --git a/gcc/doc/invoke.texi b/gcc/doc/invoke.texi index 67a1b60..7a8ca55 100644 --- a/gcc/doc/invoke.texi +++ b/gcc/doc/invoke.texi @@ -428,11 +428,6 @@ Objective-C and Objective-C++ Dialects}. @gccoptlist{-B@var{prefix} -I@var{dir} -iquote@var{dir} -L@var{dir} -specs=@var{file} -I- --sysroot=@var{dir}} -@item Target Options -@c I wrote this xref this way to avoid overfull hbox. -- rms -@xref{Target Options}. -@gccoptlist{-V @var{version} -b @var{machine}} - @item Machine Dependent Options @xref{Submodel Options,,Hardware Models and Configurations}. @c This list is ordered alphanumerically by subsection name. @@ -9556,33 +9551,7 @@ proper position among the other output files. The usual way to run GCC is to run the executable called @file{gcc}, or @file{<machine>-gcc} when cross-compiling, or @file{<machine>-gcc-<version>} to run a version other than the one that -was installed last. Sometimes this is inconvenient, so GCC provides -options that will switch to another cross-compiler or version. - -@table @gcctabopt -@item -b @var{machine} -@opindex b -The argument @var{machine} specifies the target machine for compilation. - -The value to use for @var{machine} is the same as was specified as the -machine type when configuring GCC as a cross-compiler. For -example, if a cross-compiler was configured with @samp{configure -arm-elf}, meaning to compile for an arm processor with elf binaries, -then you would specify @option{-b arm-elf} to run that cross compiler. -Because there are other options beginning with @option{-b}, the -configuration must contain a hyphen, or @option{-b} alone should be one -argument followed by the configuration in the next argument. - -@item -V @var{version} -@opindex V -The argument @var{version} specifies which version of GCC to run. -This is useful when multiple versions are installed. For example, -@var{version} might be @samp{4.0}, meaning to run GCC version 4.0. -@end table - -The @option{-V} and @option{-b} options work by running the -@file{<machine>-gcc-<version>} executable, so there's no real reason to -use them if you can just run that directly. +was installed last. @node Submodel Options @section Hardware Models and Configurations @@ -9591,11 +9560,7 @@ use them if you can just run that directly. @cindex hardware models and configurations, specifying @cindex machine dependent options -Earlier we discussed the standard option @option{-b} which chooses among -different installed compilers for completely different target -machines, such as VAX vs.@: 68000 vs.@: 80386. - -In addition, each of these target machine types can have its own +Each target machine types can have its own special options, starting with @samp{-m}, to choose among various hardware models or configurations---for example, 68010 vs 68020, floating coprocessor or none. A single installed version of the diff --git a/gcc/doc/tm.texi b/gcc/doc/tm.texi index 222117d..8337e16 100644 --- a/gcc/doc/tm.texi +++ b/gcc/doc/tm.texi @@ -465,7 +465,7 @@ indicates an absolute file name. @defmac MD_EXEC_PREFIX If defined, this macro is an additional prefix to try after @code{STANDARD_EXEC_PREFIX}. @code{MD_EXEC_PREFIX} is not searched -when the @option{-b} option is used, or the compiler is built as a cross +when the compiler is built as a cross compiler. If you define @code{MD_EXEC_PREFIX}, then be sure to add it to the list of directories used to find the assembler in @file{configure.in}. @end defmac @@ -497,14 +497,13 @@ is built as a cross compiler. @defmac MD_STARTFILE_PREFIX If defined, this macro supplies an additional prefix to try after the standard prefixes. @code{MD_EXEC_PREFIX} is not searched when the -@option{-b} option is used, or when the compiler is built as a cross -compiler. +compiler is built as a cross compiler. @end defmac @defmac MD_STARTFILE_PREFIX_1 If defined, this macro supplies yet another prefix to try after the -standard prefixes. It is not searched when the @option{-b} option is -used, or when the compiler is built as a cross compiler. +standard prefixes. It is not searched when the compiler is built as a +cross compiler. @end defmac @defmac INIT_ENVIRONMENT @@ -262,11 +262,11 @@ static int use_pipes; static const char *compiler_version; -/* The target version specified with -V */ +/* The target version. */ static const char *const spec_version = DEFAULT_TARGET_VERSION; -/* The target machine specified with -b. */ +/* The target machine. */ static const char *spec_machine = DEFAULT_TARGET_MACHINE; @@ -3420,8 +3420,6 @@ display_help (void) --sysroot=<directory> Use <directory> as the root directory for headers\n\ and libraries\n"), stdout); fputs (_(" -B <directory> Add <directory> to the compiler's search paths\n"), stdout); - fputs (_(" -b <machine> Run gcc for target <machine>, if installed\n"), stdout); - fputs (_(" -V <version> Run gcc version number <version>, if installed\n"), stdout); fputs (_(" -v Display the programs invoked by the compiler\n"), stdout); fputs (_(" -### Like -v but options quoted and commands not executed\n"), stdout); fputs (_(" -E Preprocess only; do not compile, assemble or link\n"), stdout); @@ -3526,81 +3524,6 @@ process_command (int argc, const char **argv) } } - /* If there is a -V or -b option (or both), process it now, before - trying to interpret the rest of the command line. - Use heuristic that all configuration names must have at least - one dash '-'. This allows us to pass options starting with -b. */ - if (argc > 1 && argv[1][0] == '-' - && (argv[1][1] == 'V' - || (argv[1][1] == 'b' - && (argv[1][2] == '\0' - || NULL != strchr (argv[1] + 2, '-'))))) - { - const char *new_version = DEFAULT_TARGET_VERSION; - const char *new_machine = DEFAULT_TARGET_MACHINE; - const char *progname = argv[0]; - char **new_argv; - char *new_argv0; - int baselen; - int status = 0; - int err = 0; - const char *errmsg; - - while (argc > 1 && argv[1][0] == '-' - && (argv[1][1] == 'V' - || (argv[1][1] == 'b' - && (argv[1][2] == '\0' - || NULL != strchr (argv[1] + 2, '-'))))) - { - char opt = argv[1][1]; - const char *arg; - if (argv[1][2] != '\0') - { - arg = argv[1] + 2; - argc -= 1; - argv += 1; - } - else if (argc > 2) - { - arg = argv[2]; - argc -= 2; - argv += 2; - } - else - fatal ("'-%c' option must have argument", opt); - if (opt == 'V') - new_version = arg; - else - new_machine = arg; - } - - for (baselen = strlen (progname); baselen > 0; baselen--) - if (IS_DIR_SEPARATOR (progname[baselen-1])) - break; - new_argv0 = XDUPVAR (char, progname, baselen, - baselen + concat_length (new_version, new_machine, - "-gcc-", NULL) + 1); - strcpy (new_argv0 + baselen, new_machine); - strcat (new_argv0, "-gcc-"); - strcat (new_argv0, new_version); - - new_argv = XDUPVEC (char *, argv, argc + 1); - new_argv[0] = new_argv0; - - errmsg = pex_one (PEX_SEARCH, new_argv0, new_argv, progname, NULL, - NULL, &status, &err); - - if (errmsg) - { - if (err == 0) - fatal ("couldn't run '%s': %s", new_argv0, errmsg); - else - fatal ("couldn't run '%s': %s: %s", new_argv0, errmsg, - xstrerror (err)); - } - exit (status); - } - /* Convert new-style -- options to old-style. */ translate_options (&argc, CONST_CAST2 (const char *const **, const char ***, @@ -4094,15 +4017,6 @@ process_command (int argc, const char **argv) switch (c) { - case 'b': - if (p[1] && NULL == strchr (argv[i] + 2, '-')) - goto normal_switch; - - /* Fall through. */ - case 'V': - fatal ("'-%c' must come at the start of the command line", c); - break; - case 'B': { const char *value; @@ -38,7 +38,7 @@ struct spec_function || (CHAR) == 'e' || (CHAR) == 'T' || (CHAR) == 'u' \ || (CHAR) == 'I' || (CHAR) == 'J' || (CHAR) == 'm' \ || (CHAR) == 'x' || (CHAR) == 'L' || (CHAR) == 'A' \ - || (CHAR) == 'V' || (CHAR) == 'B' || (CHAR) == 'b') + || (CHAR) == 'B' ) /* This defines which multi-letter switches take arguments. */ |