Commit c87b811b authored by Maxime Perrotin's avatar Maxime Perrotin

Iterate on the templates

parent 539e376c
......@@ -23,9 +23,15 @@ package body TASTE.Backend.Build_Script is
Element_Func : constant String :=
Parse (Prefix & "build-script-func.tmplt", Template_Data);
begin
Vec_Code := Vec_Code & Element_Code;
Vec_Zip := Vec_Zip & Element_Zip;
Vec_Func := Vec_Func & Element_Func;
if Element_Code'Length > 0 then
Vec_Code := Vec_Code & Element_Code;
end if;
if Element_Zip'Length > 0 then
Vec_Zip := Vec_Zip & Element_Zip;
end if;
if Element_Func'Length > 0 then
Vec_Func := Vec_Func & Element_Func;
end if;
end;
end loop;
Put_Line ("==== Generating build script ====");
......
package TASTE.Parser_Version is
Parser_Release : constant String :=
"2f67821 ; Commit Date: Wed Jan 3 08:43:19 2018 ";
"539e376 ; Commit Date: Wed Jan 3 18:21:39 2018 ";
Ocarina_Version : constant String :=
"Ocarina 2017.x (Working Copy from rd078c54)";
end TASTE.Parser_Version;
\ No newline at end of file
......@@ -33,6 +33,8 @@ package body TASTE.Templates is
function Generate (Template_Name : String) return String is
(Parse (Template_Name, Tmpl_Set));
begin
Set_Tag_Separators (Start_With => "<",
Stop_With => ">");
null;
-- Don't change the separators, these could conflict with @@IF@@ syntax
-- Set_Tag_Separators (Start_With => "<",
-- Stop_With => ">");
end TASTE.Templates;
--sub<Language> <Function_Name> \
@@IF@@ @_Language_@ /= "LANGUAGE_GUI"
--sub@_REPLACE(Sdl/Ada):REPLACE(Ada_95/Ada):CAPITALIZE:SLICE(10 .. 0):Language_@ @_Function_Name_@ \
@@END_IF@@
# Generate code for function "<Function_Name>" implemented in "<Language>"
# Generate code for function "@_Function_Name_@ implemented in "@_Language_@
# Zip code of function <Function_Name>
# Zip code of function @_Function_Name_@
#!/bin/bash -e
# This script will build your system
# DO NOT EDIT THIS FILE - IT WAS GENERATED BY TASTE
# DO NOT EDIT THIS FILE
# Generated by TASTE on @_Now_@
# If you need additional pre-processing, there are three hook files
# that you can provide and that are called dring the build:
......@@ -35,17 +36,17 @@ USE_POHIC=1
# Set Debug mode by default
DEBUG_MODE=--debug
INTERFACEVIEW=<Interface_View_Path>
INTERFACEVIEW=@_Interface_View_Path_@
# Output path were the user code was generated
SKELS=<Output_Path>
SKELS=@_Output_Path_@
@@TABLE@@
<Generate_Code>
@_Generate_Code_@
@@END_TABLE@@
@@TABLE@@
<Zip_Code>
@_Zip_Code_@
@@END_TABLE@@
if [ -f ConcurrencyView.pro ]
......@@ -81,13 +82,13 @@ assert-builder-ocarina.py \
--aadlv2 \
--keep-case \
$DEBUG_MODE \
--interfaceView "$INTERFACEVIEW" \
--interfaceView "$INTERFACEVIEW" \
--deploymentView "$DEPLOYMENTVIEW" \
-o "$OUTPUTDIR" \
@@TABLE@@
<Functions>
@_REPLACE((\n)/):Functions_@
@@END_TABLE@@
<CodeCoverage> \
@_CodeCoverage_@ \
$ORCHESTRATOR_OPTIONS
if [ -f user_init_last.sh ]
......
-- TASTE CONFIGURATION ------------------------------------
|
|Interface View : <Interface_View>
|Deployment View : <Deployment_View>
|Data View : <Data_View>
|Interface View : @_Interface_View_@
|Deployment View : @_Deployment_View_@
|Data View : @_Data_View_@
|Other Files :
@@TABLE@@
<Other_Files>
@_Other_Files_@
@@END_TABLE@@
|Output Directory : <Output_Directory>
|Generate skeletons : <Skeletons>
|Generate glue : <Glue>
|Debug mode : <Debug_Flag>
|Request Version : <Version>
|Timer resolution : <Timer_Resolution>
|Use PolyORB-HI-C : <Use_POHIC>
|Output Directory : @_Output_Directory_@
|Generate skeletons : @_YES_NO:Skeletons_@
|Generate glue : @_YES_NO:Glue_@
|Debug mode : @_YES_NO:Debug_Flag_@
|Request Version : @_YES_NO:Version_@
|Timer resolution : @_Timer_Resolution_@
|Use PolyORB-HI-C : @_YES_NO:Use_POHIC_@
|
-----------------------------------------------------------
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