Commit fdfcaa93 authored by Maxime Perrotin's avatar Maxime Perrotin
Browse files

Look for templates in dedicated directory

parent e9c639e9
......@@ -32,7 +32,8 @@ procedure AADL_Parser is
Map ("Version", Model.Configuration.Version);
Map ("Timer_Resolution", Model.Configuration.Timer_Resolution);
Put_Line ("=== Template-generated debug output ===");
Put_Line (Generate ("configuration.tmplt"));
Put_Line (Generate (Model.Configuration.Binary_Path.all
& "templates/configuration.tmplt"));
end Dump_With_Templates;
begin
Model := Parse_Project;
......
......@@ -3,6 +3,8 @@
-- LGPL license, see LICENSE file
with Ada.Text_IO,
Ada.Command_Line,
GNAT.Directory_Operations,
GNAT.OS_Lib,
GNAT.Command_Line,
Ocarina.AADL_Values,
......@@ -14,6 +16,7 @@ with Ada.Text_IO,
package body TASTE.Parser_Utils is
use Ada.Text_IO,
GNAT.Directory_Operations,
GNAT.OS_Lib,
GNAT.Command_Line,
Ocarina.Instances.Queries,
......@@ -35,6 +38,8 @@ package body TASTE.Parser_Utils is
procedure Parse_Command_Line (Result : out Taste_Configuration) is
Config : Command_Line_Configuration;
begin
Result.Binary_Path :=
new String'(Dir_Name (Ada.Command_Line.Command_Name));
Define_Switch (Config, Output => Result.Interface_View'Access,
Switch => "-i:", Long_Switch => "--interfaceview=",
Help => "Mandatory interface view (AADL model)",
......
......@@ -98,6 +98,7 @@ package TASTE.Parser_Utils is
type Taste_Configuration is tagged
record
Binary_Path : GNAT.Strings.String_Access;
Interface_View : aliased GNAT.Strings.String_Access;
Deployment_View : aliased GNAT.Strings.String_Access;
Data_View : aliased GNAT.Strings.String_Access;
......
package TASTE.Parser_Version is
Parser_Release : constant String :=
"607e11b ; Commit Date: Sun Dec 31 15:42:19 2017 ";
"e9c639e ; Commit Date: Mon Jan 1 17:22:01 2018 ";
Ocarina_Version : constant String :=
"Ocarina 2017.x (Working Copy from rd078c54)";
end TASTE.Parser_Version;
\ No newline at end of file
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