Commit 6541e95c authored by julien.delange's avatar julien.delange

* ocarina_cmd.adb

   - Add a new option to provide the ability
     to load ocarina components library from
     scenario files.



git-svn-id: https://tecsw.estec.esa.int/svn/taste/trunk/ocarina@2043 129961e7-ef38-4bb5-a8f7-c9a525a55882
parent 4688cd77
......@@ -639,6 +639,7 @@ procedure Ocarina_Cmd is
Source_Files : List_Id;
Ref_Files : List_Id;
Needed_PS : List_Id;
Use_CL : Boolean := False;
Used_Generator_Options : List_Id;
Dirname : Name_Id;
Success : Boolean := False;
......@@ -660,6 +661,8 @@ procedure Ocarina_Cmd is
AADL_Files : constant Name_Id
:= Get_String_Name (Ocarina_Config & "::aadl_files");
Use_Components_Library : constant Name_Id
:= Get_String_Name (Ocarina_Config & "::use_components_library");
Referencial_Files : constant Name_Id
:= Get_String_Name (Ocarina_Config & "::referencial_files");
The_Generator : constant Name_Id
......@@ -886,6 +889,13 @@ procedure Ocarina_Cmd is
Needed_PS := No_List;
end if;
if Is_Defined_Boolean_Property
(Root_System, Use_Components_Library) then
Use_CL := True;
else
Use_CL := False;
end if;
-- Extract the generator options.
if Is_Defined_List_Property (Root_System, Generator_Options) then
......@@ -943,6 +953,13 @@ procedure Ocarina_Cmd is
Sources.Init;
Extract_Source_Files (Source_Files, Needed_PS);
if Use_CL then
Set_Str_To_Name_Buffer ("ocarina_components.aadl");
Ocarina.Files.Add_File_To_Parse_List (Name_Find);
Set_Str_To_Name_Buffer ("base_types.aadl");
Ocarina.Files.Add_File_To_Parse_List (Name_Find);
end if;
Extract_Referencial_Files (Ref_Files, Ref_Map);
-- Extract the name of the root of the instance tree
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment