diff options
Diffstat (limited to 'examples/xsd2c/ex2/Makefile')
-rw-r--r-- | examples/xsd2c/ex2/Makefile | 37 |
1 files changed, 37 insertions, 0 deletions
diff --git a/examples/xsd2c/ex2/Makefile b/examples/xsd2c/ex2/Makefile new file mode 100644 index 0000000..027b36f --- /dev/null +++ b/examples/xsd2c/ex2/Makefile @@ -0,0 +1,37 @@ +######################################################### +# +# XSD2C Examles Makefile +# +######################################################### + +SHELL = bash +CC = gcc + + +VPATH = . ../ + +EXECNAME= ex2.exe +XSDFILE = ex2.xsd +EXSRC = ex2.c utils.c +GENSRC = Person_xsd.c Address_xsd.c + +EXOBJ = $(addsuffix .o, $(basename $(EXSRC))) +GENOBJ = $(addsuffix .o, $(basename $(GENSRC))) +OBJECTS = $(EXOBJ) $(GENOBJ) +XSD2C = ../../xsd2c + +$(EXECNAME): stubs $(GENSRC) $(OBJECTS) + $(CC) -g $(CFLAGS) -o $@ $(OBJECTS) $(CLIBS) + +CFLAGS = `xml2-config --cflags` +CLIBS = `xml2-config --libs` + +stubs: + $(XSD2C) -S $(XSDFILE) + +clean: + -@rm -f *.o + -@rm -f *_xsd.h + -@rm -f *_xsd.c + -@rm -f *~ + -@rm -f $(EXECNAME) |