OSDN Git Service

2007-08-16 Vincent Celier <celier@adacore.com>
authorcharlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 16 Aug 2007 12:21:20 +0000 (12:21 +0000)
committercharlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 16 Aug 2007 12:21:20 +0000 (12:21 +0000)
* vms_conv.adb (Process_Argument): Ensure that project related options
are not put in the -cargs section when using GNAT COMPILE.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@127551 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/ada/vms_conv.adb

index f30bf6e..f40898e 100644 (file)
@@ -1788,8 +1788,17 @@ package body VMS_Conv is
                   end if;
 
                   if Sw /= null then
-                     case Sw.Translation is
+                     if Cargs
+                       and then Sw.Name /= null
+                       and then
+                         (Sw.Name.all = "/PROJECT_FILE"          or else
+                          Sw.Name.all = "/MESSAGES_PROJECT_FILE" or else
+                          Sw.Name.all = "/EXTERNAL_REFERENCE")
+                     then
+                        Cargs := False;
+                     end if;
 
+                     case Sw.Translation is
                         when T_Direct =>
                            Place_Unix_Switches (Sw.Unix_String);
                            if SwP < Arg'Last