-- --
-- B o d y --
-- --
--- Copyright (C) 2001-2005, Free Software Foundation, Inc. --
+-- Copyright (C) 2001-2006, Free Software Foundation, Inc. --
-- --
-- GNAT is free software; you can redistribute it and/or modify it under --
-- terms of the GNU General Public License as published by the Free Soft- --
Ptr := Ptr + 1;
List_Restrictions := True;
+ -- Processing for R switch
+
+ when 'R' =>
+ Ptr := Ptr + 1;
+ Check_Only := True;
+ List_Closure := True;
+
-- Processing for s switch
when 's' =>
Ptr := Ptr + 1;
No_Main_Subprogram := True;
+ -- Processing for Z switch
+
+ when 'Z' =>
+ Ptr := Ptr + 1;
+ Zero_Formatting := True;
+
-- Processing for --RTS
when '-' =>
-- --
-- B o d y --
-- --
--- Copyright (C) 2001-2006, Free Software Foundation, Inc. --
+-- Copyright (C) 2001-2007, Free Software Foundation, Inc. --
-- --
-- GNAT is free software; you can redistribute it and/or modify it under --
-- terms of the GNU General Public License as published by the Free Soft- --
with Debug; use Debug;
with Osint; use Osint;
with Opt; use Opt;
+with Prj.Ext; use Prj.Ext;
with Table;
package body Switch.M is
when False =>
-- All switches that don't start with -gnat stay as is,
- -- except -v and -pg
+ -- except -v, -E and -pg
if Switch_Chars = "-pg" then
Add_Switch_Component ("-p");
- elsif C /= 'v' then
+ -- Do not take into account switches that are not transmitted
+ -- to gnat1 by the gcc driver.
+
+ elsif C /= 'v' and then C /= 'E' then
Add_Switch_Component (Switch_Chars);
end if;
if Switch_Chars = "--create-missing-dirs" then
Setup_Projects := True;
+ elsif Switch_Chars'Length > 3 and then
+ Switch_Chars (Ptr .. Ptr + 1) = "aP"
+ then
+ Add_Search_Project_Directory
+ (Switch_Chars (Ptr + 2 .. Switch_Chars'Last));
+
elsif C = 'v' and then Switch_Chars'Length = 3 then
Ptr := Ptr + 1;
Verbose_Mode := True;