From c6751cfb92e5c5a4cdfc778398f74468123ccdf1 Mon Sep 17 00:00:00 2001 From: Keegan McAllister Date: Tue, 10 Apr 2012 22:00:48 -0400 Subject: [PATCH] configure.ac: Fix protoc check AC_MSG_ERROR inside the variable assignment doesn't work properly. We get output like checking for protoc... ./configure: line 4524: is: command not found no and then the build continues (and fails) with PROTOC="". Closes #132 github pull request. --- configure.ac | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/configure.ac b/configure.ac index f96acec..24f5a13 100644 --- a/configure.ac +++ b/configure.ac @@ -13,7 +13,9 @@ AC_CONFIG_HEADERS([config.h]) AC_PROG_CC AC_PROG_CXX AC_PROG_RANLIB -AC_PATH_PROG([PROTOC], [protoc], [AC_MSG_ERROR([protoc is not found])]) +AC_PATH_PROG([PROTOC], [protoc], []) +AS_IF([test x"$PROTOC" = x], + [AC_MSG_ERROR([cannot find protoc, the Protocol Buffers compiler])]) WARNING_CXXFLAGS="" PICKY_CXXFLAGS=""