From 6c7e099d060749c70637672abac18131833d3cc1 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Mon, 23 May 2011 21:00:56 -0700 Subject: [PATCH] Restore test/ to its non-distributed state (bug#8107) * make-dist: Don't distribute test/. * configure.in (OPT_MAKEFILES_IN): New output variable. (AC_CONFIG_FILES): Conditionally include test/automated/Makefile. * Makefile.in (OPT_MAKEFILES_IN): New, set by configure. (SUBDIR_MAKEFILES_IN): Use $OPT_MAKEFILES_IN. (check): Give an explicit error if test/ is not present. --- ChangeLog | 7 +++++++ Makefile.in | 10 ++++++++-- configure.in | 11 ++++++++++- make-dist | 21 --------------------- 4 files changed, 25 insertions(+), 24 deletions(-) diff --git a/ChangeLog b/ChangeLog index cf2da157e8c..b4c9173f1ea 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,12 @@ 2011-05-24 Glenn Morris + * make-dist: Don't distribute test/. (Bug#8107) + * configure.in (OPT_MAKEFILES_IN): New output variable. + (AC_CONFIG_FILES): Conditionally include test/automated/Makefile. + * Makefile.in (OPT_MAKEFILES_IN): New, set by configure. + (SUBDIR_MAKEFILES_IN): Use $OPT_MAKEFILES_IN. + (check): Give an explicit error if test/ is not present. + * Makefile.in (SUBDIR_MAKEFILES_IN): New variable. (SUBDIR_MAKEFILES): Derive from $SUBDIR_MAKEFILES_IN. (Makefile): Use $SUBDIR_MAKEFILES_IN. diff --git a/Makefile.in b/Makefile.in index e3d5f3ba2bb..f60e70ac518 100644 --- a/Makefile.in +++ b/Makefile.in @@ -264,11 +264,14 @@ EMACSFULL = `echo emacs-${version}${EXEEXT} | sed '$(TRANSFORM)'` # checked out from a VCS. SUBDIR = lib lib-src src lisp +# test/automated/Makefile.in, if you have it (test/ is not in the release). +OPT_MAKEFILES_IN = @OPT_MAKEFILES_IN@ + # The subdir makefiles created by config.status. SUBDIR_MAKEFILES_IN = lib/Makefile.in lib-src/Makefile.in \ doc/emacs/Makefile.in doc/misc/Makefile.in doc/lispref/Makefile.in \ doc/lispintro/Makefile.in src/Makefile.in oldXMenu/Makefile.in \ - lwlib/Makefile.in leim/Makefile.in lisp/Makefile.in test/automated/Makefile.in + lwlib/Makefile.in leim/Makefile.in lisp/Makefile.in $(OPT_MAKEFILES_IN) SUBDIR_MAKEFILES = $(SUBDIR_MAKEFILES_IN:.in=) @@ -862,7 +865,10 @@ TAGS tags: lib lib-src src cd src; $(MAKE) tags check: - cd test/automated; $(MAKE) check + @if test ! -d test/automated; then \ + echo "You do not seem to have the test/ directory."; exit 1; \ + else true; fi + cd test/automated && $(MAKE) check dist: cd ${srcdir}; ./make-dist diff --git a/configure.in b/configure.in index dd895f3f06f..c06965ca17d 100644 --- a/configure.in +++ b/configure.in @@ -3715,7 +3715,16 @@ test "${exec_prefix}" != NONE && AC_CONFIG_FILES([Makefile lib/Makefile lib-src/Makefile oldXMenu/Makefile \ doc/emacs/Makefile doc/misc/Makefile doc/lispintro/Makefile \ doc/lispref/Makefile src/Makefile \ - lwlib/Makefile lisp/Makefile leim/Makefile test/automated/Makefile]) + lwlib/Makefile lisp/Makefile leim/Makefile]) + +dnl test/ is not present in release tarfiles. +if test -f $srcdir/test/automated/Makefile.in; then + OPT_MAKEFILES_IN=test/automated/Makefile.in + AC_CONFIG_FILES([test/automated/Makefile]) +else + OPT_MAKEFILES_IN= +fi +AC_SUBST(OPT_MAKEFILES_IN) dnl Make the necessary directories, if they don't exist. AC_CONFIG_COMMANDS([mkdirs], [ diff --git a/make-dist b/make-dist index 1a92d48a6ba..963236b936e 100755 --- a/make-dist +++ b/make-dist @@ -299,7 +299,6 @@ for subdir in site-lisp \ nt nt/inc nt/inc/sys nt/inc/arpa nt/inc/netinet nt/icons \ `find etc lisp -type d` \ doc doc/emacs doc/misc doc/man doc/lispref doc/lispintro \ - test test/automated test/cedet test/cedet/tests test/indent \ info m4 msdos \ nextstep nextstep/Cocoa nextstep/Cocoa/Emacs.base \ nextstep/Cocoa/Emacs.base/Contents \ @@ -485,26 +484,6 @@ echo "Making links to \`doc/man'" ln ChangeLog* *.1 ../../${tempdir}/doc/man cd ../../${tempdir}/doc/man) -echo "Making links to \`test'" -(cd test - ln *.el ChangeLog README ../${tempdir}/test) - -echo "Making links to \`test/automated'" -(cd test/automated - ln *.el Makefile.in ../../${tempdir}/test/automated) - -echo "Making links to \`test/cedet'" -(cd test/cedet - ln *.el ../../${tempdir}/test/cedet) - -echo "Making links to \`test/cedet/tests'" -(cd test/cedet/tests - ln *.c *.[ch]pp *.el *.hh *.java *.make ../../../${tempdir}/test/cedet/tests) - -echo "Making links to \`test/indent'" -(cd test/indent - ln *.m *.mod *.prolog Makefile ../../${tempdir}/test/indent) - ### It would be nice if they could all be symlinks to top-level copy, but ### you're not supposed to have any symlinks in distribution tar files. echo "Making sure copying notices are all copies of \`COPYING'" -- 2.39.2