summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJim Meyering <meyering@fb.com>2016-12-05 12:15:24 (GMT)
committerJim Meyering <meyering@fb.com>2016-12-14 01:58:26 (GMT)
commiteec6ab399159b8c3caec722d956531a4e799a84c (patch)
tree44fa14f8491e32499ca853c6d36a0edb29443543
parent84d6ae06c287eb4b7254fa85d6b771fd8b4dffc4 (diff)
downloadgrep-eec6ab399159b8c3caec722d956531a4e799a84c.zip
grep-eec6ab399159b8c3caec722d956531a4e799a84c.tar.gz
grep-eec6ab399159b8c3caec722d956531a4e799a84c.tar.bz2
tests: use just-built grep in more places
* cfg.mk (PATH): Prepend $(srcdir)/src, so that we use the just- built grep also when running commands like those of "make distcheck". This would have avoided the recently-luckily-noticed infloop bug. Tested by running this in a just-built directory: f=src/grep; printf '%s\n' '#!/bin/sh' 'sleep 9h' > $f; chmod a+x $f and then verifying that nearly every "make syntax-check" rule hangs.
-rw-r--r--cfg.mk5
1 files changed, 5 insertions, 0 deletions
diff --git a/cfg.mk b/cfg.mk
index aa4ea85..43205a6 100644
--- a/cfg.mk
+++ b/cfg.mk
@@ -14,6 +14,11 @@
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
+# Cause the tool(s) built by this package to be used also when running
+# commands via e.g., "make syntax-check". Doing this a little sooner
+# would have avoided a grep infloop bug.
+export PATH := $(srcdir)/src:${PATH}
+
# Used in maint.mk's web-manual rule
manual_title = GNU Grep: Print lines matching a pattern