Explorar o código

Also test for declaration of nvmlDeviceGetTotalEnergyConsumption

Samuel Thibault %!s(int64=5) %!d(string=hai) anos
pai
achega
086871f394
Modificáronse 1 ficheiros con 3 adicións e 1 borrados
  1. 3 1
      configure.ac

+ 3 - 1
configure.ac

@@ -1359,7 +1359,9 @@ if test x$enable_cuda = xyes; then
 	    ]
 	)
 	if test x$have_valid_nvml = xyes ; then
-		AC_CHECK_FUNCS([nvmlDeviceGetTotalEnergyConsumption])
+		AC_CHECK_DECLS([nvmlDeviceGetTotalEnergyConsumption], [
+			AC_CHECK_FUNCS([nvmlDeviceGetTotalEnergyConsumption])
+			], [], [[#include <nvml.h>]])
 		AC_DEFINE([HAVE_LIBNVIDIA_ML], [1], [Define to 1 if you have the nvidia-ml library])
 		STARPU_CUDA_LDFLAGS="$STARPU_CUDA_LDFLAGS -lnvidia-ml"
 	fi