Переглянути джерело

examples/lu,mpi/examples/mpi_lu: fix non-cuda build

Nathalie Furmento 10 роки тому
батько
коміт
6a6b787b10
2 змінених файлів з 6 додано та 2 видалено
  1. 3 1
      examples/lu/xlu.h
  2. 3 1
      mpi/examples/mpi_lu/pxlu.h

+ 3 - 1
examples/lu/xlu.h

@@ -1,7 +1,7 @@
 /* StarPU --- Runtime system for heterogeneous multicore architectures.
  *
  * Copyright (C) 2009, 2010-2011, 2014  Université de Bordeaux
- * Copyright (C) 2010, 2011, 2012, 2013  Centre National de la Recherche Scientifique
+ * Copyright (C) 2010, 2011, 2012, 2013, 2014  Centre National de la Recherche Scientifique
  *
  * StarPU is free software; you can redistribute it and/or modify
  * it under the terms of the GNU Lesser General Public License as published by
@@ -20,7 +20,9 @@
 
 #include <starpu.h>
 #include <common/blas.h>
+#ifdef STARPU_USE_CUDA
 #include <cublas.h>
+#endif
 
 #define TAG11(k)	((starpu_tag_t)( (1ULL<<60) | (unsigned long long)(k)))
 #define TAG12(k,i)	((starpu_tag_t)(((2ULL<<60) | (((unsigned long long)(k))<<32)	\

+ 3 - 1
mpi/examples/mpi_lu/pxlu.h

@@ -1,7 +1,7 @@
 /* StarPU --- Runtime system for heterogeneous multicore architectures.
  *
  * Copyright (C) 2010, 2014  Université de Bordeaux
- * Copyright (C) 2010, 2012  Centre National de la Recherche Scientifique
+ * Copyright (C) 2010, 2012, 2014  Centre National de la Recherche Scientifique
  *
  * StarPU is free software; you can redistribute it and/or modify
  * it under the terms of the GNU Lesser General Public License as published by
@@ -21,7 +21,9 @@
 #include <starpu.h>
 #include <common/blas.h>
 #include <starpu_mpi.h>
+#ifdef STARPU_USE_CUDA
 #include <cublas.h>
+#endif
 
 #define BLAS3_FLOP(n1,n2,n3)    \
         (2*((uint64_t)n1)*((uint64_t)n2)*((uint64_t)n3))