Greg Troxel a écrit :
> and Mac OS X 10.5.7 has MAP_ANON and not MAP_ANONYMOUS.  Just dropping
> it seems not justified, but perhaps it is actually ok.
>
>   
Yes, instead can you try the attached patch ?

MAP_ANON should be defined, but not MAP_ANONYMOUS on some systems,
so making an alias should suffice.

--
Zas

Index: compat.h
===================================================================
--- compat.h	(révision 1803)
+++ compat.h	(copie de travail)
@@ -21,5 +21,13 @@
 #endif
 
 
+/* Some systems (BSD,MacOsX,HP-UX,...) define MAP_ANON and not MAP_ANONYMOUS */
+#if defined(MAP_ANON) && !defined(MAP_ANONYMOUS)
+#define	MAP_ANONYMOUS	MAP_ANON
+#elif defined(MAP_ANONYMOUS) && !defined(MAP_ANON)
+#define	MAP_ANON	MAP_ANONYMOUS
+#endif
+
+
 #endif /* COMPAT_H */
 /* vim: set shiftwidth=8 softtabstop=0 cindent cinoptions={1s: */
Index: main.c
===================================================================
--- main.c	(révision 1803)
+++ main.c	(copie de travail)
@@ -10,7 +10,21 @@
  * This software comes with no warranty of any kind, use at your own risk!
  */
 
+#include <gdk/gdkkeysyms.h> /* for keyboard values */
+#ifdef HAVE_LIBCHAMPLAIN
+#ifdef HAVE_LIBCHAMPLAIN_GTK
+#include <clutter-gtk/gtk-clutter-embed.h>
+#endif
+#endif
 
+#include <signal.h>
+#include <sys/mman.h>
+
+#include <math.h>
+#ifdef G_OS_UNIX
+#include <pwd.h>
+#endif
+
 #include "main.h"
 
 #include "cache.h"
@@ -36,21 +50,7 @@
 #include "histogram.h"
 #include "pixbuf_util.h"
 
-#include <gdk/gdkkeysyms.h> /* for keyboard values */
-#ifdef HAVE_LIBCHAMPLAIN
-#ifdef HAVE_LIBCHAMPLAIN_GTK
-#include <clutter-gtk/gtk-clutter-embed.h>
-#endif
-#endif
 
-#include <signal.h>
-#include <sys/mman.h>
-
-#include <math.h>
-#ifdef G_OS_UNIX
-#include <pwd.h>
-#endif
-
 gboolean thumb_format_changed = FALSE;
 static RemoteConnection *remote_connection = NULL;
 
------------------------------------------------------------------------------
_______________________________________________
Geeqie-devel mailing list
Geeqie-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geeqie-devel

Reply via email to