Commit 5bc16717 authored by Maxime Perrotin's avatar Maxime Perrotin
Browse files

Update makefiles to build properly rtems systems with ada

parent e135fc92
......@@ -6,10 +6,22 @@
@@-- @_CPU_Name_@, _Platform_@, _Classifier_@, _Ada_Runtime_@ : Info about CPU
@@-- In standard TASTE systems there is only one partition per node
# Build of node @_Node_Name_@ for @_CPU_Platform_@
# (rule generated by templates/concurrency_view/aadl_4_makefile/node.tmplt)
@@IF@@ @_CPU_Platform_@ = PLATFORM_LEON_RTEMS_POSIX
@@INLINE@@
@_LOWER:Node_Name_@_@_CPU_Name_@:
@@TABLE@@
@_Partition_Names_@_rtems_ada
@@END_TABLE@@
DriversConfig/drivers_config.h
@@END_INLINE@@
@@ELSE@@
@_LOWER:Node_Name_@_@_CPU_Name_@: @_LOWER:REPLACE_ALL(,/):Partition_Names_@ DriversConfig/drivers_config.h
@@END_IF@@
make -j -C @_Node_Name_@ -f Makefile.@_Node_Name_@
# Build of node @_Node_Name_@ for RTEMS
# Force build of node @_Node_Name_@ for RTEMS
# (rule generated by templates/concurrency_view/aadl_4_makefile/node.tmplt)
@@INLINE@@
@_LOWER:Node_Name_@_rtems_ada:
@@TABLE@@
......@@ -17,7 +29,8 @@
@@END_TABLE@@
@@END_INLINE@@
# Build of node @_Node_Name_@ for AIR
# Force build of node @_Node_Name_@ for AIR
# (rule generated by templates/concurrency_view/aadl_4_makefile/node.tmplt)
@@INLINE@@
@_LOWER:Node_Name_@_air:
@@TABLE@@
......
......@@ -22,6 +22,7 @@
@@-- @_Thread_Src_Port_@ : Vector tag : connection port name (source)
@@-- @_Thread_Dst_Port_@ : Vector tag : connection port name (dest)
# Build of partition @_Name_@ (common to all targets)
# (rule generated by templates/concurrency_view/aadl_4_makefile/partition.tmplt)
@@INLINE()( )(\n)@@
@_LOWER:Name_@:
@@TABLE@@
......@@ -29,31 +30,30 @@
@@END_TABLE@@
@@END_INLINE@@
# Build of partition @_Name_@ for RTEMS
# Build of partition @_Name_@ for RTEMS (generate adainit)
# (rule generated by templates/concurrency_view/aadl_4_makefile/partition.tmplt)
@_LOWER:Name_@_rtems_ada : @_LOWER:Name_@
@@-- On RTEMS if using POHIC we need to have adainit created for Ada functions
@@--@@IF@@ @_CPU_Platform_@ /= PLATFORM_NATIVE
mkdir -p @_LOWER:Name_@_adainit && \
@@INLINE( echo ')()()@@
@@TABLE@@
@@IF@@ @_LOWER:Block_Languages_@ = sdl or @_LOWER:Block_Languages_@ = ada
with @_CAPITALIZE:Block_Names_@;
@@END_IF@@
@@END_TABLE@@
package adainit is end adainit;' >@_LOWER:Name_@_adainit/tasteada.ads && \
@@TABLE@@
@@IF@@ @_LOWER:Block_Languages_@ = sdl or @_LOWER:Block_Languages_@ = ada
with @_CAPITALIZE:Block_Names_@;
@@END_IF@@
@@END_TABLE@@
package adainit is end adainit;' >@_LOWER:Name_@_adainit/tasteada.ads && \
@@END_INLINE@@
cd @_LOWER:Name_@_adainit && \
@@INLINE( )(:)( \\)@@
ADA_INCLUDE_PATH=../../dataview/Ada
@@TABLE'TERSE@@
@@IF@@ @_LOWER:Block_Languages_@ = sdl
../../@_LOWER:Block_Names_@/SDL/code
@@ELSIF@@ @_LOWER:Block_Languages_@ = ada
../../@_LOWER:Block_Names_@/Ada/src
@@END_IF@@
@@END_TABLE@@
ADA_INCLUDE_PATH=../../dataview/Ada
@@TABLE'TERSE@@
@@IF@@ @_LOWER:Block_Languages_@ = sdl
../../@_LOWER:Block_Names_@/SDL/code
@@ELSIF@@ @_LOWER:Block_Languages_@ = ada
../../@_LOWER:Block_Names_@/Ada/src
@@END_IF@@
@@END_TABLE@@
@@END_INLINE@@
sparc-rtems5-gnatmake -c tasteada.ads && sparc-rtems5-gnatbind -t -n tasteada.ali -o ada-start.adb && mkdir -p ../@_LOWER:Node_Name_@/ada_code_startup && mv ada-start.* ../@_LOWER:Node_Name_@/ada_code_startup
@@--@@END_IF@@
@_Blocks_@
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