Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

buildconf hangs with IRIX m4 #1471

canavan opened this issue May 5, 2017 · 1 comment

buildconf hangs with IRIX m4 #1471

canavan opened this issue May 5, 2017 · 1 comment


Copy link

canavan commented May 5, 2017

Trying to build a git checkout of curl on IRIX fails when buildconf attempts to determine the m4 version if the system m4 is used. Apparently, /usr/bin/m4 ignores the --version parameter and waits for input from stdin. Adjusting the path such that a gnu m4 is found first fixes this.

I expected the following

Since the test is intended to weed out non-GNU m4, providing a meaningful error message would be nice.

I've failed so far in my attempts to cause /usr/bin/m4 --version to throw an error, but closing stdin or piping an empty string into m4 at least allows the check to report the problem, although gm4 is not considered at all in this case.

curl/libcurl version


operating system

IRIX 6.5.30


diff --git a/buildconf b/buildconf
index 0d998c2..976734a 100755
--- a/buildconf
+++ b/buildconf
@@ -255,7 +255,7 @@ echo "buildconf: libtoolize version $lt_version (ok)"

m4 check

-m4=(${M4:-m4} --version || ${M4:-gm4} --version) 2>/dev/null | head -n 1;
+m4=(${M4:-m4} --version 0<&- || ${M4:-gm4} --version) 2>/dev/null 0<&- | head -n 1;
m4_version=echo $m4 | sed -e 's/^.* \([0-9]\)/\1/' -e 's/[a-z]* *$//'

if { echo $m4 | grep "GNU" >/dev/null 2>&1; } then

@bagder bagder closed this as completed in 6c7f1f7 May 6, 2017
Copy link

bagder commented May 6, 2017


@lock lock bot locked as resolved and limited conversation to collaborators May 6, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
None yet

No branches or pull requests

2 participants