diff --git a/Makefile b/Makefile index 9edfb88..2099dbc 100644 --- a/Makefile +++ b/Makefile @@ -1,7 +1,7 @@ MODELNAME := _ConvNet -INCLUDES := -I$(PYTHON_INCLUDE) -I$(NUMPY_INCLUDE) -I./include -LIB := -lpthread -lcblas +INCLUDES := -I$(PYTHON_INCLUDE_PATH) -I$(NUMPY_INCLUDE_PATH) -I./include +LIB := -lpthread -L$(ATLAS_LIB_PATH) -L$(CUDA_INSTALL_PATH)/lib64 -lcblas USECUBLAS := 1 diff --git a/build.sh b/build.sh index f21c633..87bb27b 100755 --- a/build.sh +++ b/build.sh @@ -8,16 +8,16 @@ export CUDA_INSTALL_PATH=/usr/local/cuda # CUDA SDK installation directory -export CUDA_SDK_PATH=/home/spoon/NVIDIA_GPU_Computing_SDK/ +export CUDA_SDK_PATH=/home/spoon/NVIDIA_GPU_Computing_SDK # Python include directory. This should contain the file Python.h, among others. -export PYTHON_INCLUDE=/usr/include/python2.7/ +export PYTHON_INCLUDE_PATH=/usr/include/python2.7 # Numpy include directory. This should contain the file arrayobject.h, among others. -export NUMPY_INCLUDE=/usr/include/python2.7_d/numpy/ +export NUMPY_INCLUDE_PATH=/usr/lib64/python2.7/site-packages/numpy/core/include/numpy -# Leave this line alone. -export LD_LIBRARY_PATH=$CUDA_INSTALL_PATH/lib64:$CUDA_INSTALL_PATH/lib:$LD_LIBRARY_PATH +# ATLAS library directory. This should contain the file libcblas.so, among others. +export ATLAS_LIB_PATH=/usr/lib64/atlas make $* diff --git a/common-gcc-cuda-4.0.mk b/common-gcc-cuda-4.0.mk index eadc88e..b5610b5 100644 --- a/common-gcc-cuda-4.0.mk +++ b/common-gcc-cuda-4.0.mk @@ -281,18 +281,18 @@ endif # If dynamically linking to CUDA and CUDART, we exclude the libraries from the LIB ifeq ($(USECUDADYNLIB),1) - LIB += ${OPENGLLIB} $(PARAMGLLIB) $(RENDERCHECKGLLIB) $(CUDPPLIB) ${LIB} -ldl -rdynamic + LIB := ${OPENGLLIB} $(PARAMGLLIB) $(RENDERCHECKGLLIB) $(CUDPPLIB) ${LIB} -ldl -rdynamic else # static linking, we will statically link against CUDA and CUDART ifeq ($(USEDRVAPI),1) - LIB += -lcuda ${OPENGLLIB} $(PARAMGLLIB) $(RENDERCHECKGLLIB) $(CUDPPLIB) ${LIB} + LIB := -lcuda ${OPENGLLIB} $(PARAMGLLIB) $(RENDERCHECKGLLIB) $(CUDPPLIB) ${LIB} else ifeq ($(emu),1) LIB += -lcudartemu else LIB += -lcudart endif - LIB += ${OPENGLLIB} $(PARAMGLLIB) $(RENDERCHECKGLLIB) $(CUDPPLIB) ${LIB} + LIB := ${OPENGLLIB} $(PARAMGLLIB) $(RENDERCHECKGLLIB) $(CUDPPLIB) ${LIB} endif endif