summaryrefslogtreecommitdiff
path: root/dist/examples/cxx/tree/custom/wildcard/makefile
blob: 7473f00cc90b24e70b95530f472d3cd1f5d2df2c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
root := ../../../..

include $(root)/build/cxx/rules.make
include $(root)/build/xsd/tree-rules.make


override XSDFLAGS += --generate-inline --generate-ostream \
--generate-serialization --hxx-epilogue '\#include "wildcard-custom.hxx"'

ifneq ($(shell uname -o 2>&1),Msys)
override XSDFLAGS += --custom-type data=/data_base
else
# Prevent MSYS from converting / to Windows path.
override XSDFLAGS += --custom-type data=//data_base
endif


# Build.
#
driver: driver.o wildcard.o wildcard-custom.o

wildcard.o: wildcard.cxx wildcard.ixx wildcard.hxx wildcard-custom.hxx
driver.o: driver.cxx wildcard.ixx wildcard.hxx wildcard-custom.hxx
wildcard-custom.o: wildcard-custom.cxx wildcard.ixx wildcard.hxx wildcard-custom.hxx

wildcard.cxx wildcard.hxx wildcard.ixx: wildcard.xsd


# Test
#
.PHONY: test
test: driver wildcard.xml
	./driver wildcard.xml


# Clean.
#
.PHONY: clean
clean:
	rm -f wildcard-custom.o wildcard.o wildcard.?xx driver.o driver