mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2025-08-27 01:11:33 +02:00
libcgroup needs the fts api, which musl does not include; depend on fts remove the non-portable *DECLS mess while we're here
208 lines
4.0 KiB
Diff
208 lines
4.0 KiB
Diff
commit ca780b4f7f71abeeb04a585f2a4d889caaa985fa
|
|
Author: Isaac Dunham <ibid.ag@gmail.com>
|
|
Date: Fri Sep 5 22:35:32 2014 -0700
|
|
|
|
Remove __.*DECLS nonsense
|
|
|
|
diff --git a/include/libcgroup/config.h b/include/libcgroup/config.h
|
|
index 2dfdd32..859f7b5 100644
|
|
--- a/include/libcgroup/config.h
|
|
+++ b/include/libcgroup/config.h
|
|
@@ -9,7 +9,9 @@
|
|
#include <features.h>
|
|
#endif
|
|
|
|
-__BEGIN_DECLS
|
|
+#ifdef __cplusplus
|
|
+extern "C" {
|
|
+#endif
|
|
|
|
/**
|
|
* @defgroup group_config 5. Configuration
|
|
@@ -77,6 +79,8 @@ int cgroup_config_set_default(struct cgroup *new_default);
|
|
* @}
|
|
* @}
|
|
*/
|
|
-__END_DECLS
|
|
+#ifdef __cplusplus
|
|
+}
|
|
+#endif
|
|
|
|
#endif /*_LIBCGROUP_CONFIG_H*/
|
|
diff --git a/include/libcgroup/error.h b/include/libcgroup/error.h
|
|
index 91b5c1c..02115f5 100644
|
|
--- a/include/libcgroup/error.h
|
|
+++ b/include/libcgroup/error.h
|
|
@@ -9,7 +9,9 @@
|
|
#include <features.h>
|
|
#endif
|
|
|
|
-__BEGIN_DECLS
|
|
+#ifdef __cplusplus
|
|
+extern "C" {
|
|
+#endif
|
|
|
|
/**
|
|
* @defgroup group_errors 6. Error handling
|
|
@@ -104,6 +106,8 @@ int cgroup_get_last_errno(void);
|
|
* @}
|
|
* @}
|
|
*/
|
|
-__END_DECLS
|
|
+#ifdef __cplusplus
|
|
+}
|
|
+#endif
|
|
|
|
#endif /* _LIBCGROUP_INIT_H */
|
|
diff --git a/include/libcgroup/groups.h b/include/libcgroup/groups.h
|
|
index 39596a1..451fbbd 100644
|
|
--- a/include/libcgroup/groups.h
|
|
+++ b/include/libcgroup/groups.h
|
|
@@ -11,7 +11,9 @@
|
|
#include <stdbool.h>
|
|
#endif
|
|
|
|
-__BEGIN_DECLS
|
|
+#ifdef __cplusplus
|
|
+extern "C" {
|
|
+#endif
|
|
|
|
/**
|
|
* Flags for cgroup_delete_cgroup_ext().
|
|
@@ -570,6 +572,8 @@ int cg_chmod_recursive(struct cgroup *cgroup, mode_t dir_mode,
|
|
*/
|
|
|
|
|
|
-__END_DECLS
|
|
+#ifdef __cplusplus
|
|
+}
|
|
+#endif
|
|
|
|
#endif /* _LIBCGROUP_GROUPS_H */
|
|
diff --git a/include/libcgroup/init.h b/include/libcgroup/init.h
|
|
index 3709096..8ef69ec 100644
|
|
--- a/include/libcgroup/init.h
|
|
+++ b/include/libcgroup/init.h
|
|
@@ -9,7 +9,9 @@
|
|
#include <features.h>
|
|
#endif
|
|
|
|
-__BEGIN_DECLS
|
|
+#ifdef __cplusplus
|
|
+extern "C" {
|
|
+#endif
|
|
|
|
/**
|
|
* @defgroup group_init 1. Initialization
|
|
@@ -54,6 +56,8 @@ int cgroup_get_subsys_mount_point(const char *controller, char **mount_point);
|
|
* @}
|
|
* @}
|
|
*/
|
|
-__END_DECLS
|
|
+#ifdef __cplusplus
|
|
+}
|
|
+#endif
|
|
|
|
#endif /* _LIBCGROUP_INIT_H */
|
|
diff --git a/include/libcgroup/iterators.h b/include/libcgroup/iterators.h
|
|
index c6d453d..fb47d01 100644
|
|
--- a/include/libcgroup/iterators.h
|
|
+++ b/include/libcgroup/iterators.h
|
|
@@ -11,7 +11,9 @@
|
|
#include <features.h>
|
|
#endif
|
|
|
|
-__BEGIN_DECLS
|
|
+#ifdef __cplusplus
|
|
+extern "C" {
|
|
+#endif
|
|
|
|
/**
|
|
* @defgroup group_iterators 3. Iterators
|
|
@@ -423,6 +425,8 @@ int cgroup_get_subsys_mount_point_end(void **handle);
|
|
* @}
|
|
*/
|
|
|
|
-__END_DECLS
|
|
+#ifdef __cplusplus
|
|
+}
|
|
+#endif
|
|
|
|
#endif /* _LIBCGROUP_ITERATORS_H */
|
|
diff --git a/include/libcgroup/tasks.h b/include/libcgroup/tasks.h
|
|
index fb728f4..2f2e486 100644
|
|
--- a/include/libcgroup/tasks.h
|
|
+++ b/include/libcgroup/tasks.h
|
|
@@ -12,7 +12,9 @@
|
|
#include <stdbool.h>
|
|
#endif
|
|
|
|
-__BEGIN_DECLS
|
|
+#ifdef __cplusplus
|
|
+extern "C" {
|
|
+#endif
|
|
|
|
/** Flags for cgroup_change_cgroup_uid_gid(). */
|
|
enum cgflags {
|
|
@@ -189,6 +191,8 @@ int cgroup_register_unchanged_process(pid_t pid, int flags);
|
|
* @}
|
|
* @}
|
|
*/
|
|
-__END_DECLS
|
|
+#ifdef __cplusplus
|
|
+}
|
|
+#endif
|
|
|
|
#endif /* _LIBCGROUP_TASKS_H */
|
|
diff --git a/src/daemon/cgrulesengd.h b/src/daemon/cgrulesengd.h
|
|
index 97c62f1..23607d0 100644
|
|
--- a/src/daemon/cgrulesengd.h
|
|
+++ b/src/daemon/cgrulesengd.h
|
|
@@ -17,7 +17,9 @@
|
|
|
|
#include <features.h>
|
|
|
|
-__BEGIN_DECLS
|
|
+#ifdef __cplusplus
|
|
+extern "C" {
|
|
+#endif
|
|
|
|
#include "config.h"
|
|
#include "libcgroup.h"
|
|
@@ -112,7 +114,9 @@ void cgre_flash_rules(int signum);
|
|
*/
|
|
void cgre_catch_term(int signum);
|
|
|
|
-__END_DECLS
|
|
+#ifdef __cplusplus
|
|
+}
|
|
+#endif
|
|
|
|
#endif /* _CGRULESENGD_H */
|
|
|
|
diff --git a/src/libcgroup-internal.h b/src/libcgroup-internal.h
|
|
index b9d7b6b..46d1f56 100644
|
|
--- a/src/libcgroup-internal.h
|
|
+++ b/src/libcgroup-internal.h
|
|
@@ -16,7 +16,9 @@
|
|
|
|
#define __LIBCG_INTERNAL
|
|
|
|
-__BEGIN_DECLS
|
|
+#ifdef __cplusplus
|
|
+extern "C" {
|
|
+#endif
|
|
|
|
#include "config.h"
|
|
#include <fts.h>
|
|
@@ -269,6 +271,8 @@ extern void cgroup_dictionary_iterator_end(void **handle);
|
|
*/
|
|
int cg_chmod_path(const char *path, mode_t mode, int owner_is_umask);
|
|
|
|
-__END_DECLS
|
|
+#ifdef __cplusplus
|
|
+}
|
|
+#endif
|
|
|
|
#endif
|