# HG changeset patch # User Mike Miller # Date 1491245461 25200 # Node ID ce61206a61f8141cf53dc518c8881a41086e7609 # Parent 1af3687133792db86fc3a1d8ea55266b4d7fcf28 build: make distcheck pass again * Makefile.am (EXTRA_DIST): Include $(M_FILES). (PKG_ADD, PKG_DEL): Use $(srcdir) as needed. (check-local): Use $(srcdir) to run the test script. * __py_tests__.m: Suppress warnings about opening files on the load path. diff -r 1af368713379 -r ce61206a61f8 Makefile.am --- a/Makefile.am Mon Apr 03 11:25:53 2017 -0700 +++ b/Makefile.am Mon Apr 03 11:51:01 2017 -0700 @@ -75,7 +75,7 @@ TST_FILES = $(addsuffix -tst,$(OCT_SOURCE_FILES)) -EXTRA_DIST = $(DOC_FILES) $(OCT_SOURCE_FILES) +EXTRA_DIST = $(DOC_FILES) $(M_FILES) $(OCT_SOURCE_FILES) EXTRA_libdir = $(PYTAVE_MODULE_INSTALL_PATH) EXTRA_lib_LTLIBRARIES = _pytave.la @@ -115,7 +115,8 @@ PKG_ADD: $(OCT_SOURCE_FILES) $(AM_V_GEN)for f in $(OCT_SOURCE_FILES); do \ b=$${f%.cc}; \ - funcs=`$(SED) -n 's/^DEFUN.*(\(\w\+\),.*/\1/p' $$f | grep -v $$b`; \ + if test -f $$f; then d=.; else d=$(srcdir); fi; \ + funcs=`$(SED) -n 's/^DEFUN.*(\(\w\+\),.*/\1/p' $$d/$$f | grep -v $$b`; \ if test -n "$$funcs"; then \ echo "$$funcs" | $(SED) "s/.*/autoload (\"&\", \"$$b.oct\");/" > $@-t && \ mv $@-t $@ || exit $?; \ @@ -125,7 +126,8 @@ PKG_DEL: $(OCT_SOURCE_FILES) $(AM_V_GEN)for f in $(OCT_SOURCE_FILES); do \ b=$${f%.cc}; \ - funcs=`$(SED) -n 's/^DEFUN.*(\(\w\+\),.*/\1/p' $$f | grep -v $$b`; \ + if test -f $$f; then d=.; else d=$(srcdir); fi; \ + funcs=`$(SED) -n 's/^DEFUN.*(\(\w\+\),.*/\1/p' $$d/$$f | grep -v $$b`; \ if test -n "$$funcs"; then \ echo "$$funcs" | $(SED) "s/.*/autoload (\"&\", which (\"&\"), \"remove\");/" > $@-t && \ mv $@-t $@ || exit $?; \ @@ -146,4 +148,4 @@ check-local: $(M_FILES) $(TST_FILES) $(OCTAVE) --no-gui-libs --no-history --no-window-system --norc \ --path="$(abs_builddir)" --path="$(abs_srcdir)" \ - __py_tests__.m $(M_FILES) $(TST_FILES) + $(srcdir)/__py_tests__.m $(M_FILES) $(TST_FILES) diff -r 1af368713379 -r ce61206a61f8 __py_tests__.m --- a/__py_tests__.m Mon Apr 03 11:25:53 2017 -0700 +++ b/__py_tests__.m Mon Apr 03 11:51:01 2017 -0700 @@ -26,10 +26,12 @@ files_with_tests = {}; pso = page_screen_output (); + orig_wstate = warning (); logfile = make_absolute_filename ("fntests.log"); unwind_protect page_screen_output (false); + warning ("off", "Octave:data-file-in-path"); try fid = fopen (logfile, "wt"); if (fid < 0) @@ -104,6 +106,8 @@ disp (lasterr ()); end_try_catch unwind_protect_cleanup + warning ("off", "all"); + warning (orig_wstate); page_screen_output (pso); end_unwind_protect retval = (nfail != 0);