[PATCH] build: fix make dist and make rpm

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: "Fabio M. Di Nitto" <fdinitto@xxxxxxxxxx>

do some cleanup around to include all files that need to be shipped
and honor conditional builds properly

Signed-off-by: Fabio M. Di Nitto <fdinitto@xxxxxxxxxx>
---
 Makefile.am      |   28 ++--------------------------
 conf/Makefile.am |   39 +++++++++++++++++++++++++++++++++------
 corosync.spec.in |    5 +++++
 man/Makefile.am  |   14 ++++++++------
 4 files changed, 48 insertions(+), 38 deletions(-)

diff --git a/Makefile.am b/Makefile.am
index 5b882a7..178b34d 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -33,14 +33,11 @@ SPEC			= $(PACKAGE_NAME).spec
 
 TARFILE			= $(PACKAGE_NAME)-$(VERSION).tar.gz
 
-EXTRA_DIST		= autogen.sh conf/corosync.conf.example $(SPEC).in \
+EXTRA_DIST		= autogen.sh $(SPEC).in \
 			  build-aux/git-version-gen \
 			  build-aux/gitlog-to-changelog \
 			  build-aux/release.mk \
-			  conf/lenses/tests/test_corosync.aug \
-			  conf/lenses/corosync.aug \
-			  conf/corosync.conf.example.udpu \
-			  .version conf/corosync.xml.example
+			  .version
 
 AUTOMAKE_OPTIONS	= foreign
 
@@ -50,27 +47,6 @@ MAINTAINERCLEANFILES	= Makefile.in aclocal.m4 configure depcomp \
 
 dist_doc_DATA		= LICENSE INSTALL README.recovery SECURITY TODO AUTHORS
 
-corosysconfdir		= ${COROSYSCONFDIR}
-
-corosysconf_DATA	= conf/corosync.conf.example \
-			  conf/corosync.conf.example.udpu
-
-if INSTALL_AUGEAS
-corolensdir		= ${datadir}/augeas/lenses
-corolens_DATA		= conf/lenses/corosync.aug
-
-corolenstestdir		= ${corolensdir}/tests
-corolenstest_DATA	= conf/lenses/tests/test_corosync.aug
-endif
-
-if INSTALL_XMLCONF
-corosysxmlconfdir	= ${COROSYSCONFDIR}
-corosysxmlconf_DATA	= conf/corosync.xml.example
-
-corosysxmlxsltdir	= ${datadir}/corosync
-corosysxmlxslt_DATA	= conf/xml2conf.xsl
-endif
-
 SUBDIRS			= include lib exec tools test cts pkgconfig \
 			  man init conf
 
diff --git a/conf/Makefile.am b/conf/Makefile.am
index 3d7adcc..69f7ff9 100644
--- a/conf/Makefile.am
+++ b/conf/Makefile.am
@@ -29,16 +29,43 @@
 # ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
 # THE POSSIBILITY OF SUCH DAMAGE.
 
-EXTRA_DIST     = COROSYNC-MIB.txt corosync-signals.conf
-
 MAINTAINERCLEANFILES    = Makefile.in
 
+EXTRA_DIST		= COROSYNC-MIB.txt corosync-signals.conf \
+			  corosync.conf.example \
+			  corosync.conf.example.udpu \
+			  corosync.xml.example \
+			  xml2conf.xsl \
+			  lenses/corosync.aug \
+			  lenses/tests/test_corosync.aug
+
+corosysconfdir		= ${COROSYSCONFDIR}
+
+corosysconf_DATA	= corosync.conf.example \
+			  corosync.conf.example.udpu
+
+if INSTALL_AUGEAS
+corolensdir		= ${datadir}/augeas/lenses
+corolens_DATA		= lenses/corosync.aug
+
+corolenstestdir		= ${corolensdir}/tests
+corolenstest_DATA	= lenses/tests/test_corosync.aug
+endif
+
+if INSTALL_XMLCONF
+corosysxmlconfdir	= ${COROSYSCONFDIR}
+corosysxmlconf_DATA	= corosync.xml.example
+
+corosysxmlxsltdir	= ${datadir}/corosync
+corosysxmlxslt_DATA	= xml2conf.xsl
+endif
+
 if INSTALL_MIB
-mibdir = $(datadir)/snmp/mibs
-mib_DATA = COROSYNC-MIB.txt
+mibdir			= $(datadir)/snmp/mibs
+mib_DATA		= COROSYNC-MIB.txt
 endif
 
 if INSTALL_DBUSCONF
-dbusdir = $(sysconfdir)/dbus-1/system.d
-dbus_DATA = corosync-signals.conf
+dbusdir			= $(sysconfdir)/dbus-1/system.d
+dbus_DATA		= corosync-signals.conf
 endif
diff --git a/corosync.spec.in b/corosync.spec.in
index 2b78f2f..9341636 100644
--- a/corosync.spec.in
+++ b/corosync.spec.in
@@ -155,6 +155,11 @@ fi
 %{_bindir}/corosync-blackbox
 %if %{with xmlconf}
 %{_bindir}/corosync-xmlproc
+%config(noreplace) %{_sysconfdir}/corosync/corosync.xml.example
+%dir %{_datadir}/corosync
+%dir %{_datadir}/corosync/xml2conf.xsl
+%{_mandir}/man8/corosync-xmlproc.8*
+%{_mandir}/man5/corosync.xml.5*
 %endif
 %dir %{_sysconfdir}/corosync
 %dir %{_sysconfdir}/corosync/uidgid.d
diff --git a/man/Makefile.am b/man/Makefile.am
index 3ce859e..480d8b3 100644
--- a/man/Makefile.am
+++ b/man/Makefile.am
@@ -34,7 +34,13 @@
 
 MAINTAINERCLEANFILES	= Makefile.in
 
-EXTRA_DIST		= index.html
+xml_man			= corosync-xmlproc.8 \
+			  corosync.xml.5
+
+INDEX_HTML		= index.html
+
+EXTRA_DIST		= $(INDEX_HTML) \
+			  $(xml_man)
 
 dist_man_MANS = \
 	corosync.conf.5 \
@@ -114,17 +120,13 @@ dist_man_MANS = \
 	sam_warn_signal_set.3
 
 if INSTALL_XMLCONF
-dist_man_MANS += \
-	corosync-xmlproc.8 \
-	corosync.xml.5
+dist_man_MANS += $(xml_man)
 endif
 
 if BUILD_HTML_DOCS
 
 HTML_DOCS = $(dist_man_MANS:%=%.html)
 
-INDEX_HTML = index.html
-
 %.html: %
 	$(GROFF) -mandoc -Thtml $^ > $@
 
-- 
1.7.7.6

_______________________________________________
discuss mailing list
discuss@xxxxxxxxxxxx
http://lists.corosync.org/mailman/listinfo/discuss


[Index of Archives]     [Linux Clusters]     [Corosync Project]     [Linux USB Devel]     [Linux Audio Users]     [Photo]     [Yosemite News]    [Yosemite Photos]    [Linux Kernel]     [Linux SCSI]     [X.Org]

  Powered by Linux