diff -Naur gnome-vfs-1.0.3.old/configure gnome-vfs-1.0.3.new/configure --- gnome-vfs-1.0.3.old/configure Fri Oct 12 17:35:44 2001 +++ gnome-vfs-1.0.3.new/configure Thu Oct 18 02:21:50 2001 @@ -3563,7 +3563,7 @@ ;; darwin* | rhapsody*) - allow_undefined_flag='-undefined suppress' + allow_undefined_flag='-flat_namespace -undefined suppress' # FIXME: Relying on posixy $() will cause problems for # cross-compilation, but unfortunately the echo tests do not # yet detect zsh echo's removal of \ escapes. @@ -6719,7 +6719,7 @@ -ALL_LINGUAS="az ca da de el es fi fr ga gl hu it ja ko lt nl nn no pl pt pt_BR ro ru sk sl sv tr uk wa zh_TW" +ALL_LINGUAS="az ca da de el es fi fr ga gl hu it ja ko lt nl nn no pl pt pt_BR ro ru sk sl sv tr uk wa" # Extract the first word of "ranlib", so it can be a program name with args. set dummy ranlib; ac_word=$2 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 @@ -8635,7 +8635,7 @@ fi -for ac_func in getdtablesize open64 lseek64 statvfs +for ac_func in getdtablesize open64 lseek64 statvfs strptime readdir_r do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 echo "configure:8642: checking for $ac_func" >&5 diff -Naur gnome-vfs-1.0.3.old/configure.in gnome-vfs-1.0.3.new/configure.in --- gnome-vfs-1.0.3.old/configure.in Fri Oct 12 17:29:13 2001 +++ gnome-vfs-1.0.3.new/configure.in Thu Oct 18 02:21:50 2001 @@ -184,11 +184,11 @@ AM_GNOME_SIZE_T AM_GNOME_OFF_T -ALL_LINGUAS="az ca da de el es fi fr ga gl hu it ja ko lt nl nn no pl pt pt_BR ro ru sk sl sv tr uk wa zh_TW" +ALL_LINGUAS="az ca da de el es fi fr ga gl hu it ja ko lt nl nn no pl pt pt_BR ro ru sk sl sv tr uk wa" AM_GNOME_GETTEXT AC_FUNC_ALLOCA -AC_CHECK_FUNCS(getdtablesize open64 lseek64 statvfs) +AC_CHECK_FUNCS(getdtablesize open64 lseek64 statvfs strptime readdir_r) AC_REPLACE_FUNCS(getdelim) dnl diff -Naur gnome-vfs-1.0.3.old/devel-docs/Makefile.am gnome-vfs-1.0.3.new/devel-docs/Makefile.am --- gnome-vfs-1.0.3.old/devel-docs/Makefile.am Thu May 31 07:06:32 2001 +++ gnome-vfs-1.0.3.new/devel-docs/Makefile.am Wed Oct 17 21:43:16 2001 @@ -3,7 +3,7 @@ TEXT_FILES = \ gnome-vfs-mime-type-handling.txt -docdir = $(prefix)/doc +docdir = $(prefix)/share/doc doc_DATA = # devel-docs/Makefile.am ends here diff -Naur gnome-vfs-1.0.3.old/devel-docs/Makefile.in gnome-vfs-1.0.3.new/devel-docs/Makefile.in --- gnome-vfs-1.0.3.old/devel-docs/Makefile.in Sat Oct 13 01:08:18 2001 +++ gnome-vfs-1.0.3.new/devel-docs/Makefile.in Wed Oct 17 21:43:24 2001 @@ -179,7 +179,7 @@ TEXT_FILES = gnome-vfs-mime-type-handling.txt -docdir = $(prefix)/doc +docdir = $(prefix)/share/doc doc_DATA = mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs CONFIG_HEADER = ../config.h diff -Naur gnome-vfs-1.0.3.old/libgnomevfs/Makefile.am gnome-vfs-1.0.3.new/libgnomevfs/Makefile.am --- gnome-vfs-1.0.3.old/libgnomevfs/Makefile.am Thu Oct 11 17:11:57 2001 +++ gnome-vfs-1.0.3.new/libgnomevfs/Makefile.am Wed Oct 17 02:19:54 2001 @@ -91,6 +91,7 @@ $(NULL) libgnomevfs_la_SOURCES = \ + strptime.c \ fnmatch.c \ gnome-vfs-application-registry.c \ gnome-vfs-async-ops.c \ diff -Naur gnome-vfs-1.0.3.old/libgnomevfs/Makefile.in gnome-vfs-1.0.3.new/libgnomevfs/Makefile.in --- gnome-vfs-1.0.3.old/libgnomevfs/Makefile.in Sat Oct 13 01:08:04 2001 +++ gnome-vfs-1.0.3.new/libgnomevfs/Makefile.in Wed Oct 17 02:43:50 2001 @@ -192,7 +192,7 @@ libgnomevfsinclude_HEADERS = gnome-vfs-application-registry.h gnome-vfs-async-ops.h gnome-vfs-backend.h gnome-vfs-cancellable-ops.h gnome-vfs-cancellation.h gnome-vfs-configuration.h gnome-vfs-context.h gnome-vfs-directory-filter.h gnome-vfs-directory.h gnome-vfs-file-info.h gnome-vfs-file-size.h gnome-vfs-find-directory.h gnome-vfs-handle.h gnome-vfs-inet-connection.h gnome-vfs-init.h gnome-vfs-iobuf.h gnome-vfs-messages.h gnome-vfs-method.h gnome-vfs-mime-handlers.h gnome-vfs-mime-info.h gnome-vfs-mime-magic.h gnome-vfs-mime-monitor.h gnome-vfs-mime-sniff-buffer.h gnome-vfs-mime.h gnome-vfs-module-callback-module-api.h gnome-vfs-module-callback.h gnome-vfs-module-shared.h gnome-vfs-module.h gnome-vfs-ops.h gnome-vfs-parse-ls.h gnome-vfs-private-utils.h gnome-vfs-private.h gnome-vfs-regexp-filter.h gnome-vfs-result.h gnome-vfs-seekable.h gnome-vfs-shellpattern-filter.h gnome-vfs-socket-buffer.h gnome-vfs-socket.h gnome-vfs-ssl-private.h gnome-vfs-ssl.h gnome-vfs-standard-callbacks.h gnome-vfs-transform.h gnome-vfs-types.h gnome-vfs-uri.h gnome-vfs-utils.h gnome-vfs-xfer.h gnome-vfs.h $(NULL) -libgnomevfs_la_SOURCES = fnmatch.c gnome-vfs-application-registry.c gnome-vfs-async-ops.c gnome-vfs-backend.c gnome-vfs-cancellable-ops.c gnome-vfs-cancellation.c gnome-vfs-configuration.c gnome-vfs-context.c gnome-vfs-directory-filter.c gnome-vfs-directory.c gnome-vfs-file-info.c gnome-vfs-find-directory.c gnome-vfs-handle.c gnome-vfs-i18n.c gnome-vfs-inet-connection.c gnome-vfs-init.c gnome-vfs-iobuf.c gnome-vfs-messages.c gnome-vfs-method.c gnome-vfs-mime-handlers.c gnome-vfs-mime-info.c gnome-vfs-mime-magic.c gnome-vfs-mime-monitor.c gnome-vfs-mime-sniff-buffer.c gnome-vfs-mime.c gnome-vfs-module-callback-module-api.c gnome-vfs-module-callback-private.c gnome-vfs-module-callback.c gnome-vfs-module-shared.c gnome-vfs-module.c gnome-vfs-ops.c gnome-vfs-parse-ls.c gnome-vfs-private-utils.c gnome-vfs-private.c gnome-vfs-process.c gnome-vfs-regexp-filter.c gnome-vfs-result.c gnome-vfs-seekable.c gnome-vfs-shellpattern-filter.c gnome-vfs-socket-buffer.c gnome-vfs-socket.c gnome-vfs-ssl.c gnome-vfs-transform.c gnome-vfs-uri.c gnome-vfs-utils.c gnome-vfs-xfer.c fnmatch.h gnome-vfs-mime-private.h gnome-vfs-mime-sniff-buffer-private.h gnome-vfs-module-callback-private.h gnome-vfs-process.h $(NULL) +libgnomevfs_la_SOURCES = strptime.c fnmatch.c gnome-vfs-application-registry.c gnome-vfs-async-ops.c gnome-vfs-backend.c gnome-vfs-cancellable-ops.c gnome-vfs-cancellation.c gnome-vfs-configuration.c gnome-vfs-context.c gnome-vfs-directory-filter.c gnome-vfs-directory.c gnome-vfs-file-info.c gnome-vfs-find-directory.c gnome-vfs-handle.c gnome-vfs-i18n.c gnome-vfs-inet-connection.c gnome-vfs-init.c gnome-vfs-iobuf.c gnome-vfs-messages.c gnome-vfs-method.c gnome-vfs-mime-handlers.c gnome-vfs-mime-info.c gnome-vfs-mime-magic.c gnome-vfs-mime-monitor.c gnome-vfs-mime-sniff-buffer.c gnome-vfs-mime.c gnome-vfs-module-callback-module-api.c gnome-vfs-module-callback-private.c gnome-vfs-module-callback.c gnome-vfs-module-shared.c gnome-vfs-module.c gnome-vfs-ops.c gnome-vfs-parse-ls.c gnome-vfs-private-utils.c gnome-vfs-private.c gnome-vfs-process.c gnome-vfs-regexp-filter.c gnome-vfs-result.c gnome-vfs-seekable.c gnome-vfs-shellpattern-filter.c gnome-vfs-socket-buffer.c gnome-vfs-socket.c gnome-vfs-ssl.c gnome-vfs-transform.c gnome-vfs-uri.c gnome-vfs-utils.c gnome-vfs-xfer.c fnmatch.h gnome-vfs-mime-private.h gnome-vfs-mime-sniff-buffer-private.h gnome-vfs-module-callback-private.h gnome-vfs-process.h $(NULL) noinst_HEADERS = gnome-vfs-backend-private.h @@ -212,7 +212,7 @@ LIBS = @LIBS@ libgnomevfs_la_LDFLAGS = libgnomevfs_la_DEPENDENCIES = -libgnomevfs_la_OBJECTS = fnmatch.lo gnome-vfs-application-registry.lo \ +libgnomevfs_la_OBJECTS = strptime.lo fnmatch.lo gnome-vfs-application-registry.lo \ gnome-vfs-async-ops.lo gnome-vfs-backend.lo \ gnome-vfs-cancellable-ops.lo gnome-vfs-cancellation.lo \ gnome-vfs-configuration.lo gnome-vfs-context.lo \ @@ -408,6 +408,7 @@ || cp -p $$d/$$file $(distdir)/$$file || :; \ fi; \ done +strptime.lo strptime.o : strptime.c fnmatch.lo fnmatch.o : fnmatch.c ../config.h fnmatch.h gnome-vfs-app-context.lo gnome-vfs-app-context.o : \ gnome-vfs-app-context.c ../config.h gnome-vfs-app-context.h \ diff -Naur gnome-vfs-1.0.3.old/libgnomevfs/fnmatch.c gnome-vfs-1.0.3.new/libgnomevfs/fnmatch.c --- gnome-vfs-1.0.3.old/libgnomevfs/fnmatch.c Sat Jul 21 14:40:32 2001 +++ gnome-vfs-1.0.3.new/libgnomevfs/fnmatch.c Wed Oct 17 02:19:54 2001 @@ -54,6 +54,9 @@ /* Match STRING against the filename pattern PATTERN, returning zero if it matches, nonzero if not. */ +#if defined(__APPLE__) +__private_extern__ +#endif int fnmatch (pattern, string, flags) const char *pattern; diff -Naur gnome-vfs-1.0.3.old/libgnomevfs/gnome-vfs-mime.h gnome-vfs-1.0.3.new/libgnomevfs/gnome-vfs-mime.h --- gnome-vfs-1.0.3.old/libgnomevfs/gnome-vfs-mime.h Sat Jul 21 14:40:33 2001 +++ gnome-vfs-1.0.3.new/libgnomevfs/gnome-vfs-mime.h Tue Oct 16 22:14:40 2001 @@ -25,13 +25,13 @@ #define GNOME_VFS_MIME_H #include +#include #include #include #include #include #include #include -#include #ifdef __cplusplus extern "C" { diff -Naur gnome-vfs-1.0.3.old/libgnomevfs/strptime.c gnome-vfs-1.0.3.new/libgnomevfs/strptime.c --- gnome-vfs-1.0.3.old/libgnomevfs/strptime.c Thu Jan 1 09:00:00 1970 +++ gnome-vfs-1.0.3.new/libgnomevfs/strptime.c Wed Oct 17 02:19:54 2001 @@ -0,0 +1,366 @@ +/* + * Copyright (c) 1994 Powerdog Industries. All rights reserved. + * + * Redistribution and use in source and binary forms, without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer + * in the documentation and/or other materials provided with the + * distribution. + * 3. All advertising materials mentioning features or use of this + * software must display the following acknowledgement: + * This product includes software developed by Powerdog Industries. + * 4. The name of Powerdog Industries may not be used to endorse or + * promote products derived from this software without specific prior + * written permission. + * + * THIS SOFTWARE IS PROVIDED BY POWERDOG INDUSTRIES ``AS IS'' AND ANY + * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR + * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE POWERDOG INDUSTRIES BE + * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, + * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#ifndef HAVE_STRPTIME + +#include +#include +#include +#include + +#define asizeof(a) (sizeof (a) / sizeof ((a)[0])) + +struct dtconv { + char *abbrev_month_names[12]; + char *month_names[12]; + char *abbrev_weekday_names[7]; + char *weekday_names[7]; + char *time_format; + char *sdate_format; + char *dtime_format; + char *am_string; + char *pm_string; + char *ldate_format; +}; + +static struct dtconv En_US = { + { "Jan", "Feb", "Mar", "Apr", "May", "Jun", + "Jul", "Aug", "Sep", "Oct", "Nov", "Dec" }, + { "January", "February", "March", "April", + "May", "June", "July", "August", + "September", "October", "November", "December" }, + { "Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat" }, + { "Sunday", "Monday", "Tuesday", "Wednesday", + "Thursday", "Friday", "Saturday" }, + "%H:%M:%S", + "%m/%d/%y", + "%a %b %e %T %Z %Y", + "AM", + "PM", + "%A, %B, %e, %Y" +}; + +#if defined(__APPLE__) +__private_extern__ +#endif +char * +strptime(char *buf, char *fmt, struct tm *tm) +{ + char c, *ptr; + int i, len = 0; + + ptr = fmt; + while (*ptr != 0) + { + if (*buf == 0) + break; + + c = *ptr++; + + if (c != '%') + { + if (isspace(c)) + while (*buf != 0 && isspace(*buf)) + buf++; + else if (c != *buf++) + return 0; + continue; + } + + c = *ptr++; + switch (c) + { + case 0: + case '%': + if (*buf++ != '%') + return 0; + break; + + case 'C': + buf = strptime(buf, En_US.ldate_format, tm); + if (buf == 0) + return 0; + break; + + case 'c': + buf = strptime(buf, "%x %X", tm); + if (buf == 0) + return 0; + break; + + case 'D': + buf = strptime(buf, "%m/%d/%y", tm); + if (buf == 0) + return 0; + break; + + case 'R': + buf = strptime(buf, "%H:%M", tm); + if (buf == 0) + return 0; + break; + + case 'r': + buf = strptime(buf, "%I:%M:%S %p", tm); + if (buf == 0) + return 0; + break; + + case 'T': + buf = strptime(buf, "%H:%M:%S", tm); + if (buf == 0) + return 0; + break; + + case 'X': + buf = strptime(buf, En_US.time_format, tm); + if (buf == 0) + return 0; + break; + + case 'x': + buf = strptime(buf, En_US.sdate_format, tm); + if (buf == 0) + return 0; + break; + + case 'j': + if (!isdigit(*buf)) + return 0; + + for (i = 0; *buf != 0 && isdigit(*buf); buf++) + { + i *= 10; + i += *buf - '0'; + } + if (i > 365) + return 0; + + tm->tm_yday = i; + break; + + case 'M': + case 'S': + if (*buf == 0 || isspace(*buf)) + break; + + if (!isdigit(*buf)) + return 0; + + for (i = 0; *buf != 0 && isdigit(*buf); buf++) + { + i *= 10; + i += *buf - '0'; + } + if (i > 59) + return 0; + + if (c == 'M') + tm->tm_min = i; + else + tm->tm_sec = i; + + if (*buf != 0 && isspace(*buf)) + while (*ptr != 0 && !isspace(*ptr)) + ptr++; + break; + + case 'H': + case 'I': + case 'k': + case 'l': + if (!isdigit(*buf)) + return 0; + + for (i = 0; *buf != 0 && isdigit(*buf); buf++) + { + i *= 10; + i += *buf - '0'; + } + if (c == 'H' || c == 'k') { + if (i > 23) + return 0; + } else if (i > 11) + return 0; + + tm->tm_hour = i; + + if (*buf != 0 && isspace(*buf)) + while (*ptr != 0 && !isspace(*ptr)) + ptr++; + break; + + case 'p': + len = strlen(En_US.am_string); + if (strncasecmp(buf, En_US.am_string, len) == 0) + { + if (tm->tm_hour > 12) + return 0; + if (tm->tm_hour == 12) + tm->tm_hour = 0; + buf += len; + break; + } + + len = strlen(En_US.pm_string); + if (strncasecmp(buf, En_US.pm_string, len) == 0) + { + if (tm->tm_hour > 12) + return 0; + if (tm->tm_hour != 12) + tm->tm_hour += 12; + buf += len; + break; + } + + return 0; + + case 'A': + case 'a': + for (i = 0; i < asizeof(En_US.weekday_names); i++) + { + len = strlen(En_US.weekday_names[i]); + if (strncasecmp(buf, + En_US.weekday_names[i], + len) == 0) + break; + + len = strlen(En_US.abbrev_weekday_names[i]); + if (strncasecmp(buf, + En_US.abbrev_weekday_names[i], + len) == 0) + break; + } + if (i == asizeof(En_US.weekday_names)) + return 0; + + tm->tm_wday = i; + buf += len; + break; + + case 'd': + case 'e': + if (!isdigit(*buf)) + return 0; + + for (i = 0; *buf != 0 && isdigit(*buf); buf++) + { + i *= 10; + i += *buf - '0'; + } + if (i > 31) + return 0; + + tm->tm_mday = i; + + if (*buf != 0 && isspace(*buf)) + while (*ptr != 0 && !isspace(*ptr)) + ptr++; + break; + + case 'B': + case 'b': + case 'h': + for (i = 0; i < asizeof(En_US.month_names); i++) + { + len = strlen(En_US.month_names[i]); + if (strncasecmp(buf, + En_US.month_names[i], + len) == 0) + break; + + len = strlen(En_US.abbrev_month_names[i]); + if (strncasecmp(buf, + En_US.abbrev_month_names[i], + len) == 0) + break; + } + if (i == asizeof(En_US.month_names)) + return 0; + + tm->tm_mon = i; + buf += len; + break; + + case 'm': + if (!isdigit(*buf)) + return 0; + + for (i = 0; *buf != 0 && isdigit(*buf); buf++) + { + i *= 10; + i += *buf - '0'; + } + if (i < 1 || i > 12) + return 0; + + tm->tm_mon = i - 1; + + if (*buf != 0 && isspace(*buf)) + while (*ptr != 0 && !isspace(*ptr)) + ptr++; + break; + + case 'Y': + case 'y': + if (*buf == 0 || isspace(*buf)) + break; + + if (!isdigit(*buf)) + return 0; + + for (i = 0; *buf != 0 && isdigit(*buf); buf++) + { + i *= 10; + i += *buf - '0'; + } + if (c == 'y' && i < 69) /* Unix Epoch pivot year */ + i += 100; + if (c == 'Y') + i -= 1900; + if (i < 0) + return 0; + + tm->tm_year = i; + + if (*buf != 0 && isspace(*buf)) + while (*ptr != 0 && !isspace(*ptr)) + ptr++; + break; + } + } + + return buf; +} + +#endif /* !HAVE_STRPTIME */ + diff -Naur gnome-vfs-1.0.3.old/libgnomevfs-pthread/Makefile.am gnome-vfs-1.0.3.new/libgnomevfs-pthread/Makefile.am --- gnome-vfs-1.0.3.old/libgnomevfs-pthread/Makefile.am Thu Oct 11 17:11:58 2001 +++ gnome-vfs-1.0.3.new/libgnomevfs-pthread/Makefile.am Thu Oct 18 02:04:06 2001 @@ -31,4 +31,4 @@ gnome-vfs-job.c libgnomevfs_pthread_la_LDFLAGS = \ - -module -avoid-version + -export_dynamic -avoid-version -module diff -Naur gnome-vfs-1.0.3.old/libgnomevfs-pthread/Makefile.in gnome-vfs-1.0.3.new/libgnomevfs-pthread/Makefile.in --- gnome-vfs-1.0.3.old/libgnomevfs-pthread/Makefile.in Sat Oct 13 01:08:06 2001 +++ gnome-vfs-1.0.3.new/libgnomevfs-pthread/Makefile.in Thu Oct 18 02:04:21 2001 @@ -185,7 +185,7 @@ libgnomevfs_pthread_la_SOURCES = gnome-vfs-pthread.c gnome-vfs-thread-pool.c gnome-vfs-async-job-map.c gnome-vfs-async-ops.c gnome-vfs-job-slave.c gnome-vfs-job.c -libgnomevfs_pthread_la_LDFLAGS = -module -avoid-version +libgnomevfs_pthread_la_LDFLAGS = -export_dynamic -avoid-version -module mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs CONFIG_HEADER = ../config.h diff -Naur gnome-vfs-1.0.3.old/modules/Makefile.am gnome-vfs-1.0.3.new/modules/Makefile.am --- gnome-vfs-1.0.3.old/modules/Makefile.am Fri Oct 12 17:19:14 2001 +++ gnome-vfs-1.0.3.new/modules/Makefile.am Wed Oct 17 21:49:58 2001 @@ -34,7 +34,7 @@ CDDA_LTLIBS = endif -module_flags = -export_dynamic -avoid-version +module_flags = -export_dynamic -avoid-version -module modulesdir = $(libdir)/vfs/modules modules_LTLIBRARIES = \ @@ -107,6 +107,7 @@ libvfs_test_la_SOURCES = \ test-method.c +libvfs_test_la_LDFLAGS = $(module_flags) libvfs_test_la_LIBADD = $(XML_LIBS) ### `gzip' method @@ -126,6 +127,7 @@ libftp_la_SOURCES = \ ftp-method.c \ ftp-method.h +libftp_la_LDFLAGS = $(module_flags) ### `gconf' method diff -Naur gnome-vfs-1.0.3.old/modules/Makefile.in gnome-vfs-1.0.3.new/modules/Makefile.in --- gnome-vfs-1.0.3.old/modules/Makefile.in Sat Oct 13 01:08:08 2001 +++ gnome-vfs-1.0.3.new/modules/Makefile.in Wed Oct 17 21:49:58 2001 @@ -185,7 +185,7 @@ @HAVE_CDDA_TRUE@CDDA_LTLIBS = libcdda.la @HAVE_CDDA_FALSE@CDDA_LTLIBS = -module_flags = -export_dynamic -avoid-version +module_flags = -export_dynamic -avoid-version -module modulesdir = $(libdir)/vfs/modules modules_LTLIBRARIES = $(CDDA_LTLIBS) libextfs.la libfile.la libvfs-test.la $(HTTP_LTLIBS) libbzip2.la libgzip.la libftp.la libvfs-pipe.la libvfs-translate.la libdesktop.la $(NULL) @@ -236,6 +236,8 @@ libvfs_test_la_SOURCES = test-method.c +libvfs_test_la_LDFLAGS = $(module_flags) + libvfs_test_la_LIBADD = $(XML_LIBS) ### `gzip' method @@ -253,6 +255,7 @@ ### `ftp' method libftp_la_SOURCES = ftp-method.c ftp-method.h +libftp_la_LDFLAGS = $(module_flags) ### `gconf' method @@ -306,7 +309,6 @@ libextfs_la_OBJECTS = extfs-method.lo libfile_la_LIBADD = libfile_la_OBJECTS = file-method.lo -libvfs_test_la_LDFLAGS = libvfs_test_la_DEPENDENCIES = libvfs_test_la_OBJECTS = test-method.lo libhttp_la_DEPENDENCIES = @@ -315,7 +317,6 @@ libbzip2_la_OBJECTS = bzip2-method.lo libgzip_la_DEPENDENCIES = libgzip_la_OBJECTS = gzip-method.lo -libftp_la_LDFLAGS = libftp_la_LIBADD = libftp_la_OBJECTS = ftp-method.lo libvfs_pipe_la_DEPENDENCIES = diff -Naur gnome-vfs-1.0.3.old/modules/file-method.c gnome-vfs-1.0.3.new/modules/file-method.c --- gnome-vfs-1.0.3.old/modules/file-method.c Tue Oct 2 03:17:55 2001 +++ gnome-vfs-1.0.3.new/modules/file-method.c Wed Oct 17 04:49:12 2001 @@ -42,13 +42,12 @@ #define _(String) (String) #define N_(String) (String) #endif +#include #include #include #include #include -#include #include -#include #include #include #include @@ -64,6 +63,44 @@ #include "gnome-vfs-module-shared.h" #include "file-method.h" + +#ifndef HAVE_READDIR_R +#include + +static int +readdir_r (DIR *dirp, + struct dirent *entry, + struct dirent **result) +{ + static int readdir_mutex_inited = 0; + static pthread_mutex_t readdir_mutex; + struct dirent *tmp; + int old_errno; + + if (!readdir_mutex_inited) { + readdir_mutex_inited = 1; + pthread_mutex_init (&readdir_mutex, NULL); + } + + old_errno = errno; + errno = 0; + + pthread_mutex_lock (&readdir_mutex); + if ((tmp = readdir(dirp)) != NULL) + memcpy (entry, tmp, sizeof (*entry)); + pthread_mutex_unlock (&readdir_mutex); + + if (errno && !tmp) + return errno; + + if (!errno) + errno = old_errno; + + *result = (tmp) ? entry : NULL; + + return 0; +} +#endif /* HAVE_READDIR_R */ #ifdef PATH_MAX #define GET_PATH_MAX() PATH_MAX