diff options
| author | Denys Vlasenko <dvlasenk@redhat.com> | 2010-08-30 18:00:16 +0200 |
|---|---|---|
| committer | Denys Vlasenko <dvlasenk@redhat.com> | 2010-08-30 18:00:16 +0200 |
| commit | 35935c0f0087eefa9b8e84152cecb92060ba65ec (patch) | |
| tree | 23503b7b441bba4334728a6c75d91088b9fd453e | |
| parent | 5fc3f57be241030651f7c2417951aff37f1e12d8 (diff) | |
preparatory change for hooklib.cpp -> hooklib.c conversion
Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com>
| -rw-r--r-- | inc/debug_dump.h | 13 | ||||
| -rw-r--r-- | lib/utils/Makefile.am | 2 | ||||
| -rw-r--r-- | lib/utils/hooklib.cpp | 2 | ||||
| -rw-r--r-- | lib/utils/hooklib.h | 8 |
4 files changed, 22 insertions, 3 deletions
diff --git a/inc/debug_dump.h b/inc/debug_dump.h index 1222a1cb..2e04d780 100644 --- a/inc/debug_dump.h +++ b/inc/debug_dump.h @@ -22,6 +22,8 @@ #ifndef DEBUGDUMP_H_ #define DEBUGDUMP_H_ +#ifdef __cplusplus + #include <string> class CDebugDump @@ -60,10 +62,21 @@ class CDebugDump const char *Directory() const { return m_sDebugDumpDir.c_str(); } }; +#endif /* __cplusplus */ + + +#ifdef __cplusplus +extern "C" { +#endif + /** * Deletes particular debugdump directory. * @param pDebugDumpDir A debugdump directory. */ void delete_debug_dump_dir(const char *pDebugDumpDir); +#ifdef __cplusplus +} +#endif + #endif diff --git a/lib/utils/Makefile.am b/lib/utils/Makefile.am index 14308419..427a39d0 100644 --- a/lib/utils/Makefile.am +++ b/lib/utils/Makefile.am @@ -31,7 +31,7 @@ libABRTUtils_la_SOURCES = \ backtrace_parser.y \ strbuf.h strbuf.c \ abrt_packages.c abrt_packages.h \ - hooklib.h hooklib.cpp + hooklib.cpp hooklib.h libABRTUtils_la_CPPFLAGS = \ -Wall -Werror \ -I$(srcdir)/../../inc \ diff --git a/lib/utils/hooklib.cpp b/lib/utils/hooklib.cpp index f82a9ae5..b0d161d8 100644 --- a/lib/utils/hooklib.cpp +++ b/lib/utils/hooklib.cpp @@ -20,8 +20,6 @@ #include "debug_dump.h" #include <sys/statvfs.h> -using namespace std; - void parse_conf(const char *additional_conf, unsigned *setting_MaxCrashReportsSize, bool *setting_MakeCompatCore, bool *setting_SaveBinaryImage) { FILE *fp = fopen(CONF_DIR"/abrt.conf", "r"); diff --git a/lib/utils/hooklib.h b/lib/utils/hooklib.h index 1651204f..ba76efbc 100644 --- a/lib/utils/hooklib.h +++ b/lib/utils/hooklib.h @@ -16,6 +16,14 @@ 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. */ +#ifdef __cplusplus +extern "C" { +#endif + void parse_conf(const char *additional_conf, unsigned *setting_MaxCrashReportsSize, bool *setting_MakeCompatCore, bool *setting_SaveBinaryImage); void check_free_space(unsigned setting_MaxCrashReportsSize); void trim_debug_dumps(unsigned setting_MaxCrashReportsSize, const char *exclude_path); + +#ifdef __cplusplus +} +#endif |
