diff --git a/Make.inc.in b/Make.inc.in index e28e9bee..f0b21f91 100755 --- a/Make.inc.in +++ b/Make.inc.in @@ -69,6 +69,7 @@ CBINDLIBNAME=libpsb_cbind.a GPUD=@GPUD@ GPULD=@GPULD@ +LGPU=@LGPU@ SPGPUDIR=@SPGPU_DIR@ SPGPU_INCDIR=@SPGPU_INCDIR@ @@ -92,3 +93,4 @@ CUDEFINES=@CUDEFINES@ @PSBLASRULES@ +PSBGPULDLIBS=$(LGPU) $(SPGPU_LIBS) $(CUDA_LIBS) $(LIBS) \ No newline at end of file diff --git a/configure b/configure index 5c3444b3..d2fa80d2 100755 --- a/configure +++ b/configure @@ -653,6 +653,7 @@ ac_subst_vars='am__EXEEXT_FALSE am__EXEEXT_TRUE LTLIBOBJS LIBOBJS +LGPU GPULD GPUD CUDEFINES @@ -11020,6 +11021,7 @@ CPPFLAGS="$SAVE_CPPFLAGS" if test "x$pac_cv_have_spgpu" == "xyes" ; then GPUD=gpud; GPULD=gpuld; + LGPU="-lpsb_gpu"; EXTRALDLIBS="-lstdc++"; fi { printf "%s\n" "$as_me:${as_lineno-$LINENO}: At this point GPUTARGET is $GPUD $GPULD" >&5 @@ -11161,6 +11163,7 @@ FDEFINES=$(PSBFDEFINES) + ############################################################################### diff --git a/configure.ac b/configure.ac index 4b7f82e1..cb23c6ac 100755 --- a/configure.ac +++ b/configure.ac @@ -801,7 +801,8 @@ CUDA_SHORT_VERSION=$(expr $pac_cv_cuda_version / 1000); PAC_CHECK_SPGPU() if test "x$pac_cv_have_spgpu" == "xyes" ; then GPUD=gpud; - GPULD=gpuld; + GPULD=gpuld; + LGPU="-lpsb_gpu"; EXTRALDLIBS="-lstdc++"; fi AC_MSG_NOTICE([At this point GPUTARGET is $GPUD $GPULD]) @@ -933,6 +934,7 @@ AC_SUBST(CUDA_NVCC) AC_SUBST(CUDEFINES) AC_SUBST(GPUD) AC_SUBST(GPULD) +AC_SUBST(LGPU) ############################################################################### # the following files will be created by Automake