On Solaris 11.4, the "gmake check" command in automake-1.16j appears to hang. Using 'truss', I found that it invokes /usr/bin/lex --version and that command reads from standard input: $ /usr/bin/lex --version lex: Software Generation Utilities (SGU) Solaris-ELF (4.0) _ The attached proposed patch fixes it.