From feb9b77fc7a598f756734b3224a5acd4b5463f7d Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Fri, 12 Nov 2004 15:22:45 +0000 Subject: add c++ extern definitions git-svn-id: file:///home/lennart/svn/public/libdaemon/trunk@68 153bfa13-eec0-0310-be40-b0cb6a0e1b4b --- src/dexec.h | 8 ++++++++ src/dfork.h | 8 ++++++++ src/dlog.h | 8 ++++++++ src/dnonblock.h | 8 ++++++++ src/dpid.h | 8 ++++++++ src/dsignal.h | 8 ++++++++ 6 files changed, 48 insertions(+) diff --git a/src/dexec.h b/src/dexec.h index de9f6ff..831cb9d 100644 --- a/src/dexec.h +++ b/src/dexec.h @@ -21,6 +21,10 @@ * Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. */ +#ifdef __cplusplus +extern "C" { +#endif + /** \file * * Contains a robust API for running sub processes with STDOUT and @@ -44,4 +48,8 @@ */ int daemon_exec(const char *dir, int *ret, const char *prog, ...); +#ifdef __cplusplus +} +#endif + #endif diff --git a/src/dfork.h b/src/dfork.h index bdb2923..01b97b4 100644 --- a/src/dfork.h +++ b/src/dfork.h @@ -21,6 +21,10 @@ #include +#ifdef __cplusplus +extern "C" { +#endif + /** \mainpage * * For a brief explanation of libdaemons's purpose, have a look on +#ifdef __cplusplus +extern "C" { +#endif + /** \file * * Contains a robust API for logging messages @@ -58,4 +62,8 @@ void daemon_log(int prio, const char* t, ...); */ char *daemon_ident_from_argv0(char *argv0); +#ifdef __cplusplus +} +#endif + #endif diff --git a/src/dnonblock.h b/src/dnonblock.h index 62a45b3..6cb362b 100644 --- a/src/dnonblock.h +++ b/src/dnonblock.h @@ -19,6 +19,10 @@ * Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. */ +#ifdef __cplusplus +extern "C" { +#endif + /** \file * * Contains a single function used to change a file descriptor to @@ -34,4 +38,8 @@ */ int daemon_nonblock(int fd, int b); +#ifdef __cplusplus +} +#endif + #endif diff --git a/src/dpid.h b/src/dpid.h index 9812ad9..fa2df8f 100644 --- a/src/dpid.h +++ b/src/dpid.h @@ -21,6 +21,10 @@ #include +#ifdef __cplusplus +extern "C" { +#endif + /** \file * * Contains an API for manipulating PID files. @@ -84,4 +88,8 @@ int daemon_pid_file_kill(int s); */ int daemon_pid_file_kill_wait(int s, int m); +#ifdef __cplusplus +} +#endif + #endif diff --git a/src/dsignal.h b/src/dsignal.h index a26b5cc..c777bb7 100644 --- a/src/dsignal.h +++ b/src/dsignal.h @@ -19,6 +19,10 @@ * Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. */ +#ifdef __cplusplus +extern "C" { +#endif + /** \file * * Contains the API for serializing signals to a pipe for @@ -62,4 +66,8 @@ int daemon_signal_next(void); */ int daemon_signal_fd(void); +#ifdef __cplusplus +} +#endif + #endif -- cgit