+2011-02-14 Eric Botcazou <ebotcazou@adacore.com>
+
+ * gcc-interface/misc.c (gnat_init_options): Do not concatenate -I and
+ its argument, except for the special -I- switch.
+
2011-02-12 Gerald Pfeifer <gerald@pfeifer.com>
* gnat_ugn.texi (Compiling Different Versions of Ada): Update
|| num_elements == 0)
continue;
- if (decoded_options[i].opt_index == OPT_I)
- {
- gcc_assert (num_elements == 2);
- save_argv[save_argc++]
- = concat (decoded_options[i].canonical_option[0],
- decoded_options[i].canonical_option[1], NULL);
- }
+ /* Deal with -I- specially since it must be a single switch. */
+ if (decoded_options[i].opt_index == OPT_I
+ && num_elements == 2
+ && decoded_options[i].canonical_option[1][0] == '-'
+ && decoded_options[i].canonical_option[1][1] == '\0')
+ save_argv[save_argc++] = "-I-";
else
{
gcc_assert (num_elements >= 1 && num_elements <= 2);