diff -rup rpm-4.1/rpmio.orig/fts.c rpm-4.1/rpmio/fts.c --- rpm-4.1/rpmio.orig/fts.c 2002-08-30 12:17:58.000000000 +0100 +++ rpm-4.1/rpmio/fts.c 2003-03-05 23:08:08.000000000 +0000 @@ -53,6 +53,12 @@ static char sccsid[] = "@(#)fts.c 8.6 (B # define _STAT_VER 0 # define __fxstat64(_stat_ver, _fd, _sbp) fstat((_fd), (_sbp)) #endif +#if defined(__CYGWIN__) +# define __errno_location() (&errno) +# define stat64 stat +# define _STAT_VER 0 +# define __fxstat64(_stat_ver, _fd, _sbp) fstat((_fd), (_sbp)) +#endif #include "system.h" #include "fts.h" #include "rpmio.h" diff -rup rpm-4.1/rpmio.orig/fts.h rpm-4.1/rpmio/fts.h --- rpm-4.1/rpmio.orig/fts.h 2002-08-30 12:25:43.000000000 +0100 +++ rpm-4.1/rpmio/fts.h 2003-03-05 23:05:34.000000000 +0000 @@ -51,6 +51,10 @@ # define _LARGEFILE64_SOURCE #endif +#if defined(__CYGWIN__) +# define _D_EXACT_NAMLEN(d) (strlen ((d)->d_name)) +#endif + #endif #include diff -rup rpm-4.1/rpmio.orig/rpmio.h rpm-4.1/rpmio/rpmio.h --- rpm-4.1/rpmio.orig/rpmio.h 2002-08-13 21:42:43.000000000 +0100 +++ rpm-4.1/rpmio/rpmio.h 2003-03-05 22:49:58.000000000 +0000 @@ -10,7 +10,6 @@ #include #include /*@-noparams@*/ -#include /*@=noparams@*/ #include #include diff -rup rpm-4.1/rpmio.orig/rpmrpc.c rpm-4.1/rpmio/rpmrpc.c --- rpm-4.1/rpmio.orig/rpmrpc.c 2002-09-17 15:57:36.000000000 +0100 +++ rpm-4.1/rpmio/rpmrpc.c 2003-03-05 23:11:13.000000000 +0000 @@ -1285,6 +1285,7 @@ static struct dirent * ftpReaddir(DIR * /* XXX glob(3) uses REAL_DIR_ENTRY(dp) test on d_ino */ dp->d_ino = i + 1; /* W2DO? */ +#if !defined(__CYGWIN__) dp->d_reclen = 0; /* W2DO? */ #if !defined(hpux) @@ -1293,6 +1294,7 @@ static struct dirent * ftpReaddir(DIR * dp->d_type = dt[i]; /*@=boundsread@*/ #endif +#endif strncpy(dp->d_name, av[i], sizeof(dp->d_name)); /*@+voidabstract@*/ --- rpm-4.1/lib/signature.c 2002-09-17 15:29:26.000000000 +0100 +++ rpm-4.1x/lib/signature.c 2003-03-06 22:11:54.000000000 +0000 @@ -27,7 +27,7 @@ /*@access pgpDigParams@*/ #if !defined(__GLIBC__) -char ** environ = NULL; +/*char ** environ = NULL;*/ #endif int rpmLookupSignatureType(int action) --- rpm-4.1/tools/Makefile.in 2002-08-31 14:23:21.000000000 +0100 +++ rpm-4.1x/tools/Makefile.in 2003-03-06 22:38:41.000000000 +0000 @@ -263,8 +263,7 @@ EXTRA_PROGRAMS = rpminject$(EXEEXT) rpms bin_PROGRAMS = rpmgraph$(EXEEXT) noinst_PROGRAMS = dump$(EXEEXT) dumpdb$(EXEEXT) rpmarchive$(EXEEXT) \ rpmheader$(EXEEXT) rpmlead$(EXEEXT) rpmsignature$(EXEEXT) -pkgbin_PROGRAMS = javadeps$(EXEEXT) rpmcache$(EXEEXT) \ - striptofile$(EXEEXT) unstripfile$(EXEEXT) +pkgbin_PROGRAMS = javadeps$(EXEEXT) rpmcache$(EXEEXT) PROGRAMS = $(bin_PROGRAMS) $(noinst_PROGRAMS) $(pkgbin_PROGRAMS) dump_SOURCES = dump.c