Browse Source

Bugfix: Use test -f rather than AC_CHECK_FILE to check for ADL headers

AC_CHECK_FILE is for "native system" checks, and doesn't work when cross-compiling.
autoconf developers seem to recommend test -f for build-system file existence checking.
Luke Dashjr 13 years ago
parent
commit
610328a316
1 changed files with 5 additions and 1 deletions
  1. 5 1
      configure.ac

+ 5 - 1
configure.ac

@@ -136,7 +136,11 @@ AC_ARG_ENABLE([adl],
 
 if test "x$opencl" = xyes; then
 	if test "x$adl" != xno; then
-		AC_CHECK_FILE([ADL_SDK/adl_sdk.h], have_adl=true, have_adl=false,)
+		if test -f ADL_SDK/adl_sdk.h; then
+			have_adl=true
+		else
+			have_adl=false
+		fi
 		if test x$have_adl = xtrue
 		then
 			AC_DEFINE([HAVE_ADL], [1], [Defined if ADL headers were found])