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

call asn2dataModel in templates with PROJECT_CACHE for all targets

parent 0262adff
...@@ -54,7 +54,7 @@ extern "C" { ...@@ -54,7 +54,7 @@ extern "C" {
#endif #endif
// C_ASN1_Types contains the signatures for ASN.1 Encoding/Decoding // C_ASN1_Types contains the signatures for ASN.1 Encoding/Decoding
#include "C_ASN1_Types.h" //#include "C_ASN1_Types.h"
@@IF@@ @_Language_@ = "C" or @_Language_@ = "CPP" @@IF@@ @_Language_@ = "C" or @_Language_@ = "CPP"
#include "@_LOWER:Name_@.h" #include "@_LOWER:Name_@.h"
......
...@@ -7,10 +7,10 @@ ...@@ -7,10 +7,10 @@
@@-- @_Unique_Languages_@ : List of all languages used in the system @@-- @_Unique_Languages_@ : List of all languages used in the system
@@-- @_ASN1_Files_@ : List of all ASN.1 files @@-- @_ASN1_Files_@ : List of all ASN.1 files
@@-- @_ASN1_Modules_@ : List of all ASN.1 modules @@-- @_ASN1_Modules_@ : List of all ASN.1 modules
all: compile-all-linux all: dataviews
dataviews: dataviews:
mkdir -p dataview mkdir -p dataview/.cache
@@-- Create dataview-uniq.asn @@-- Create dataview-uniq.asn
@@INLINE( )( )(\n)@@ @@INLINE( )( )(\n)@@
for f in for f in
...@@ -21,27 +21,25 @@ dataviews: ...@@ -21,27 +21,25 @@ dataviews:
@@END_INLINE@@ @@END_INLINE@@
@@-- Then generate Dataviews once per target language @@-- Then generate Dataviews once per target language
@@TABLE@@ @@TABLE@@
@@IF@@ @_Unique_Languages_@ /= "GUI" @@IF@@ @_Unique_Languages_@ /= "GUI"
@@IF@@ @_Unique_Languages_@ = "Ada" or @_Unique_Languages_@ = "SDL" @@IF@@ @_Unique_Languages_@ = "Ada" or @_Unique_Languages_@ = "SDL"
@@INLINE()()(; fi\n)@@ @@SET@@ Lang=Ada
if [ ! -d dataview/Ada ]; then mkdir dataview/Ada && mono $(shell which asn1.exe) -Ada -typePrefix asn1Scc -o dataview/Ada dataview/dataview-uniq.asn @@SET@@ Post=cd dataview/Ada && rm -f gnat.cfg GPS_project.gpr IgnoredExaminerWarnings.wrn runSpark.sh
@@TABLE@@ @@ELSIF@@ @_Unique_Languages_@ = "C" or @_Unique_Languages_@ = "CPP" or @_Unique_Languages_@ = "Blackbox_C"
@_REPLACE(,/ ):CP_Files_@ @@SET@@ Lang=C
@@END_TABLE@@ @@SET@@ Post=# Blackboxes, C and C++ all use the same C data model
@@END_INLINE@@ @@ELSE@@
cd dataview/Ada && rm -f gnat.cfg GPS_project.gpr IgnoredExaminerWarnings.wrn runSpark.sh @@SET@@ Lang=@_Unique_Languages_@
@@ELSIF@@ @_Unique_Languages_@ = "C" or @_Unique_Languages_@ = "CPP" or @_Unique_Languages_@ = "Blackbox_C" @@END_IF@@
@@INLINE()()(; fi\n)@@ @@INLINE( )(\n )(\n)@@
if [ ! -d dataview/C ]; then mkdir dataview/C && mono $(shell which asn1.exe) -c -typePrefix asn1Scc -o dataview/C dataview/dataview-uniq.asn mkdir -p dataview/@_Lang_@
@@TABLE@@ PROJECT_CACHE=dataview/.cache asn2dataModel -o dataview/@_Lang_@ -to@_Lang_@ dataview/dataview-uniq.asn \
@_REPLACE(,/ ):CP_Files_@ @@TABLE@@
@@END_TABLE@@ @_REPLACE(,/ ):CP_Files_@
@@END_INLINE@@ @@END_TABLE@@
@@ELSE@@ @_Post_@
mkdir -p dataview/@_Unique_Languages_@ @@END_INLINE@@
asn2dataModel -o dataview/@_Unique_Languages_@ -to@_Unique_Languages_@ dataview/dataview-uniq.asn @@END_IF@@
@@END_IF@@
@@END_IF@@
@@END_TABLE@@ @@END_TABLE@@
@@-- Then symlink the files for each function @@-- Then symlink the files for each function
@@TABLE@@ @@TABLE@@
......
KAZOO=../../kazoo KAZOO=../../kazoo
all: test-parse all: test-parse
make -C output
cd output/concurrency_view && \ cd output/concurrency_view && \
ocarina -x main.aadl && \ ocarina -x main.aadl && \
make -f Makefile.taste make -f Makefile.taste
......
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