浏览代码

include: fix c++ code

Nathalie Furmento 13 年之前
父节点
当前提交
f311c3c43b

+ 2 - 0
include/starpu.h

@@ -37,6 +37,8 @@ typedef unsigned long long uint64_t;
 
 #include <starpu_util.h>
 #include <starpu_data.h>
+#include <starpu_data_interfaces.h>
+#include <starpu_data_filters.h>
 #include <starpu_perfmodel.h>
 #include <starpu_task.h>
 #include <starpu_task_list.h>

+ 3 - 6
include/starpu_data.h

@@ -22,17 +22,14 @@
 
 #include <starpu_config.h>
 
-struct _starpu_data_state;
-typedef struct _starpu_data_state* starpu_data_handle_t;
-
-#include <starpu_data_interfaces.h>
-#include <starpu_data_filters.h>
-
 #ifdef __cplusplus
 extern "C"
 {
 #endif
 
+struct _starpu_data_state;
+typedef struct _starpu_data_state* starpu_data_handle_t;
+
 enum starpu_access_mode
 {
 	STARPU_R=(1<<0),

+ 0 - 1
include/starpu_data_filters.h

@@ -22,7 +22,6 @@
 #define __STARPU_DATA_FILTERS_H__
 
 #include <stdarg.h>
-
 #include <starpu_config.h>
 
 #ifdef __cplusplus

+ 8 - 0
include/starpu_deprecated_api.h

@@ -18,6 +18,11 @@
 #ifndef __STARPU_DEPRECATED_API_H__
 #define _STARPU_DEPRECATED_API_H__
 
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
 #warning deprecated types. Please update your code to use the latest API.
 
 #define starpu_codelet			struct starpu_codelet
@@ -43,5 +48,8 @@
 #define starpu_sched_policy_s		starpu_sched_policy
 #define starpu_data_interface_ops_t	starpu_data_interface_ops
 
+#ifdef __cplusplus
+}
+#endif
 
 #endif /* _STARPU_DEPRECATED_API_H__ */

+ 0 - 1
include/starpu_profiling.h

@@ -23,7 +23,6 @@
 #include <errno.h>
 #include <sys/time.h>
 
-
 #ifdef __cplusplus
 extern "C"
 {

+ 5 - 5
include/starpu_task.h

@@ -30,6 +30,11 @@
 
 #include <starpu_data.h>
 
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
 #define STARPU_CPU	((1ULL)<<1)
 #define STARPU_CUDA	((1ULL)<<3)
 #define STARPU_SPU	((1ULL)<<4)
@@ -56,11 +61,6 @@ enum starpu_task_status
 	STARPU_TASK_BLOCKED_ON_DATA
 };
 
-#ifdef __cplusplus
-extern "C"
-{
-#endif
-
 typedef uint64_t starpu_tag_t;
 
 typedef void (*starpu_cpu_func_t)(void **, void*);    /* CPU core */

+ 0 - 2
include/starpu_top.h

@@ -243,8 +243,6 @@ void starpu_top_debug_lock(const char* message);
 void starpu_top_process_input_message(char *message);
 
 
-
-
 #ifdef __cplusplus
 }
 #endif