summaryrefslogtreecommitdiff
path: root/gcc/ada/prj-env.adb
diff options
context:
space:
mode:
authorcharlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4>2011-12-23 09:36:49 +0000
committercharlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4>2011-12-23 09:36:49 +0000
commitb5dea9cd0ebbc1a3c706adbba8914f50837e4fa1 (patch)
treeac173532856e499f071301288be35fa355582b5c /gcc/ada/prj-env.adb
parent43c5696dfa156ed24dba1fac47723c3bd80bf4cd (diff)
downloadgcc-b5dea9cd0ebbc1a3c706adbba8914f50837e4fa1.tar.gz
2011-12-23 Pascal Obry <obry@adacore.com>
* prj.ads (For_Every_Project_Imported): Add In_Aggregate_Lib parameter to generic formal procedure. * prj.adb (For_Every_Project_Imported): Update accordingly. (Recursive_Check): Likewise. Do not parse imported project for aggregate library. This is needed as the imported projects are there just to handle dependencies. (Look_For_Sources): Likewise. (Recursive_Add): Likewise. * prj-env.adb, prj-conf.adb, makeutl.adb, gnatcmd.adb: Add In_Aggregate_Lib parameter to routines used with For_Every_Project_Imported generic procedure. * prj-nmsc.adb (Tree_Processing_Data): Add In_Aggregate_Lib field. (Check): Move where it is used. Fix implementation to not check libraries that are inside aggregate libraries. (Recursive_Check): Add In_Aggregate_Lib parameter. 2011-12-23 Ed Schonberg <schonberg@adacore.com> * sem_ch7.adb (Analyze_Package_Body, Has_Referencer): A generic package is a referencer regardless of whether there is a subsequent subprogram with an Inline pragma. 2011-12-23 Geert Bosch <bosch@adacore.com> * sem_ch3.adb (Can_Derive_From): Check matching Float_Rep on VMS. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@182656 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/ada/prj-env.adb')
-rw-r--r--gcc/ada/prj-env.adb112
1 files changed, 63 insertions, 49 deletions
diff --git a/gcc/ada/prj-env.adb b/gcc/ada/prj-env.adb
index bce59d96bcc..1ff9a5c8f3f 100644
--- a/gcc/ada/prj-env.adb
+++ b/gcc/ada/prj-env.adb
@@ -115,9 +115,10 @@ package body Prj.Env is
Buffer_Last : Natural := 0;
procedure Add
- (Project : Project_Id;
- In_Tree : Project_Tree_Ref;
- Dummy : in out Boolean);
+ (Project : Project_Id;
+ In_Tree : Project_Tree_Ref;
+ In_Aggregate_Lib : Boolean;
+ Dummy : in out Boolean);
-- Add source dirs of Project to the path
---------
@@ -125,11 +126,12 @@ package body Prj.Env is
---------
procedure Add
- (Project : Project_Id;
- In_Tree : Project_Tree_Ref;
- Dummy : in out Boolean)
+ (Project : Project_Id;
+ In_Tree : Project_Tree_Ref;
+ In_Aggregate_Lib : Boolean;
+ Dummy : in out Boolean)
is
- pragma Unreferenced (Dummy);
+ pragma Unreferenced (Dummy, In_Aggregate_Lib);
begin
Add_To_Path
(Project.Source_Dirs, In_Tree.Shared, Buffer, Buffer_Last);
@@ -185,9 +187,10 @@ package body Prj.Env is
Buffer_Last : Natural := 0;
procedure Add
- (Project : Project_Id;
- In_Tree : Project_Tree_Ref;
- Dummy : in out Boolean);
+ (Project : Project_Id;
+ In_Tree : Project_Tree_Ref;
+ In_Aggregate_Lib : Boolean;
+ Dummy : in out Boolean);
-- Add all the object directories of a project to the path
---------
@@ -195,11 +198,12 @@ package body Prj.Env is
---------
procedure Add
- (Project : Project_Id;
- In_Tree : Project_Tree_Ref;
- Dummy : in out Boolean)
+ (Project : Project_Id;
+ In_Tree : Project_Tree_Ref;
+ In_Aggregate_Lib : Boolean;
+ Dummy : in out Boolean)
is
- pragma Unreferenced (Dummy, In_Tree);
+ pragma Unreferenced (Dummy, In_Tree, In_Aggregate_Lib);
Path : constant Path_Name_Type :=
Get_Object_Directory
@@ -472,9 +476,10 @@ package body Prj.Env is
Current_Naming : Naming_Id;
procedure Check
- (Project : Project_Id;
- In_Tree : Project_Tree_Ref;
- State : in out Integer);
+ (Project : Project_Id;
+ In_Tree : Project_Tree_Ref;
+ In_Aggregate_Lib : Boolean;
+ State : in out Integer);
-- Recursive procedure that put in the config pragmas file any non
-- standard naming schemes, if it is not already in the file, then call
-- itself for any imported project.
@@ -496,11 +501,12 @@ package body Prj.Env is
-----------
procedure Check
- (Project : Project_Id;
- In_Tree : Project_Tree_Ref;
- State : in out Integer)
+ (Project : Project_Id;
+ In_Tree : Project_Tree_Ref;
+ In_Aggregate_Lib : Boolean;
+ State : in out Integer)
is
- pragma Unreferenced (State);
+ pragma Unreferenced (State, In_Aggregate_Lib);
Lang : constant Language_Ptr :=
Get_Language_From_Name (Project, "ada");
@@ -786,9 +792,10 @@ package body Prj.Env is
-- Put the line contained in the Name_Buffer in the global buffer
procedure Process
- (Project : Project_Id;
- In_Tree : Project_Tree_Ref;
- State : in out Integer);
+ (Project : Project_Id;
+ In_Tree : Project_Tree_Ref;
+ In_Aggregate_Lib : Boolean;
+ State : in out Integer);
-- Generate the mapping file for Project (not recursively)
---------------------
@@ -811,11 +818,12 @@ package body Prj.Env is
-------------
procedure Process
- (Project : Project_Id;
- In_Tree : Project_Tree_Ref;
- State : in out Integer)
+ (Project : Project_Id;
+ In_Tree : Project_Tree_Ref;
+ In_Aggregate_Lib : Boolean;
+ State : in out Integer)
is
- pragma Unreferenced (State);
+ pragma Unreferenced (State, In_Aggregate_Lib);
Source : Source_Id;
Suffix : File_Name_Type;
@@ -1225,9 +1233,10 @@ package body Prj.Env is
Tree : Project_Tree_Ref)
is
procedure For_Project
- (Prj : Project_Id;
- Tree : Project_Tree_Ref;
- Dummy : in out Integer);
+ (Prj : Project_Id;
+ Tree : Project_Tree_Ref;
+ In_Aggregate_Lib : Boolean;
+ Dummy : in out Integer);
-- Get all object directories of Prj
-----------------
@@ -1235,11 +1244,12 @@ package body Prj.Env is
-----------------
procedure For_Project
- (Prj : Project_Id;
- Tree : Project_Tree_Ref;
- Dummy : in out Integer)
+ (Prj : Project_Id;
+ Tree : Project_Tree_Ref;
+ In_Aggregate_Lib : Boolean;
+ Dummy : in out Integer)
is
- pragma Unreferenced (Dummy, Tree);
+ pragma Unreferenced (Dummy, Tree, In_Aggregate_Lib);
begin
-- ??? Set_Ada_Paths has a different behavior for library project
@@ -1270,9 +1280,10 @@ package body Prj.Env is
In_Tree : Project_Tree_Ref)
is
procedure For_Project
- (Prj : Project_Id;
- In_Tree : Project_Tree_Ref;
- Dummy : in out Integer);
+ (Prj : Project_Id;
+ In_Tree : Project_Tree_Ref;
+ In_Aggregate_Lib : Boolean;
+ Dummy : in out Integer);
-- Get all object directories of Prj
-----------------
@@ -1280,11 +1291,12 @@ package body Prj.Env is
-----------------
procedure For_Project
- (Prj : Project_Id;
- In_Tree : Project_Tree_Ref;
- Dummy : in out Integer)
+ (Prj : Project_Id;
+ In_Tree : Project_Tree_Ref;
+ In_Aggregate_Lib : Boolean;
+ Dummy : in out Integer)
is
- pragma Unreferenced (Dummy);
+ pragma Unreferenced (Dummy, In_Aggregate_Lib);
Current : String_List_Id := Prj.Source_Dirs;
The_String : String_Element;
@@ -1642,9 +1654,10 @@ package body Prj.Env is
Buffer_Last : Natural := 0;
procedure Recursive_Add
- (Project : Project_Id;
- In_Tree : Project_Tree_Ref;
- Dummy : in out Boolean);
+ (Project : Project_Id;
+ In_Tree : Project_Tree_Ref;
+ In_Aggregate_Lib : Boolean;
+ Dummy : in out Boolean);
-- Recursive procedure to add the source/object paths of extended/
-- imported projects.
@@ -1653,11 +1666,12 @@ package body Prj.Env is
-------------------
procedure Recursive_Add
- (Project : Project_Id;
- In_Tree : Project_Tree_Ref;
- Dummy : in out Boolean)
+ (Project : Project_Id;
+ In_Tree : Project_Tree_Ref;
+ In_Aggregate_Lib : Boolean;
+ Dummy : in out Boolean)
is
- pragma Unreferenced (Dummy, In_Tree);
+ pragma Unreferenced (Dummy, In_Tree, In_Aggregate_Lib);
Path : Path_Name_Type;