Author: benny
Date: 2006-07-27 20:30:20 +0000 (Thu, 27 Jul 2006)
New Revision: 22536

Modified:
   thunar/trunk/ChangeLog
   thunar/trunk/configure.in.in
   thunar/trunk/tdb/Makefile.am
   thunar/trunk/thunar-vfs/thunar-vfs-io-local-xfer.c
Log:
2006-07-27      Benedikt Meurer <[EMAIL PROTECTED]>

        * configure.in.in, thunar-vfs/thunar-vfs-io-local-xfer.c,
          tdb/Makefile.am: Work-around various glibc oddities.




Modified: thunar/trunk/ChangeLog
===================================================================
--- thunar/trunk/ChangeLog      2006-07-27 18:55:05 UTC (rev 22535)
+++ thunar/trunk/ChangeLog      2006-07-27 20:30:20 UTC (rev 22536)
@@ -1,5 +1,10 @@
 2006-07-27     Benedikt Meurer <[EMAIL PROTECTED]>
 
+       * configure.in.in, thunar-vfs/thunar-vfs-io-local-xfer.c,
+         tdb/Makefile.am: Work-around various glibc oddities.
+
+2006-07-27     Benedikt Meurer <[EMAIL PROTECTED]>
+
        * README, acinclude.m4, configure.in.in, thunar-vfs/, thunar/,
          plugins/thunar-apr/thunar-apr-provider.c,
          plugins/thunar-uca/thunar-uca-model.c: Import the trash framework,

Modified: thunar/trunk/configure.in.in
===================================================================
--- thunar/trunk/configure.in.in        2006-07-27 18:55:05 UTC (rev 22535)
+++ thunar/trunk/configure.in.in        2006-07-27 20:30:20 UTC (rev 22536)
@@ -96,6 +96,8 @@
 dnl ***********************************************
 dnl *** Work-around system-specific limitations ***
 dnl ***********************************************
+AC_DEFINE([_XOPEN_SOURCE], [600], [Required to make glibc usable])
+AC_DEFINE([_BSD_SOURCE], [1], [Required to make glibc usable])
 AC_SYS_LARGEFILE()
 
 dnl **********************************
@@ -114,74 +116,10 @@
 dnl ************************************
 AC_FUNC_MMAP()
 AC_CHECK_FUNCS([attropen extattr_get_fd fgetxattr lchmod localeconv \
-                localtime_r mbrtowc mkfifo pread pwrite readdir_r \
-                sched_yield setgroupent setpassent statfs statvfs strcoll \
-                strlcpy symlink])
+                localtime_r mbrtowc mkfifo posix_madvise pread pwrite \
+               readdir_r sched_yield setgroupent setpassent statfs \
+               statvfs strcoll strlcpy strptime symlink])
 
-dnl ***************************************
-dnl *** Check for working posix_madvise ***
-dnl ***************************************
-m4_define([posix_madvise_test],
-[
-posix_madvise (0, 0, POSIX_MADV_NORMAL);
-posix_madvise (0, 0, POSIX_MADV_SEQUENTIAL);
-posix_madvise (0, 0, POSIX_MADV_RANDOM);
-posix_madvise (0, 0, POSIX_MADV_WILLNEED);
-posix_madvise (0, 0, POSIX_MADV_DONTNEED);
-])
-AC_MSG_CHECKING([for working posix_madvise])
-AC_TRY_LINK([#include <sys/mman.h>], posix_madvise_test(),
-[
-  AC_DEFINE([HAVE_POSIX_MADVISE], [1], [Define if posix_madvise is working])
-  AC_MSG_RESULT([yes])
-],
-[
-  dnl As usual, Linux/glibc doesn't work properly out-of-the-box
-  ac_save_CPPFLAGS="$CPPFLAGS"
-  CPPFLAGS="$CPPFLAGS -D__USE_XOPEN2K"
-  AC_TRY_LINK([#include <sys/mman.h>], posix_madvise_test(),
-  [
-    AC_DEFINE([HAVE_POSIX_MADVISE], [1], [Define if posix_madvise is working])
-    AC_MSG_RESULT([yes])
-  ],
-  [
-    CPPFLAGS="$ac_save_CPPFLAGS"
-    AC_MSG_RESULT([no])
-  ])
-])
-
-dnl **********************************
-dnl *** Check for working strptime ***
-dnl **********************************
-if test x"$GCC" = x"yes"; then
-  ac_save_CFLAGS="$CFLAGS"
-  CFLAGS="$CFLAGS -Werror" # to detect a protected declaration
-  m4_define([strptime_test], [ strptime (0, 0, 0); ])
-  AC_MSG_CHECKING([for working strptime])
-  AC_TRY_LINK([#include <time.h>], strptime_test,
-  [
-    AC_DEFINE([HAVE_STRPTIME], [1], [Define if strptime is working])
-    AC_MSG_RESULT([yes])
-  ],
-  [
-    dnl As usual, Linux/glibc doesn't work properly out-of-the-box
-    ac_save_CPPFLAGS="$CPPFLAGS"
-    CPPFLAGS="$CPPFLAGS -D__USE_XOPEN"
-    AC_TRY_LINK([#include <time.h>], strptime_test,
-    [
-      AC_DEFINE([HAVE_STRPTIME], [1], [Define if strptime is working])
-      AC_MSG_RESULT([yes])
-    ],
-    [
-      CPPFLAGS="$ac_save_CPPFLAGS"
-      AC_MSG_RESULT([no])
-    ])
-  ])
-  CFLAGS="$ac_save_CFLAGS"
-else
-  AC_CHECK_FUNCS([strptime])
-fi
-
 dnl ******************************
 dnl *** Check for i18n support ***
 dnl ******************************

Modified: thunar/trunk/tdb/Makefile.am
===================================================================
--- thunar/trunk/tdb/Makefile.am        2006-07-27 18:55:05 UTC (rev 22535)
+++ thunar/trunk/tdb/Makefile.am        2006-07-27 20:30:20 UTC (rev 22536)
@@ -7,9 +7,6 @@
 noinst_LTLIBRARIES =                                                   \
        libtdb.la
 
-libtdb_la_CFLAGS =                                                     \
-       -D_XOPEN_SOURCE=500
-
 libtdb_la_SOURCES =                                                    \
        spinlock.c                                                      \
        spinlock.h                                                      \

Modified: thunar/trunk/thunar-vfs/thunar-vfs-io-local-xfer.c
===================================================================
--- thunar/trunk/thunar-vfs/thunar-vfs-io-local-xfer.c  2006-07-27 18:55:05 UTC 
(rev 22535)
+++ thunar/trunk/thunar-vfs/thunar-vfs-io-local-xfer.c  2006-07-27 20:30:20 UTC 
(rev 22536)
@@ -200,7 +200,7 @@
     {
 #ifdef HAVE_POSIX_MADVISE
       /* tell the system that the data will be read sequentially */
-      posix_madvise (buffer, source_statb->st_size, MADV_SEQUENTIAL);
+      posix_madvise (buffer, source_statb->st_size, POSIX_MADV_SEQUENTIAL);
 #endif
 
       /* write the data to the target file */

_______________________________________________
Xfce4-commits mailing list
[email protected]
http://foo-projects.org/mailman/listinfo/xfce4-commits

Reply via email to