summaryrefslogtreecommitdiff
path: root/dist/examples/cxx/tree/order
diff options
context:
space:
mode:
Diffstat (limited to 'dist/examples/cxx/tree/order')
-rw-r--r--dist/examples/cxx/tree/order/element/makefile31
-rw-r--r--dist/examples/cxx/tree/order/makefile11
-rw-r--r--dist/examples/cxx/tree/order/mixed/makefile32
3 files changed, 74 insertions, 0 deletions
diff --git a/dist/examples/cxx/tree/order/element/makefile b/dist/examples/cxx/tree/order/element/makefile
new file mode 100644
index 0000000..31f5ec5
--- /dev/null
+++ b/dist/examples/cxx/tree/order/element/makefile
@@ -0,0 +1,31 @@
+root := ../../../..
+
+include $(root)/build/cxx/rules.make
+include $(root)/build/xsd/tree-rules.make
+
+
+override XSDFLAGS += --generate-serialization --generate-wildcard --ordered-type batch
+
+
+# Build.
+#
+driver: driver.o transactions.o
+
+transactions.o: transactions.cxx transactions.hxx
+driver.o: driver.cxx transactions.hxx
+
+transactions.cxx transactions.hxx: transactions.xsd
+
+
+# Test
+#
+.PHONY: test
+test: driver transactions.xml
+ ./driver transactions.xml
+
+
+# Clean.
+#
+.PHONY: clean
+clean:
+ rm -f transactions.o transactions.?xx driver.o driver
diff --git a/dist/examples/cxx/tree/order/makefile b/dist/examples/cxx/tree/order/makefile
new file mode 100644
index 0000000..2713b6e
--- /dev/null
+++ b/dist/examples/cxx/tree/order/makefile
@@ -0,0 +1,11 @@
+dirs := element mixed
+
+.PHONY: all $(dirs)
+
+all: $(dirs)
+
+$(dirs):
+ @$(MAKE) -C $@ $(MAKECMDGOALS)
+
+makefile: ;
+% :: $(dirs) ;
diff --git a/dist/examples/cxx/tree/order/mixed/makefile b/dist/examples/cxx/tree/order/mixed/makefile
new file mode 100644
index 0000000..b7929d9
--- /dev/null
+++ b/dist/examples/cxx/tree/order/mixed/makefile
@@ -0,0 +1,32 @@
+root := ../../../..
+
+include $(root)/build/cxx/rules.make
+include $(root)/build/xsd/tree-rules.make
+
+
+override XSDFLAGS += --generate-serialization --ordered-type-mixed
+
+
+# Build.
+#
+driver: driver.o text.o
+
+text.o: text.cxx text.hxx
+driver.o: driver.cxx text.hxx
+
+text.cxx text.hxx: text.xsd
+
+
+# Test
+#
+.PHONY: test
+test: driver text.xml
+ ./driver text.xml
+
+
+# Clean.
+#
+.PHONY: clean
+clean:
+ rm -f text.o text.?xx driver.o driver
+