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:
@_LOWER:Node_Names_@_native
@@END_TABLE@@
@@END_INLINE@@
ocarina -x main.aadl
@@TABLE@@
make -C @_Node_Names_@ -f Makefile.@_Node_Names_@
@@END_TABLE@@
......@@ -30,6 +31,7 @@ rtems_ada:
@_LOWER:Node_Names_@_rtems_ada
@@END_TABLE@@
@@END_INLINE@@
ocarina -x main.aadl
@@TABLE@@
make -C @_Node_Names_@ -f Makefile.@_Node_Names_@ debug_rtems_leon3_with_ada
@@END_TABLE@@
......@@ -40,6 +42,7 @@ air:
@_LOWER:Node_Names_@_air
@@END_TABLE@@
@@END_INLINE@@
ocarina -x main.aadl
@@TABLE@@
# generate the xml file for AIR and call AIR's configure script
ocarina -aadlv2 -v -disable-annexes=emv2 -g air_configuration \
......@@ -49,9 +52,15 @@ air:
taste_properties.aadl base_types.aadl \
../../DataView.aadl ../../InterfaceView.aadl ../../DeploymentView.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..."
make -C @_Node_Names_@ -f Makefile.@_Node_Names_@ air
@@END_TABLE@@
@_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:
air:
@@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@@
release_native:
@@TABLE@@
gprbuild -p -P @_LOWER:Partition_Names_@.gpr -XCFG="Release" -cargs:C -DSTATIC=""
@@END_TABLE@@
clean:
@@TABLE@@
rm -rf @_LOWER:Partition_Names_@_obj
@@END_TABLE@@
......@@ -10,18 +10,20 @@
MAKEFILE_PATH := $(abspath $(lastword $(MAKEFILE_LIST)))
OUTDIR := $(dir $(MAKEFILE_PATH))
export PROJECT_CACHE=${HOME}/.taste_AST_cache
all: build-native
dataview : dataview/dataview-uniq.asn
build-native: dataview
cd build && ocarina -x main.aadl && make -f Makefile.taste
make -C build -f Makefile.taste
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
cd build && ocarina -x main.aadl && make -f Makefile.taste air
make -C build -f Makefile.taste air
@@INLINE(dataview/dataview-uniq.asn:)( )(\n)@@
@@TABLE@@
......@@ -49,15 +51,15 @@ air: dataview
@@END_INLINE@@
@@-- 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
@@TABLE@@
@@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_TABLE@@
@@-- 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)@@
@@TABLE@@
@_REPLACE(,/ ):CP_Files_@
......@@ -77,7 +79,7 @@ air: dataview
@@IF@@ Enable=TRUE
@@INLINE( )(\n )(\n)@@
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 )@@
@@TABLE@@
@_REPLACE(,/ ):CP_Files_@
......@@ -87,7 +89,7 @@ air: dataview
@@END_IF@@
@@END_TABLE@@
@@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)@@
@@TABLE@@
@_REPLACE(,/ ):CP_Files_@
......@@ -98,7 +100,7 @@ air: dataview
@@END_IF@@
cp $(shell taste-config --prefix)/share/AutoGUI/debug_messages.? 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
@@TABLE@@
@@IF@@ @_Language_@ = "SDL"
......@@ -124,5 +126,6 @@ compile-all-linux: dataviews function-instances-linux
clean:
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
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