Attempt to make Bongo compile on older libical apis
This commit is contained in:
@@ -72,7 +72,20 @@ pkg_check_modules (SQLITE REQUIRED sqlite3)
|
||||
pkg_check_modules (CURL REQUIRED libcurl)
|
||||
|
||||
# check for libical
|
||||
pkg_check_modules (LIBICAL REQUIRED libical)
|
||||
check_include_file(libical/ical.h HAVE_ICAL_H)
|
||||
if (NOT HAVE_ICAL_H)
|
||||
check_include_file(ical.h HAVE_OLD_ICAL_H)
|
||||
if (NOT HAVE_OLD_ICAL_H)
|
||||
message(FATAL_ERROR "Bongo needs libical in order to compile")
|
||||
endif (NOT HAVE_OLD_ICAL_H)
|
||||
endif (NOT HAVE_ICAL_H)
|
||||
|
||||
check_library_exists(ical icaltime_compare "" HAVE_ICAL)
|
||||
if (HAVE_ICAL)
|
||||
set(LIBICAL_LIBRARIES "ical")
|
||||
else (HAVE_ICAL)
|
||||
message(FATAL_ERROR "Bongo couldn't find the libical runtime library")
|
||||
endif (HAVE_ICAL)
|
||||
|
||||
# check for Python
|
||||
include(FindPythonLibs)
|
||||
|
||||
@@ -31,6 +31,9 @@
|
||||
#cmakedefine HAVE_SEMAPHORE_H
|
||||
#endif// Directories.txt
|
||||
|
||||
#cmakedefine HAVE_ICAL_H 1
|
||||
#cmakedefine HAVE_OLD_ICAL_H 1
|
||||
|
||||
#cmakedefine BINDIR "@BINDIR@"
|
||||
#cmakedefine SBINDIR "@SBINDIR@"
|
||||
#cmakedefine LIBDIR "@LIBDIR@"
|
||||
|
||||
@@ -23,7 +23,7 @@
|
||||
#define BONGOCAL_RAW_H
|
||||
|
||||
#include <xpl.h>
|
||||
#include <libical/ical.h>
|
||||
#include <ical-wrapper.h>
|
||||
#include <bongojson.h>
|
||||
|
||||
XPL_BEGIN_C_LINKAGE
|
||||
|
||||
@@ -0,0 +1,11 @@
|
||||
// This is simply a wrapper for ical
|
||||
// Sadly, some installations use /usr/include/ical.h instead of the
|
||||
// "correct" /usr/include/libical/ical.h
|
||||
|
||||
#ifdef HAVE_ICAL_H
|
||||
#include <libical/ical.h>
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_OLD_ICAL_H
|
||||
#include <ical.h>
|
||||
#endif
|
||||
@@ -28,7 +28,7 @@
|
||||
#include <nmlib.h>
|
||||
#include <bongoagent.h>
|
||||
|
||||
#include <libical/ical.h>
|
||||
#include <ical-wrapper.h>
|
||||
|
||||
#define AGENT_NAME "bongoalarm"
|
||||
#define AGENT_DN "Alarm Agent"
|
||||
|
||||
@@ -28,7 +28,7 @@
|
||||
#include <nmlib.h>
|
||||
#include <bongoagent.h>
|
||||
|
||||
#include <libical/ical.h>
|
||||
#include <ical-wrapper.h>
|
||||
|
||||
#define AGENT_NAME "bongocollector"
|
||||
#define AGENT_DN "Collector Agent"
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
#include <config.h>
|
||||
#include "bongo-cal-private.h"
|
||||
#include <bongocal.h>
|
||||
#include <libical/ical.h>
|
||||
#include <ical-wrapper.h>
|
||||
|
||||
typedef struct {
|
||||
BongoCalRecurFrequency freq;
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
#include <config.h>
|
||||
#include <bongoutil.h>
|
||||
#include <bongocal.h>
|
||||
#include <libical/ical.h>
|
||||
#include <ical-wrapper.h>
|
||||
#include <bongocal-raw.h>
|
||||
#include "bongo-cal-private.h"
|
||||
|
||||
|
||||
@@ -41,7 +41,7 @@
|
||||
#include <config.h>
|
||||
#include "bongo-cal-private.h"
|
||||
#include <bongocal.h>
|
||||
#include <libical/ical.h>
|
||||
#include <ical-wrapper.h>
|
||||
|
||||
#define ASSERTTZ(t) {assert(!t.isUtc || (t.isUtc && t.tz == NULL) || (t.isUtc && t.tz == BongoCalTimezoneGetUtc())); assert(!t.tz || !t.tzid || (!strcmp(t.tzid, BongoCalTimezoneGetTzid(t.tz)))); }
|
||||
|
||||
|
||||
@@ -48,7 +48,7 @@
|
||||
#include <config.h>
|
||||
#include "bongo-cal-private.h"
|
||||
#include <bongocal.h>
|
||||
#include <libical/ical.h>
|
||||
#include <ical-wrapper.h>
|
||||
|
||||
typedef struct {
|
||||
int utcOffset;
|
||||
|
||||
@@ -23,7 +23,7 @@
|
||||
#include <xpl.h>
|
||||
#include <bongocal.h>
|
||||
#include <bongocal-raw.h>
|
||||
#include <libical/ical.h>
|
||||
#include <ical-wrapper.h>
|
||||
#include <bongojson.h>
|
||||
#include <bongoutil.h>
|
||||
|
||||
|
||||
@@ -35,7 +35,7 @@
|
||||
#include <nmlib.h>
|
||||
#include <bongocal-raw.h>
|
||||
|
||||
#include <libical/ical.h>
|
||||
#include <ical-wrapper.h>
|
||||
|
||||
#include <curl/curl.h>
|
||||
#include "msghttp.h"
|
||||
|
||||
@@ -28,7 +28,7 @@
|
||||
#include "msgapip.h"
|
||||
|
||||
//#include <libical/icaltime.h>
|
||||
#include <libical/ical.h>
|
||||
#include <ical-wrapper.h>
|
||||
#include "bongoutil.h"
|
||||
|
||||
#define LAST 5
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
* </Novell-copyright>
|
||||
****************************************************************************/
|
||||
|
||||
#include <libical.h>
|
||||
#include <ical-wrapper.h>
|
||||
#include <msgdate.h>
|
||||
#include <memmgr.h>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user