blob: 07d02f515eaf2fec77e022dcbe6a735097d9b4ff [file] [log] [blame]
Daniel Veillard01791d51998-07-24 19:24:09 +00001## Process this file with automake to produce Makefile.in
2
Daniel Veillard19b858c1999-02-06 18:12:01 +00003SUBDIRS = doc
4
Daniel Veillard14fff061999-06-22 21:49:07 +00005INCLUDES = -I@srcdir@ @CORBA_CFLAGS@ $(VERSION_FLAGS)
6
7VERSION_FLAGS = -DLIBXML_VERSION=\"@LIBXML_VERSION@\"
Daniel Veillard27fb0751998-10-17 06:47:46 +00008
Daniel Veillardbe70ff71999-07-05 16:50:46 +00009noinst_PROGRAMS=tester testSAX testHTML
Daniel Veillard01791d51998-07-24 19:24:09 +000010
Daniel Veillarda6e1d121998-10-04 14:41:05 +000011bin_SCRIPTS=xml-config
12
Daniel Veillard0dc897e1998-07-26 04:12:22 +000013lib_LTLIBRARIES = libxml.la
Daniel Veillard01791d51998-07-24 19:24:09 +000014
Daniel Veillard14fff061999-06-22 21:49:07 +000015libxml_la_LDFLAGS = -version-info @LIBXML_VERSION_INFO@
16
Daniel Veillard0dc897e1998-07-26 04:12:22 +000017libxml_la_SOURCES = \
Daniel Veillard260a68f1998-08-13 03:39:55 +000018 SAX.c \
19 entities.c \
Daniel Veillard891e4041998-10-19 00:43:02 +000020 encoding.c \
Daniel Veillard260a68f1998-08-13 03:39:55 +000021 error.c \
22 parser.c \
Daniel Veillardbe70ff71999-07-05 16:50:46 +000023 HTMLparser.c \
Daniel Veillardbaf4cd51998-10-27 22:56:57 +000024 debugXML.c \
Daniel Veillard39a1f9a1999-01-17 19:11:59 +000025 tree.c \
26 valid.c
Daniel Veillard260a68f1998-08-13 03:39:55 +000027
Tom Tromeyc19653d1998-08-14 01:22:43 +000028xmlincdir = $(includedir)/gnome-xml
29xmlinc_HEADERS = \
Daniel Veillard260a68f1998-08-13 03:39:55 +000030 entities.h \
Daniel Veillard891e4041998-10-19 00:43:02 +000031 encoding.h \
Daniel Veillard260a68f1998-08-13 03:39:55 +000032 parser.h \
Daniel Veillard35925471999-02-25 08:46:07 +000033 parserInternals.h \
Daniel Veillardbaf4cd51998-10-27 22:56:57 +000034 debugXML.h \
Daniel Veillardd109e371999-03-05 06:26:45 +000035 xml-error.h \
Daniel Veillard39a1f9a1999-01-17 19:11:59 +000036 tree.h \
Daniel Veillard14fff061999-06-22 21:49:07 +000037 xmlIO.h \
Daniel Veillard39a1f9a1999-01-17 19:11:59 +000038 valid.h
Daniel Veillard01791d51998-07-24 19:24:09 +000039
Daniel Veillard0dc897e1998-07-26 04:12:22 +000040DEPS = $(top_builddir)/libxml.la
41LDADDS = $(top_builddir)/libxml.la @Z_LIBS@
Daniel Veillard01791d51998-07-24 19:24:09 +000042
43tester_SOURCES=tester.c
44tester_LDFLAGS =
45tester_DEPENDENCIES = $(DEPS)
46tester_LDADD= $(LDADDS)
47
Daniel Veillard011b63c1999-06-02 17:44:04 +000048testSAX_SOURCES=testSAX.c
49testSAX_LDFLAGS =
50testSAX_DEPENDENCIES = $(DEPS)
51testSAX_LDADD= $(LDADDS)
52
Daniel Veillardbe70ff71999-07-05 16:50:46 +000053testHTML_SOURCES=testHTML.c
54testHTML_LDFLAGS =
55testHTML_DEPENDENCIES = $(DEPS)
56testHTML_LDADD= $(LDADDS)
57
Raja R Harinatha86c23e1999-03-05 22:14:01 +000058check-local: tests
59
Daniel Veillard011b63c1999-06-02 17:44:04 +000060testall : tests SVGtests SAXtests
61
Daniel Veillard01791d51998-07-24 19:24:09 +000062tests : tester
Daniel Veillard011b63c1999-06-02 17:44:04 +000063 @(DIR=`pwd`; cd $(srcdir) ; \
64 for i in test/* ; do \
Daniel Veillard01791d51998-07-24 19:24:09 +000065 if [ ! -d $$i ] ; then \
Daniel Veillard011b63c1999-06-02 17:44:04 +000066 if [ ! -f result/`basename $$i` ] ; then \
67 echo New test file `basename $$i` ; \
68 $$DIR/tester $$i > result/`basename $$i` ; \
Daniel Veillard01791d51998-07-24 19:24:09 +000069 else \
Daniel Veillard011b63c1999-06-02 17:44:04 +000070 echo Testing `basename $$i` ; \
71 $$DIR/tester $$i > result.`basename $$i` ; \
72 diff result/`basename $$i` result.`basename $$i` ; \
73 $$DIR/tester result.`basename $$i` > result2.`basename $$i` ; \
74 diff result.`basename $$i` result2.`basename $$i` ; \
75 rm result.`basename $$i` result2.`basename $$i` ; \
Daniel Veillard01791d51998-07-24 19:24:09 +000076 fi ; fi ; done)
77
Daniel Veillard011b63c1999-06-02 17:44:04 +000078SVGtests : tester
79 @(DIR=`pwd`; cd $(srcdir) ; \
80 for i in test/SVG/* ; do \
81 if [ ! -d $$i ] ; then \
82 if [ ! -f result/SVG/`basename $$i` ] ; then \
83 echo New test file `basename $$i` ; \
84 $$DIR/tester $$i > result/SVG/`basename $$i` ; \
85 else \
86 echo Testing `basename $$i` ; \
87 $$DIR/tester $$i > result.`basename $$i` ; \
88 diff result/SVG/`basename $$i` result.`basename $$i` ; \
89 $$DIR/tester result.`basename $$i` > result2.`basename $$i` ; \
90 diff result.`basename $$i` result2.`basename $$i` ; \
91 rm result.`basename $$i` result2.`basename $$i` ; \
92 fi ; fi ; done)
93
94SAXtests : testSAX
95 @(DIR=`pwd`; cd $(srcdir) ; \
96 for i in test/* ; do \
97 if [ ! -d $$i ] ; then \
98 if [ ! -f SAXresult/`basename $$i` ] ; then \
99 echo New test file `basename $$i` ; \
100 $$DIR/testSAX $$i > SAXresult/`basename $$i` ; \
101 else \
102 echo Testing `basename $$i` ; \
103 $$DIR/testSAX $$i > result.`basename $$i` ; \
104 diff SAXresult/`basename $$i` result.`basename $$i` ; \
105 rm result.`basename $$i` ; \
106 fi ; fi ; done)
107
108#tests : tester
109# @(for i in $(srcdir)/test/* ; do \
110# if [ ! -d $$i ] ; then \
111# j=`echo $$i | sed -e 's,^.*/,,'`; \
112# if [ ! -f $(srcdir)/result/$$j ] ; then \
113# echo New test file $$j ; \
114# ./tester $$i > $(srcdir)/result/$$j ; \
115# else \
116# echo Testing $$j ; \
117# ./tester $$i > result.$$j ; \
118# diff $(srcdir)/result/$$j result.$$j ; \
119# rm result.$$j ; \
120# fi ; fi ; done)
121
Arturo Espinosa15fe6e71998-09-07 17:27:57 +0000122## Put `exec' in the name because this should be installed by
123## `install-exec', not `install-data'.
124
125confexecdir=$(libdir)
126confexec_DATA = xmlConf.sh
127
Daniel Veillard011b63c1999-06-02 17:44:04 +0000128EXTRA_DIST = xmlConf.sh.in libxml.spec.in test result SAXresult
Arturo Espinosa15fe6e71998-09-07 17:27:57 +0000129
Michael Fulbright63dc42c1999-02-21 21:20:12 +0000130dist-hook:
131 cp libxml.spec $(distdir)
132
Arturo Espinosa15fe6e71998-09-07 17:27:57 +0000133## We create xmlConf.sh here and not from configure because we want
134## to get the paths expanded correctly. Macros like srcdir are given
135## the value NONE in configure if the user doesn't specify them (this
136## is an autoconf feature, not a bug).
137
138xmlConf.sh: xmlConf.sh.in Makefile
139## Use sed and then mv to avoid problems if the user interrupts.
Miguel de Icaza60681bd1998-09-30 19:28:59 +0000140 sed -e 's?\@XML_LIBDIR\@?$(XML_LIBDIR)?g' \
141 -e 's?\@XML_INCLUDEDIR\@?$(XML_INCLUDEDIR)?g' \
142 -e 's?\@XML_LIBS\@?$(XML_LIBS)?g' \
Arturo Espinosa15fe6e71998-09-07 17:27:57 +0000143 < $(srcdir)/xmlConf.sh.in > xmlConf.tmp \
144 && mv xmlConf.tmp xmlConf.sh