From: Loic Dachary Date: Thu, 19 Jun 2014 07:54:32 +0000 (+0200) Subject: autotools: avoid check_SCRIPTS duplication X-Git-Tag: v0.83~74^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=741ad3ff3b1949492729ac5f7bfcc42bdcd6df5a;p=ceph.git autotools: avoid check_SCRIPTS duplication The check_SCRIPTS content must be added to EXTRA_DIST, otherwise it will not be included by make dist and it won't be possible to run make check successfully. One solution would be to add $(check_SCRIPTS) to EXTRA_DIST to avoid duplication and help with long term maintenance. However, $(srcdir) is not supported in the content of the check_SCRIPTS variable. A GNU Make variable substitution (patsubst) is used to prepend $(srcdir) to each script, only when used in the EXTRA_DIST variable. Signed-off-by: Loic Dachary --- diff --git a/src/Makefile.am b/src/Makefile.am index 3501a7c6b0bc..9bbe667ced01 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -164,7 +164,6 @@ EXTRA_DIST += \ $(srcdir)/.git_version \ $(srcdir)/ceph-rbdnamer \ $(srcdir)/test/encoding/readable.sh \ - $(srcdir)/test/encoding/check-generated.sh \ $(srcdir)/upstart/ceph-all.conf \ $(srcdir)/upstart/ceph-mon.conf \ $(srcdir)/upstart/ceph-mon-all.conf \ @@ -190,7 +189,6 @@ EXTRA_DIST += \ ceph-crush-location \ mount.fuse.ceph \ rbdmap \ - unittest_bufferlist.sh \ yasm-wrapper EXTRA_DIST += \ diff --git a/src/test/Makefile.am b/src/test/Makefile.am index 6aabe14f5cf7..3669c52c2d0e 100644 --- a/src/test/Makefile.am +++ b/src/test/Makefile.am @@ -247,16 +247,7 @@ EXTRA_DIST += \ $(srcdir)/test/mon/mon-test-helpers.sh \ $(srcdir)/test/osd/osd-test-helpers.sh \ $(srcdir)/test/coverage.sh \ - $(srcdir)/test/erasure-code/test-erasure-code.sh \ - $(srcdir)/test/mon/osd-pool-create.sh \ - $(srcdir)/test/mon/misc.sh \ - $(srcdir)/test/mon/osd-crush.sh \ - $(srcdir)/test/mon/osd-erasure-code-profile.sh \ - $(srcdir)/test/mon/mkfs.sh \ - $(srcdir)/test/ceph-disk.sh \ - $(srcdir)/test/mon/mon-handle-forward.sh \ - $(srcdir)/test/vstart_wrapped_tests.sh \ - $(srcdir)/test/pybind/test_ceph_argparse.py + $(patsubst %,$(srcdir)/%,$(check_SCRIPTS)) # target to build but not run the unit tests unittests:: $(check_PROGRAMS)