From dba1b0f45e6ebbb459887a4942a53cd3e05e4ffe Mon Sep 17 00:00:00 2001 From: randomdan Date: Mon, 2 Jun 2014 10:38:29 +0000 Subject: Split out ICE support from project jam file, add support for slicer --- slice.jam | 39 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) create mode 100644 slice.jam (limited to 'slice.jam') diff --git a/slice.jam b/slice.jam new file mode 100644 index 0000000..5c7fc83 --- /dev/null +++ b/slice.jam @@ -0,0 +1,39 @@ +import type : register ; +import generators : register-standard ; +import type ; +import feature : feature ; +import scanner ; + +type.register SLICE : ice ; + +feature slicer : no yes : propagated ; + +class slice-scanner : common-scanner +{ + rule pattern ( ) + { + return "^[ \t]*#[ \t]*include[ ]*[<\"]([^>\"]*)[>\"]" ; + } +} + +scanner.register slice-scanner : include ; + +type.set-scanner SLICE : slice-scanner ; + +generators.register-standard slice.slice2cpp : SLICE : CPP H : no ; +generators.register-standard slice.slicer : SLICE : CPP H : yes ; + +actions slice.slice2cpp +{ + slice2cpp --checksum --output-dir $(1[1]:D) $(2) +} + +actions slice.slicer +{ + slice2cpp --checksum --output-dir $(1[1]:D) $(2) + slicer $(2) $(1[1]) +} + +IMPORT $(__name__) : slice.slice2cpp : : slice.slice2cpp ; +IMPORT $(__name__) : slice.slicer : : slice.slicer ; + -- cgit v1.2.3