[evolution-kolab/gnome-2-30] libekolabconv: feature definitions for non-standard functions



commit c8c3b92ddb979b50fb9c92ed73e55705b1bf1c51
Author: Christian Hilberg <hilberg kernelconcepts de>
Date:   Thu Nov 17 12:39:33 2011 +0100

    libekolabconv: feature definitions for non-standard functions
    
    * defined the symbols checked by the feature test macros
      for timegm(), strdup() and fileno() functions
    * added missind system header includes
    * FIXME: need to remove use of these functions entirely

 .../main/src/evolution/evolution-util.c            |    7 ++++++-
 .../main/src/evolution/priv-common-e-to-i.c        |    7 ++++++-
 src/libekolabconv/main/src/kolab/event-i-to-k.c    |    7 +++++++
 src/libekolabconv/test/src/email-parser.c          |    6 ++++++
 4 files changed, 25 insertions(+), 2 deletions(-)
---
diff --git a/src/libekolabconv/main/src/evolution/evolution-util.c b/src/libekolabconv/main/src/evolution/evolution-util.c
index 5977968..c4c3250 100644
--- a/src/libekolabconv/main/src/evolution/evolution-util.c
+++ b/src/libekolabconv/main/src/evolution/evolution-util.c
@@ -23,10 +23,15 @@
  * 51 Franklin Street, Fifth Floor Boston, MA 02110-1301, USA
  */
 
+/* FIXME remove the use of timegm() */
+#define _BSD_SOURCE
+#define _SVID_SOURCE
+
+#include <time.h>
+
 #include "evolution-util.h"
 #include "../logging.h"
 
-
 /**
  * Convert an evolution iCal time type to an internal date((/time) structure.
  */
diff --git a/src/libekolabconv/main/src/evolution/priv-common-e-to-i.c b/src/libekolabconv/main/src/evolution/priv-common-e-to-i.c
index 76e1c7f..4f24e43 100644
--- a/src/libekolabconv/main/src/evolution/priv-common-e-to-i.c
+++ b/src/libekolabconv/main/src/evolution/priv-common-e-to-i.c
@@ -24,11 +24,16 @@
  * 51 Franklin Street, Fifth Floor Boston, MA 02110-1301, USA
  */
 
+/* FIXME remove the use of strdup(), replace by g_strdup() */
+#define _BSD_SOURCE
+#define _SVID_SOURCE
+#define _XOPEN_SOURCE 500
+
+#include <string.h>
 
 #include "priv-evolution.h"
 #include "evolution-util.h"
 
-
 /**
  * get ICalendar VTIMEZONE block from ECalComponentWithTZ
  *
diff --git a/src/libekolabconv/main/src/kolab/event-i-to-k.c b/src/libekolabconv/main/src/kolab/event-i-to-k.c
index 03f6629..4f2a834 100644
--- a/src/libekolabconv/main/src/kolab/event-i-to-k.c
+++ b/src/libekolabconv/main/src/kolab/event-i-to-k.c
@@ -24,6 +24,13 @@
  * 51 Franklin Street, Fifth Floor Boston, MA 02110-1301, USA
  */
 
+/* FIXME remove the use of strdup(), replace by g_strdup() */
+#define _BSD_SOURCE
+#define _SVID_SOURCE
+#define _XOPEN_SOURCE 500
+
+#include <string.h>
+
 #include "priv-kolab.h"
 #include "kolab.h" /* public part of this file */
 #include "../util.h"
diff --git a/src/libekolabconv/test/src/email-parser.c b/src/libekolabconv/test/src/email-parser.c
index 62ac0c6..fd0cd3d 100644
--- a/src/libekolabconv/test/src/email-parser.c
+++ b/src/libekolabconv/test/src/email-parser.c
@@ -22,6 +22,12 @@
  * 51 Franklin Street, Fifth Floor Boston, MA 02110-1301, USA
  */
 
+/* FIXME remove the use of fileno() */
+#define _POSIX_C_SOURCE 1
+#define _XOPEN_SOURCE
+#define _POSIX_SOURCE
+
+#include <stdio.h>
 #include <unistd.h>
 #include <logging.h>
 #include "email-parser.h"



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]