Commit 4e93667b authored by Maxime Perrotin's avatar Maxime Perrotin
Browse files

Update few templates for air builds

parent 89d0ec7d
...@@ -20,6 +20,7 @@ all: ...@@ -20,6 +20,7 @@ all:
@_LOWER:Node_Names_@_native @_LOWER:Node_Names_@_native
@@END_TABLE@@ @@END_TABLE@@
@@END_INLINE@@ @@END_INLINE@@
ocarina -x main.aadl
@@TABLE@@ @@TABLE@@
make -C @_Node_Names_@ -f Makefile.@_Node_Names_@ make -C @_Node_Names_@ -f Makefile.@_Node_Names_@
@@END_TABLE@@ @@END_TABLE@@
...@@ -30,6 +31,7 @@ rtems_ada: ...@@ -30,6 +31,7 @@ rtems_ada:
@_LOWER:Node_Names_@_rtems_ada @_LOWER:Node_Names_@_rtems_ada
@@END_TABLE@@ @@END_TABLE@@
@@END_INLINE@@ @@END_INLINE@@
ocarina -x main.aadl
@@TABLE@@ @@TABLE@@
make -C @_Node_Names_@ -f Makefile.@_Node_Names_@ debug_rtems_leon3_with_ada make -C @_Node_Names_@ -f Makefile.@_Node_Names_@ debug_rtems_leon3_with_ada
@@END_TABLE@@ @@END_TABLE@@
...@@ -40,6 +42,7 @@ air: ...@@ -40,6 +42,7 @@ air:
@_LOWER:Node_Names_@_air @_LOWER:Node_Names_@_air
@@END_TABLE@@ @@END_TABLE@@
@@END_INLINE@@ @@END_INLINE@@
ocarina -x main.aadl
@@TABLE@@ @@TABLE@@
# generate the xml file for AIR and call AIR's configure script # generate the xml file for AIR and call AIR's configure script
ocarina -aadlv2 -v -disable-annexes=emv2 -g air_configuration \ ocarina -aadlv2 -v -disable-annexes=emv2 -g air_configuration \
...@@ -49,9 +52,15 @@ air: ...@@ -49,9 +52,15 @@ air:
taste_properties.aadl base_types.aadl \ taste_properties.aadl base_types.aadl \
../../DataView.aadl ../../InterfaceView.aadl ../../DeploymentView.aadl \ ../../DataView.aadl ../../InterfaceView.aadl ../../DeploymentView.aadl \
../../../common/ocarina_components.aadl && \ ../../../common/ocarina_components.aadl && \
cd deploymentview_final && configure cd deploymentview_final && rm -f Makefile && (configure --keep-files-silent)
@echo "XML generated, AIR configuration done, building..." @echo "XML generated, AIR configuration done, building..."
make -C @_Node_Names_@ -f Makefile.@_Node_Names_@ air make -C @_Node_Names_@ -f Makefile.@_Node_Names_@ air
@@END_TABLE@@ @@END_TABLE@@
@_Nodes_@ @_Nodes_@
clean:
@@TABLE@@
make -C @_Node_Names_@ -f Makefile.@_Node_Names_@ clean
rm -rf *_adainit deploymentview_final
@@END_TABLE@@
...@@ -20,10 +20,17 @@ debug_rtems_leon3_with_ada: ...@@ -20,10 +20,17 @@ debug_rtems_leon3_with_ada:
air: air:
@@TABLE@@ @@TABLE@@
gprbuild -v --config=air.cgpr -P @_LOWER:Partition_Names_@_air.gpr -XCFG="Debug" -cargs:C -DSTATIC="" gprbuild -c -v --config=air.cgpr -P @_LOWER:Partition_Names_@_air.gpr -XCFG="Debug" -cargs:C -DSTATIC=""
cp ../deploymentview_final/@_LOWER:Partition_Names_@/linkcmds.inc @_LOWER:Partition_Names_@_obj/
gprbuild -l -v --config=air.cgpr -P @_LOWER:Partition_Names_@_air.gpr -XCFG="Debug" -cargs:C -DSTATIC=""
@@END_TABLE@@ @@END_TABLE@@
release_native: release_native:
@@TABLE@@ @@TABLE@@
gprbuild -p -P @_LOWER:Partition_Names_@.gpr -XCFG="Release" -cargs:C -DSTATIC="" gprbuild -p -P @_LOWER:Partition_Names_@.gpr -XCFG="Release" -cargs:C -DSTATIC=""
@@END_TABLE@@ @@END_TABLE@@
clean:
@@TABLE@@
rm -rf @_LOWER:Partition_Names_@_obj
@@END_TABLE@@
...@@ -10,18 +10,20 @@ ...@@ -10,18 +10,20 @@
MAKEFILE_PATH := $(abspath $(lastword $(MAKEFILE_LIST))) MAKEFILE_PATH := $(abspath $(lastword $(MAKEFILE_LIST)))
OUTDIR := $(dir $(MAKEFILE_PATH)) OUTDIR := $(dir $(MAKEFILE_PATH))
export PROJECT_CACHE=${HOME}/.taste_AST_cache
all: build-native all: build-native
dataview : dataview/dataview-uniq.asn dataview : dataview/dataview-uniq.asn
build-native: dataview build-native: dataview
cd build && ocarina -x main.aadl && make -f Makefile.taste make -C build -f Makefile.taste
build-rtems-ada: dataview build-rtems-ada: dataview
cd build && ocarina -x main.aadl && make -f Makefile.taste rtems_ada make -C build -f Makefile.taste rtems_ada
air: dataview air: dataview
cd build && ocarina -x main.aadl && make -f Makefile.taste air make -C build -f Makefile.taste air
@@INLINE(dataview/dataview-uniq.asn:)( )(\n)@@ @@INLINE(dataview/dataview-uniq.asn:)( )(\n)@@
@@TABLE@@ @@TABLE@@
...@@ -49,15 +51,15 @@ air: dataview ...@@ -49,15 +51,15 @@ air: dataview
@@END_INLINE@@ @@END_INLINE@@
@@-- Generate DataView.aadl in AADLV1 as this is needed by aadl2glueC @@-- Generate DataView.aadl in AADLV1 as this is needed by aadl2glueC
PROJECT_CACHE=${HOME}/.taste_AST_cache asn2aadlPlus dataview/dataview-uniq.asn dataview/dataview_aadlv1.aadl asn2aadlPlus dataview/dataview-uniq.asn dataview/dataview_aadlv1.aadl
@@-- For each function generate the glue code from DMT based on the dataview @@-- For each function generate the glue code from DMT based on the dataview
@@TABLE@@ @@TABLE@@
@@IF@@ not @_Is_Type_@ @@IF@@ not @_Is_Type_@
PROJECT_CACHE=${HOME}/.taste_AST_cache aadl2glueC -o @_LOWER:Function_Names_@/@_Language_@/wrappers dataview/dataview_aadlv1.aadl @_LOWER:Function_Names_@/@_Language_@/wrappers/@_LOWER:Function_Names_@_mini_cv.aadl aadl2glueC -o @_LOWER:Function_Names_@/@_Language_@/wrappers dataview/dataview_aadlv1.aadl @_LOWER:Function_Names_@/@_Language_@/wrappers/@_LOWER:Function_Names_@_mini_cv.aadl
@@END_IF@@ @@END_IF@@
@@END_TABLE@@ @@END_TABLE@@
@@-- Then generate Dataviews once per target language - first for C, it is needed in any case @@-- Then generate Dataviews once per target language - first for C, it is needed in any case
mkdir -p dataview/C && PROJECT_CACHE=${HOME}/.taste_AST_cache asn2dataModel -o dataview/C -toC dataview/dataview-uniq.asn \ mkdir -p dataview/C && asn2dataModel -o dataview/C -toC dataview/dataview-uniq.asn \
@@INLINE( )( \\\n )(\n)@@ @@INLINE( )( \\\n )(\n)@@
@@TABLE@@ @@TABLE@@
@_REPLACE(,/ ):CP_Files_@ @_REPLACE(,/ ):CP_Files_@
...@@ -77,7 +79,7 @@ air: dataview ...@@ -77,7 +79,7 @@ air: dataview
@@IF@@ Enable=TRUE @@IF@@ Enable=TRUE
@@INLINE( )(\n )(\n)@@ @@INLINE( )(\n )(\n)@@
mkdir -p dataview/@_Lang_@ mkdir -p dataview/@_Lang_@
PROJECT_CACHE=${HOME}/.taste_AST_cache asn2dataModel -o dataview/@_Lang_@ -to@_Lang_@ dataview/dataview-uniq.asn \ asn2dataModel -o dataview/@_Lang_@ -to@_Lang_@ dataview/dataview-uniq.asn \
@@INLINE( )( \\\n )(\n )@@ @@INLINE( )( \\\n )(\n )@@
@@TABLE@@ @@TABLE@@
@_REPLACE(,/ ):CP_Files_@ @_REPLACE(,/ ):CP_Files_@
...@@ -87,7 +89,7 @@ air: dataview ...@@ -87,7 +89,7 @@ air: dataview
@@END_IF@@ @@END_IF@@
@@END_TABLE@@ @@END_TABLE@@
@@IF@@ @_Need_Ada_@=TRUE @@IF@@ @_Need_Ada_@=TRUE
mkdir -p dataview/Ada && PROJECT_CACHE=${HOME}/.taste_AST_cache asn2dataModel -o dataview/Ada -toAda dataview/dataview-uniq.asn \ mkdir -p dataview/Ada && asn2dataModel -o dataview/Ada -toAda dataview/dataview-uniq.asn \
@@INLINE( )( \\\n )(\n)@@ @@INLINE( )( \\\n )(\n)@@
@@TABLE@@ @@TABLE@@
@_REPLACE(,/ ):CP_Files_@ @_REPLACE(,/ ):CP_Files_@
...@@ -98,7 +100,7 @@ air: dataview ...@@ -98,7 +100,7 @@ air: dataview
@@END_IF@@ @@END_IF@@
cp $(shell taste-config --prefix)/share/AutoGUI/debug_messages.? dataview/C cp $(shell taste-config --prefix)/share/AutoGUI/debug_messages.? dataview/C
cp $(shell taste-config --prefix)/share/AutoGUI/timeInMS.? dataview/C cp $(shell taste-config --prefix)/share/AutoGUI/timeInMS.? dataview/C
cd dataview/C && PROJECT_CACHE=${HOME}/.taste_AST_cache msgPrinter ../dataview-uniq.asn && PROJECT_CACHE=${HOME}/.taste_AST_cache msgPrinterASN1 ../dataview-uniq.asn cd dataview/C && msgPrinter ../dataview-uniq.asn && msgPrinterASN1 ../dataview-uniq.asn
@@-- Then symlink the files for each function @@-- Then symlink the files for each function
@@TABLE@@ @@TABLE@@
@@IF@@ @_Language_@ = "SDL" @@IF@@ @_Language_@ = "SDL"
...@@ -124,5 +126,6 @@ compile-all-linux: dataviews function-instances-linux ...@@ -124,5 +126,6 @@ compile-all-linux: dataviews function-instances-linux
clean: clean:
rm -rf binaries/* rm -rf binaries/*
make -C build -f Makefile.taste clean
.PHONY: clean compile-all-linux function-instances-linux function-types-linux build-native dataview build-rtems-ada .PHONY: clean compile-all-linux function-instances-linux function-types-linux build-native dataview build-rtems-ada
Supports Markdown
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