Bump version, add pkg-config support, version the schemas
[shibboleth/cpp-xmltooling.git] / Makefile.am
index de7dbe5..e04a6da 100644 (file)
@@ -2,35 +2,38 @@ AUTOMAKE_OPTIONS = foreign
 
 ACLOCAL_AMFLAGS = -I .
 
-EXTRA_DIST =
-       schemas \
-       cpp-xmltooling.sln \
-       libtool.m4 \
-       acx_pthread.m4 \
-       depcomp \
-       doxygen.cfg \
-       config_win32.h
+include doxygen.am
+
+MOSTLYCLEANFILES = $(DX_CLEANFILES)
 
 dist-hook:
        rm -rf `find $(distdir)/xmltoolingtest/data -name .svn`
-       rm -rf `find $(distdir)/schemas -name .svn`
-       rm -rf `find $(distdir)/schemas -name Makefile`
-
-
-SUBDIRS = schemas xmltooling xmltoolingtest
-
-all-local: xmltooling.spec pkginfo
-
-xmltooling.spec: xmltooling.spec.in Makefile
-       rm -f $@.tmp
-       sed < $< > $@.tmp \
-           -e 's:@-VERSION-@:${VERSION}:'
-       mv $@.tmp $@
-
-pkginfo: pkginfo.in Makefile
-       rm -f $@.tmp
-       sed < $< > $@.tmp \
-           -e 's:@-VERSION-@:${VERSION}:'
-       mv $@.tmp $@
-
-DISTCLEANFILES = xmltooling.spec pkginfo
+       rm -rf `find $(distdir)/doc/api -name .svn`
+
+
+SUBDIRS = doc schemas xmltooling xmltoolingtest
+
+if DX_COND_doc
+all-local: doxygen-doc
+else
+all-local:
+endif
+
+pkgconfigdir = $(libdir)/pkgconfig
+pkgconfig_DATA = xmltooling.pc
+
+GENFILES = xmltooling.spec xmltooling.pc pkginfo Portfile
+
+EXTRA_DIST = $(DX_CONFIG) \
+        cpp-xmltooling.sln \
+        acx_pthread.m4 \
+        acinclude.m4 \
+        ax_create_pkgconfig_info.m4 \
+        libtool.m4 \
+        doxygen.m4 \
+        depcomp \
+        config_win32.h \
+        $(GENFILES) \
+        $(GENFILES:%=%.in) \
+        depend \
+        postinstall