Module: wine
Branch: master
Commit: 2eb2f71c03e8df1007ce36ccf14af39f0291e45d
URL: http://source.winehq.org/git/wine.git/?a=commit;h=2eb2f71c03e8df1007ce36ccf…
Author: Adam Martinson <amartinson(a)codeweavers.com>
Date: Tue Dec 28 12:46:09 2010 -0600
configure: Fix OpenCL includes on systems with only CL/cl.h.
---
configure | 6 +++---
configure.ac | 6 +++---
dlls/opencl/opencl.c | 4 ++--
include/config.h.in | 4 ++--
4 files changed, 10 insertions(+), 10 deletions(-)
diff --git a/configure b/configure
index c73e024..d75cb53 100755
--- a/configure
+++ b/configure
@@ -2641,7 +2641,7 @@ fi
# Check whether --with-opencl was given.
if test "${with_opencl+set}" = set; then :
- withval=$with_opencl; if test "x$withval" = "xno"; then ac_cv_header_CL_opencl_h=no; ac_cv_header_OpenCL_opencl_h=no; fi
+ withval=$with_opencl; if test "x$withval" = "xno"; then ac_cv_header_CL_cl_h=no; ac_cv_header_OpenCL_opencl_h=no; fi
fi
@@ -5760,7 +5760,7 @@ for ac_header in \
AL/al.h \
AudioToolbox/AudioConverter.h \
AudioUnit/AudioUnit.h \
- CL/opencl.h \
+ CL/cl.h \
Carbon/Carbon.h \
CoreAudio/CoreAudio.h \
DiskArbitration/DiskArbitration.h \
@@ -9064,7 +9064,7 @@ Use the --without-x option if you really want this." "$LINENO" 5 ;;
esac
fi
-if test "$ac_cv_header_CL_opencl_h" = "yes"
+if test "$ac_cv_header_CL_cl_h" = "yes"
then
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for clGetPlatformInfo in -lOpenCL" >&5
$as_echo_n "checking for clGetPlatformInfo in -lOpenCL... " >&6; }
diff --git a/configure.ac b/configure.ac
index 773a727..5ea8356 100644
--- a/configure.ac
+++ b/configure.ac
@@ -69,7 +69,7 @@ AC_ARG_WITH(nas, AS_HELP_STRING([--without-nas],[do not use the NAS sound
AC_ARG_WITH(openal, AS_HELP_STRING([--without-openal],[do not use OpenAL]),
[if test "x$withval" = "xno"; then ac_cv_header_AL_al_h=no; ac_cv_header_OpenAL_al_h=no; fi])
AC_ARG_WITH(opencl, AS_HELP_STRING([--without-opencl],[do not use OpenCL]),
- [if test "x$withval" = "xno"; then ac_cv_header_CL_opencl_h=no; ac_cv_header_OpenCL_opencl_h=no; fi])
+ [if test "x$withval" = "xno"; then ac_cv_header_CL_cl_h=no; ac_cv_header_OpenCL_opencl_h=no; fi])
AC_ARG_WITH(opengl, AS_HELP_STRING([--without-opengl],[do not use OpenGL]))
AC_ARG_WITH(openssl, AS_HELP_STRING([--without-openssl],[do not use OpenSSL]),
[if test "x$withval" = "xno"; then ac_cv_header_openssl_err_h=no; ac_cv_header_openssl_ssl_h=no; fi])
@@ -370,7 +370,7 @@ AC_CHECK_HEADERS(\
AL/al.h \
AudioToolbox/AudioConverter.h \
AudioUnit/AudioUnit.h \
- CL/opencl.h \
+ CL/cl.h \
Carbon/Carbon.h \
CoreAudio/CoreAudio.h \
DiskArbitration/DiskArbitration.h \
@@ -1107,7 +1107,7 @@ without X support, which probably isn't what you want. You will need
to install ${notice_platform}development packages of Xlib/Xfree86 at the very least.])
dnl **** Check for OpenCL ****
-if test "$ac_cv_header_CL_opencl_h" = "yes"
+if test "$ac_cv_header_CL_cl_h" = "yes"
then
AC_CHECK_LIB(OpenCL,clGetPlatformInfo,[AC_SUBST(LIBOPENCL,["-lOpenCL"])])
fi
diff --git a/dlls/opencl/opencl.c b/dlls/opencl/opencl.c
index 7552e79..62e2355 100644
--- a/dlls/opencl/opencl.c
+++ b/dlls/opencl/opencl.c
@@ -30,8 +30,8 @@
WINE_DEFAULT_DEBUG_CHANNEL(opencl);
-#if defined(HAVE_CL_OPENCL_H)
-#include <CL/opencl.h>
+#if defined(HAVE_CL_CL_H)
+#include <CL/cl.h>
#elif defined(HAVE_OPENCL_OPENCL_H)
#include <OpenCL/opencl.h>
#endif
diff --git a/include/config.h.in b/include/config.h.in
index c7bf082..58767a0 100644
--- a/include/config.h.in
+++ b/include/config.h.in
@@ -54,8 +54,8 @@
/* Define to 1 if you have the `chsize' function. */
#undef HAVE_CHSIZE
-/* Define to 1 if you have the <CL/opencl.h> header file. */
-#undef HAVE_CL_OPENCL_H
+/* Define to 1 if you have the <CL/cl.h> header file. */
+#undef HAVE_CL_CL_H
/* Define to 1 if you have the <CoreAudio/CoreAudio.h> header file. */
#undef HAVE_COREAUDIO_COREAUDIO_H