Apple Clang, when called via `gcc` emits a `Configured with` line
on stderr which confuses the compiler detection. We just ignore
stderr for the `--version` query now.
HOST_OS_WINDOWS=false
HOST_OS_CYGWIN=false
-compiler_version="`$COMPILER --version 2>&1 | head -1`"
+compiler_version="`$COMPILER --version 2>/dev/null | head -1`"
case $compiler_version in
*gcc*|*g++*|2.95*)
COMPILER_TYPE_GCC=true
else
echo "Compiler: $COMPILER ($REAL_COMPILER)"
fi
-echo "Compiler version: $($COMPILER --version | head -n 1)"
+echo "Compiler version: $($COMPILER --version 2>/dev/null | head -n 1)"
REAL_NVCC=$(find_compiler nvcc)
REAL_CUOBJDUMP=$(find_compiler cuobjdump)
SUITE_direct_gcc_PROBE() {
- if [[ $REAL_COMPILER != *"gcc"* ]]; then
+ if [[ "${COMPILER_TYPE_GCC}" != "true" ]]; then
echo "Skipping GCC only test cases"
fi
}