From 074e9e46d1420bb1475adc6bd0707b4584f2dfac Mon Sep 17 00:00:00 2001 From: Tor Aamodt Date: Sat, 19 Nov 2011 09:38:30 -0800 Subject: fixing OpenCL include path detection (compile for nvopencl_wrapper was breaking build on pc08) [git-p4: depot-paths = "//depot/gpgpu_sim_research/fermi/distribution/": change = 10987] --- setup_environment | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) (limited to 'setup_environment') diff --git a/setup_environment b/setup_environment index 4a8e61f..2a0b89a 100644 --- a/setup_environment +++ b/setup_environment @@ -2,7 +2,7 @@ # change the following to point to your installation of CUDA Toolkit # and your installation of the NVIDIA compute SDK -export CUDA_INSTALL_PATH=/usr/local/cuda +export CUDA_INSTALL_PATH=/home/taamodt/nvcuda/3.1/cuda export NVIDIA_COMPUTE_SDK_LOCATION=$HOME/NVIDIA_GPU_Computing_SDK/ # used in commmon/common.mk: @@ -28,13 +28,14 @@ export BOOST_VER= # /usr/lib or /usr/lib64. Not setting this variable will cause gpgpu-sim to # build without opencl support. if [ -f /usr/lib64/libOpenCL.so ]; then - export NVOPENCL_LIBDIR=/usr/lib64 -fi + export NVOPENCL_LIBDIR=/usr/lib64; -# change NVOPENCL_INCDIR to point to your opencl include directory. Not setting -# this variable will cause gpgpu-sim to build without opencl support. -if [ -d /usr/include/CL ]; then - export NVOPENCL_INCDIR=/usr/include/CL + # change NVOPENCL_INCDIR to point to your opencl include directory. + if [ -f /usr/include/CL/cl.h ]; then + export NVOPENCL_INCDIR=/usr/include/; + elif [ -f $CUDA_INSTALL_PATH/include/CL/cl.h ]; then + export NVOPENCL_INCDIR=$CUDA_INSTALL_PATH/include/; + fi fi # setting LD_LIBRARY_PATH as follows enables GPGPU-Sim to be invoked by -- cgit v1.3