diff options
author | Ben Gamari <ben@smart-cactus.org> | 2018-01-28T19·19-0500 |
---|---|---|
committer | Ben Gamari <ben@smart-cactus.org> | 2018-01-29T07·20-0500 |
commit | f93e890b4d19f48fefde449c46c29e8330b23998 (patch) | |
tree | 24a21b4c34c1ba4a905fcb3e5253db47e16d7db5 /configure.ac | |
parent | 0167eac571d6d92f18640d05cfb7fa10a4cd0fd9 (diff) |
configure: Use $CPP instead of cpp directly
The latter breaks in the case of cross-compilation, when `cpp` bears a target prefix.
Diffstat (limited to 'configure.ac')
-rw-r--r-- | configure.ac | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/configure.ac b/configure.ac index 9db92ce91401..83b2346d065c 100644 --- a/configure.ac +++ b/configure.ac @@ -61,6 +61,7 @@ CFLAGS= CXXFLAGS= AC_PROG_CC AC_PROG_CXX +AC_PROG_CPP AX_CXX_COMPILE_STDCXX_11 @@ -199,7 +200,7 @@ AC_SUBST(ENABLE_S3, [$enable_s3]) AC_LANG_POP(C++) if test -n "$enable_s3"; then - declare -a aws_version_tokens=($(printf '#include <aws/core/VersionConfig.h>\nAWS_SDK_VERSION_STRING' | cpp -E | grep -v '^#.*' | sed 's/"//g' | tr '.' ' ')) + declare -a aws_version_tokens=($(printf '#include <aws/core/VersionConfig.h>\nAWS_SDK_VERSION_STRING' | $CPP - | grep -v '^#.*' | sed 's/"//g' | tr '.' ' ')) AC_DEFINE_UNQUOTED([AWS_VERSION_MAJOR], ${aws_version_tokens@<:@0@:>@}, [Major version of aws-sdk-cpp.]) AC_DEFINE_UNQUOTED([AWS_VERSION_MINOR], ${aws_version_tokens@<:@1@:>@}, [Minor version of aws-sdk-cpp.]) fi |