summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sysutils/coreutils/Makefile25
-rw-r--r--sysutils/coreutils/PLIST22
-rw-r--r--sysutils/coreutils/distinfo29
-rw-r--r--sysutils/coreutils/patches/patch-aa13
-rw-r--r--sysutils/coreutils/patches/patch-ab29
-rw-r--r--sysutils/coreutils/patches/patch-ac10
-rw-r--r--sysutils/coreutils/patches/patch-ad18
-rw-r--r--sysutils/coreutils/patches/patch-ae15
-rw-r--r--sysutils/coreutils/patches/patch-af15
-rw-r--r--sysutils/coreutils/patches/patch-ag34
-rw-r--r--sysutils/coreutils/patches/patch-ah8
-rw-r--r--sysutils/coreutils/patches/patch-ai8
-rw-r--r--sysutils/coreutils/patches/patch-aj13
-rw-r--r--sysutils/coreutils/patches/patch-ak73
-rw-r--r--sysutils/coreutils/patches/patch-ba15
-rw-r--r--sysutils/coreutils/patches/patch-bb17
-rw-r--r--sysutils/coreutils/patches/patch-ca36
-rw-r--r--sysutils/coreutils/patches/patch-cb24
18 files changed, 89 insertions, 315 deletions
diff --git a/sysutils/coreutils/Makefile b/sysutils/coreutils/Makefile
index 644564c7c2e..9cba6c135b3 100644
--- a/sysutils/coreutils/Makefile
+++ b/sysutils/coreutils/Makefile
@@ -1,12 +1,11 @@
-# $NetBSD: Makefile,v 1.37 2007/02/22 19:27:11 wiz Exp $
+# $NetBSD: Makefile,v 1.38 2007/07/18 11:25:19 tnn Exp $
-DISTNAME= coreutils-5.2.1
-PKGREVISION= 2
+DISTNAME= coreutils-6.9
CATEGORIES= sysutils
MASTER_SITES= ${MASTER_SITE_GNU:=coreutils/}
EXTRACT_SUFX= .tar.bz2
-MAINTAINER= recht@NetBSD.org
+MAINTAINER= tech-pkg@NetBSD.org
HOMEPAGE= http://www.gnu.org/software/coreutils/
COMMENT= GNU basic file, shell and text manipulation utilities
@@ -15,21 +14,19 @@ NOT_FOR_PLATFORM= NetBSD-2.0[D-H]-*
CONFLICTS= fileutils-[0-9]* linuxls-[0-9]* sh-utils-[0-9]* textutils-[0-9]*
GNU_CONFIGURE= YES
-USE_TOOLS+= msgfmt perl
+USE_TOOLS+= msgfmt msgmerge perl xgettext
USE_PKGLOCALEDIR= YES
INFO_FILES= # PLIST
TEST_TARGET= check
-SUBST_CLASSES+= root
-SUBST_MESSAGE.root= Fixing hardcoded root.
-SUBST_STAGE.root= post-patch
-SUBST_FILES.root= src/Makefile.in
-SUBST_SED.root= -e 's, root , ${ROOT_USER} ,g'
-
.include "../../mk/bsd.prefs.mk"
+.if ${OPSYS} == "Interix"
+CONFIGURE_ENV+= ac_list_mounted_fs=found
+.endif
+
# Exclude programs from PLIST which aren't built on a platform.
.if ${OPSYS} == "Interix"
PLIST_SUBST+= COREUTILS_HAVE_HOSTID="@comment "
@@ -37,6 +34,12 @@ PLIST_SUBST+= COREUTILS_HAVE_HOSTID="@comment "
PLIST_SUBST+= COREUTILS_HAVE_HOSTID=""
.endif
+# XXX - this hack is bound to cause fallout on some platform at some point.
+# How can we determine the API version of the builtin gettext?
+.if ${OPSYS} != "Linux"
+CONFIGURE_ENV+= gt_cv_func_gnugettext3_libintl=yes
+.endif
+
CONFIGURE_ARGS+= --program-prefix=${GNU_PROGRAM_PREFIX:Q}
# if GNU_PROGRAM_PREFIX == 'g'
# devel/id-utils installs a 'gid' program, so conflict with it
diff --git a/sysutils/coreutils/PLIST b/sysutils/coreutils/PLIST
index 22816de8327..9847b2a1d94 100644
--- a/sysutils/coreutils/PLIST
+++ b/sysutils/coreutils/PLIST
@@ -1,5 +1,6 @@
-@comment $NetBSD: PLIST,v 1.7 2006/04/17 07:07:33 jlam Exp $
+@comment $NetBSD: PLIST,v 1.8 2007/07/18 11:25:19 tnn Exp $
bin/${GNU_PROGRAM_PREFIX}[
+bin/${GNU_PROGRAM_PREFIX}base64
bin/${GNU_PROGRAM_PREFIX}basename
bin/${GNU_PROGRAM_PREFIX}cat
bin/${GNU_PROGRAM_PREFIX}chgrp
@@ -60,7 +61,12 @@ bin/${GNU_PROGRAM_PREFIX}rm
bin/${GNU_PROGRAM_PREFIX}rmdir
bin/${GNU_PROGRAM_PREFIX}seq
bin/${GNU_PROGRAM_PREFIX}sha1sum
+bin/${GNU_PROGRAM_PREFIX}sha224sum
+bin/${GNU_PROGRAM_PREFIX}sha256sum
+bin/${GNU_PROGRAM_PREFIX}sha384sum
+bin/${GNU_PROGRAM_PREFIX}sha512sum
bin/${GNU_PROGRAM_PREFIX}shred
+bin/${GNU_PROGRAM_PREFIX}shuf
bin/${GNU_PROGRAM_PREFIX}sleep
bin/${GNU_PROGRAM_PREFIX}sort
bin/${GNU_PROGRAM_PREFIX}split
@@ -90,6 +96,7 @@ bin/${GNU_PROGRAM_PREFIX}who
bin/${GNU_PROGRAM_PREFIX}whoami
bin/${GNU_PROGRAM_PREFIX}yes
info/coreutils.info
+man/man1/${GNU_PROGRAM_PREFIX}base64.1
man/man1/${GNU_PROGRAM_PREFIX}basename.1
man/man1/${GNU_PROGRAM_PREFIX}cat.1
man/man1/${GNU_PROGRAM_PREFIX}chgrp.1
@@ -150,7 +157,12 @@ man/man1/${GNU_PROGRAM_PREFIX}rm.1
man/man1/${GNU_PROGRAM_PREFIX}rmdir.1
man/man1/${GNU_PROGRAM_PREFIX}seq.1
man/man1/${GNU_PROGRAM_PREFIX}sha1sum.1
+man/man1/${GNU_PROGRAM_PREFIX}sha224sum.1
+man/man1/${GNU_PROGRAM_PREFIX}sha256sum.1
+man/man1/${GNU_PROGRAM_PREFIX}sha384sum.1
+man/man1/${GNU_PROGRAM_PREFIX}sha512sum.1
man/man1/${GNU_PROGRAM_PREFIX}shred.1
+man/man1/${GNU_PROGRAM_PREFIX}shuf.1
man/man1/${GNU_PROGRAM_PREFIX}sleep.1
man/man1/${GNU_PROGRAM_PREFIX}sort.1
man/man1/${GNU_PROGRAM_PREFIX}split.1
@@ -181,6 +193,7 @@ man/man1/${GNU_PROGRAM_PREFIX}whoami.1
man/man1/${GNU_PROGRAM_PREFIX}yes.1
share/locale/af/LC_MESSAGES/coreutils.mo
share/locale/be/LC_MESSAGES/coreutils.mo
+share/locale/bg/LC_MESSAGES/coreutils.mo
share/locale/ca/LC_MESSAGES/coreutils.mo
share/locale/cs/LC_MESSAGES/coreutils.mo
share/locale/da/LC_MESSAGES/coreutils.mo
@@ -188,6 +201,7 @@ share/locale/de/LC_MESSAGES/coreutils.mo
share/locale/el/LC_MESSAGES/coreutils.mo
share/locale/es/LC_MESSAGES/coreutils.mo
share/locale/et/LC_MESSAGES/coreutils.mo
+share/locale/eu/LC_MESSAGES/coreutils.mo
share/locale/fi/LC_MESSAGES/coreutils.mo
share/locale/fr/LC_MESSAGES/coreutils.mo
share/locale/ga/LC_MESSAGES/coreutils.mo
@@ -196,7 +210,6 @@ share/locale/hu/LC_MESSAGES/coreutils.mo
share/locale/it/LC_MESSAGES/coreutils.mo
share/locale/ja/LC_MESSAGES/coreutils.mo
share/locale/ko/LC_MESSAGES/coreutils.mo
-share/locale/lg/LC_MESSAGES/coreutils.mo
share/locale/ms/LC_MESSAGES/coreutils.mo
share/locale/nb/LC_MESSAGES/coreutils.mo
share/locale/nl/LC_MESSAGES/coreutils.mo
@@ -205,6 +218,7 @@ share/locale/pl/LC_MESSAGES/coreutils.mo
share/locale/pt/LC_MESSAGES/coreutils.mo
share/locale/pt_BR/LC_MESSAGES/coreutils.mo
share/locale/ru/LC_MESSAGES/coreutils.mo
+share/locale/rw/LC_MESSAGES/coreutils.mo
share/locale/sk/LC_MESSAGES/coreutils.mo
share/locale/sl/LC_MESSAGES/coreutils.mo
share/locale/sv/LC_MESSAGES/coreutils.mo
@@ -213,6 +227,7 @@ share/locale/zh_CN/LC_MESSAGES/coreutils.mo
share/locale/zh_TW/LC_MESSAGES/coreutils.mo
share/locale/af/LC_TIME/coreutils.mo
share/locale/be/LC_TIME/coreutils.mo
+share/locale/bg/LC_TIME/coreutils.mo
share/locale/ca/LC_TIME/coreutils.mo
share/locale/cs/LC_TIME/coreutils.mo
share/locale/da/LC_TIME/coreutils.mo
@@ -220,6 +235,7 @@ share/locale/de/LC_TIME/coreutils.mo
share/locale/el/LC_TIME/coreutils.mo
share/locale/es/LC_TIME/coreutils.mo
share/locale/et/LC_TIME/coreutils.mo
+share/locale/eu/LC_TIME/coreutils.mo
share/locale/fi/LC_TIME/coreutils.mo
share/locale/fr/LC_TIME/coreutils.mo
share/locale/ga/LC_TIME/coreutils.mo
@@ -228,7 +244,6 @@ share/locale/hu/LC_TIME/coreutils.mo
share/locale/it/LC_TIME/coreutils.mo
share/locale/ja/LC_TIME/coreutils.mo
share/locale/ko/LC_TIME/coreutils.mo
-share/locale/lg/LC_TIME/coreutils.mo
share/locale/ms/LC_TIME/coreutils.mo
share/locale/nb/LC_TIME/coreutils.mo
share/locale/nl/LC_TIME/coreutils.mo
@@ -237,6 +252,7 @@ share/locale/pl/LC_TIME/coreutils.mo
share/locale/pt/LC_TIME/coreutils.mo
share/locale/pt_BR/LC_TIME/coreutils.mo
share/locale/ru/LC_TIME/coreutils.mo
+share/locale/rw/LC_TIME/coreutils.mo
share/locale/sk/LC_TIME/coreutils.mo
share/locale/sl/LC_TIME/coreutils.mo
share/locale/sv/LC_TIME/coreutils.mo
diff --git a/sysutils/coreutils/distinfo b/sysutils/coreutils/distinfo
index 8a13e98c8bd..11f89079cb3 100644
--- a/sysutils/coreutils/distinfo
+++ b/sysutils/coreutils/distinfo
@@ -1,20 +1,11 @@
-$NetBSD: distinfo,v 1.11 2006/01/09 22:45:08 joerg Exp $
+$NetBSD: distinfo,v 1.12 2007/07/18 11:25:19 tnn Exp $
-SHA1 (coreutils-5.2.1.tar.bz2) = 1028755ae0fa9be840576e4837004cf5a9981c45
-RMD160 (coreutils-5.2.1.tar.bz2) = a72bdb360371c026e77281ae0d543bdcce55a4e6
-Size (coreutils-5.2.1.tar.bz2) = 4270776 bytes
-SHA1 (patch-aa) = 36c3a4a810bdc9efd7b0c3a6dc4203e0cfcbfae5
-SHA1 (patch-ab) = 630fad1a3b044b99cb8cefeb3518631e71e46db9
-SHA1 (patch-ac) = b7a527c55bba56f01f02692dc113bd912b6e7dce
-SHA1 (patch-ad) = 3b61ead0225d17667d27a6a0e379d5aabc75b0df
-SHA1 (patch-ae) = 1dda20cdc03336694b2c8dd42de159168de1f28d
-SHA1 (patch-af) = cd7deba7a8ecdf17b39668a9d5a80323e1a02c06
-SHA1 (patch-ag) = 20deb326e88b2d0a275b4a16b84ea43a9e280d79
-SHA1 (patch-ah) = 3f56cd4e1c657551f4967928ebea19df23c0d850
-SHA1 (patch-ai) = e9964ba9e3fd6ec8f2728e53439a960a6dd0a32f
-SHA1 (patch-aj) = dfa6030d09550133ae83c7d2b316f6ab0431810f
-SHA1 (patch-ak) = 2ad4d42f852db0efc9d3dee37bee43dc7d499f8d
-SHA1 (patch-ba) = 3867a17e0ad8f7c87c91ec8e511972a6255062dd
-SHA1 (patch-bb) = ade6f8e0aa73478270f568dba25e79f825374c02
-SHA1 (patch-ca) = 4d99367f5d4b35f6897b4321f2166c94ab93f9d8
-SHA1 (patch-cb) = de1896d77504b8fd82da8e2cdf6b8a82a31ba09f
+SHA1 (coreutils-6.9.tar.bz2) = 10310a78c4e1d9f742f3815ac28e9bf1086a5885
+RMD160 (coreutils-6.9.tar.bz2) = c6ae65204b2e9c234a1140f39a8be1ee5cdcaab7
+Size (coreutils-6.9.tar.bz2) = 5384378 bytes
+SHA1 (patch-ab) = 676fd4eaeedf8f94ac6d1894fd16491ce8412cb0
+SHA1 (patch-ac) = bed05fb1ba7102e9042357caea32767c88bff332
+SHA1 (patch-ad) = eb10a960047957b4142e06aff363cf35249df70c
+SHA1 (patch-ag) = 3e24b8e025a151eb7bed4c778a326da5eed09ded
+SHA1 (patch-ah) = 3a101d45bb5fc502dd5402e0df587494d1844597
+SHA1 (patch-ai) = 6b05293d6d151ca28ed897c47a1dad729306b770
diff --git a/sysutils/coreutils/patches/patch-aa b/sysutils/coreutils/patches/patch-aa
deleted file mode 100644
index e3bb8ccc149..00000000000
--- a/sysutils/coreutils/patches/patch-aa
+++ /dev/null
@@ -1,13 +0,0 @@
-$NetBSD: patch-aa,v 1.3 2004/03/29 09:22:51 recht Exp $
-
---- lib/Makefile.in.orig 2004-03-11 09:57:59.000000000 +0100
-+++ lib/Makefile.in 2004-03-13 14:29:07.000000000 +0100
-@@ -905,7 +905,7 @@
-
- install-data-am:
-
--install-exec-am: install-exec-local
-+install-exec-am:
-
- install-info: install-info-am
-
diff --git a/sysutils/coreutils/patches/patch-ab b/sysutils/coreutils/patches/patch-ab
index f0807ab7b28..03aaded5822 100644
--- a/sysutils/coreutils/patches/patch-ab
+++ b/sysutils/coreutils/patches/patch-ab
@@ -1,20 +1,20 @@
-$NetBSD: patch-ab,v 1.7 2005/08/28 09:07:21 tron Exp $
+$NetBSD: patch-ab,v 1.8 2007/07/18 11:25:20 tnn Exp $
---- lib/mountlist.c.orig Mon Jan 26 03:58:12 2004
+--- lib/mountlist.c.orig 2007-01-26 23:16:55.000000000 +0100
+++ lib/mountlist.c
-@@ -173,6 +173,11 @@ xatoi (char *cp)
+@@ -174,6 +174,11 @@
#if MOUNTED_GETMNTINFO
+# if defined(__NetBSD__) && (__NetBSD_Version__ > 299000000)
+# define statfs statvfs
-+# define HAVE_F_FSTYPENAME_IN_STATFS 1
++# define HAVE_F_FSTYPENAME_IN_STATFS 1
+# endif
+
- # if ! HAVE_F_FSTYPENAME_IN_STATFS
+ # if ! HAVE_STRUCT_STATFS_F_FSTYPENAME
static char *
- fstype_to_string (short t)
-@@ -296,6 +301,11 @@ fstype_to_string (int t)
+ fstype_to_string (short int t)
+@@ -296,6 +301,10 @@ fstype_to_string (int t)
}
#endif /* MOUNTED_VMOUNT */
@@ -22,15 +22,13 @@ $NetBSD: patch-ab,v 1.7 2005/08/28 09:07:21 tron Exp $
+# include <dirent.h>
+# include <sys/statvfs.h>
+#endif
-+
- /* Return a list of the currently mounted filesystems, or NULL on error.
- Add each entry to the tail of the list so that they stay in order.
- If NEED_FS_TYPE is nonzero, ensure that the filesystem type fields in
-@@ -804,6 +814,50 @@ read_filesystem_list (int need_fs_type)
- free (entries);
+
+ #if defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2
+
+@@ -859,6 +868,50 @@ read_file_system_list (bool need_fs_type
}
#endif /* MOUNTED_VMOUNT. */
-+
+
+#ifdef __INTERIX /* Interix. */
+ {
+ DIR *devfs = opendir ("/dev/fs");
@@ -74,6 +72,7 @@ $NetBSD: patch-ab,v 1.7 2005/08/28 09:07:21 tron Exp $
+ }
+ }
+#endif
-
++
*mtail = NULL;
return mount_list;
+
diff --git a/sysutils/coreutils/patches/patch-ac b/sysutils/coreutils/patches/patch-ac
index 55995e7c497..4696654a7b5 100644
--- a/sysutils/coreutils/patches/patch-ac
+++ b/sysutils/coreutils/patches/patch-ac
@@ -1,10 +1,10 @@
-$NetBSD: patch-ac,v 1.6 2005/08/28 09:07:21 tron Exp $
+$NetBSD: patch-ac,v 1.7 2007/07/18 11:25:20 tnn Exp $
---- src/stat.c.orig Thu Feb 5 08:46:12 2004
+--- src/stat.c.orig 2007-03-18 22:36:43.000000000 +0100
+++ src/stat.c
-@@ -86,6 +86,12 @@
- # endif
- #endif
+@@ -148,6 +148,12 @@ statfs (char const *filename, struct fs_
+ #define hextobin(c) ((c) >= 'a' && (c) <= 'f' ? (c) - 'a' + 10 : \
+ (c) >= 'A' && (c) <= 'F' ? (c) - 'A' + 10 : (c) - '0')
+#if (defined(__NetBSD__) && (__NetBSD_Version__ > 299000000)) || defined(__INTERIX)
+#include <sys/statvfs.h>
diff --git a/sysutils/coreutils/patches/patch-ad b/sysutils/coreutils/patches/patch-ad
index d4d811ef193..7af0f00ac44 100644
--- a/sysutils/coreutils/patches/patch-ad
+++ b/sysutils/coreutils/patches/patch-ad
@@ -1,8 +1,8 @@
-$NetBSD: patch-ad,v 1.1 2005/03/21 14:44:08 tv Exp $
+$NetBSD: patch-ad,v 1.2 2007/07/18 11:25:20 tnn Exp $
---- src/su.c.orig Wed Jan 21 17:27:02 2004
+--- src/su.c.orig 2007-03-18 22:36:43.000000000 +0100
+++ src/su.c
-@@ -141,6 +141,12 @@
+@@ -119,6 +119,12 @@
/* The user to become if none is specified. */
#define DEFAULT_USER "root"
@@ -13,23 +13,23 @@ $NetBSD: patch-ad,v 1.1 2005/03/21 14:44:08 tv Exp $
+#endif
+
char *crypt ();
- char *getpass ();
char *getusershell ();
-@@ -291,9 +297,13 @@ correct_password (const struct passwd *p
+ void endusershell ();
+@@ -245,9 +251,13 @@ correct_password (const struct passwd *p
error (0, 0, _("getpass: cannot open /dev/tty"));
- return 0;
+ return false;
}
+#ifdef __INTERIX
+ return setuser (pw->pw_name, unencrypted, SU_CHECK) == 0;
+#else
encrypted = crypt (unencrypted, correct);
memset (unencrypted, 0, strlen (unencrypted));
- return strcmp (encrypted, correct) == 0;
+ return STREQ (encrypted, correct);
+#endif
}
/* Update `environ' for the new shell based on PW, with SHELL being
-@@ -343,6 +353,9 @@ modify_environment (const struct passwd
+@@ -297,6 +307,9 @@ modify_environment (const struct passwd
static void
change_identity (const struct passwd *pw)
{
@@ -39,7 +39,7 @@ $NetBSD: patch-ad,v 1.1 2005/03/21 14:44:08 tv Exp $
#ifdef HAVE_INITGROUPS
errno = 0;
if (initgroups (pw->pw_name, pw->pw_gid) == -1)
-@@ -353,6 +366,7 @@ change_identity (const struct passwd *pw
+@@ -307,6 +320,7 @@ change_identity (const struct passwd *pw
error (EXIT_FAIL, errno, _("cannot set group id"));
if (setuid (pw->pw_uid))
error (EXIT_FAIL, errno, _("cannot set user id"));
diff --git a/sysutils/coreutils/patches/patch-ae b/sysutils/coreutils/patches/patch-ae
deleted file mode 100644
index 5e57ff99c8c..00000000000
--- a/sysutils/coreutils/patches/patch-ae
+++ /dev/null
@@ -1,15 +0,0 @@
-$NetBSD: patch-ae,v 1.1 2005/03/21 14:44:08 tv Exp $
-
---- src/setuidgid.c.orig Wed Jan 21 17:27:02 2004
-+++ src/setuidgid.c
-@@ -106,8 +106,10 @@ main (int argc, char **argv)
- error (SETUIDGID_FAILURE, errno,
- _("unknown user-ID: %s"), quote (user_id));
-
-+#if HAVE_SETGROUPS
- if (setgroups (1, &pwd->pw_gid))
- error (SETUIDGID_FAILURE, errno, _("cannot set supplemental group"));
-+#endif
-
- if (setgid (pwd->pw_gid))
- error (SETUIDGID_FAILURE, errno,
diff --git a/sysutils/coreutils/patches/patch-af b/sysutils/coreutils/patches/patch-af
deleted file mode 100644
index d88cf713b9c..00000000000
--- a/sysutils/coreutils/patches/patch-af
+++ /dev/null
@@ -1,15 +0,0 @@
-$NetBSD: patch-af,v 1.1 2005/03/21 14:44:08 tv Exp $
-
---- src/system.h.orig Thu Feb 5 04:23:23 2004
-+++ src/system.h
-@@ -92,6 +92,10 @@ you must include <sys/types.h> before in
- #endif
- #undef HAVE_MAJOR
-
-+#if !defined(makedev) && defined(mkdev)
-+# define makedev(a, b) (mkdev((a), (b)))
-+#endif
-+
- #if HAVE_UTIME_H
- # include <utime.h>
- #endif
diff --git a/sysutils/coreutils/patches/patch-ag b/sysutils/coreutils/patches/patch-ag
index d679db38391..3cb934803ed 100644
--- a/sysutils/coreutils/patches/patch-ag
+++ b/sysutils/coreutils/patches/patch-ag
@@ -1,28 +1,14 @@
-$NetBSD: patch-ag,v 1.1 2005/03/21 14:44:08 tv Exp $
+$NetBSD: patch-ag,v 1.2 2007/07/18 11:25:20 tnn Exp $
---- src/shred.c.orig Wed Jan 21 17:27:02 2004
+--- src/shred.c.orig 2007-03-18 22:36:43.000000000 +0100
+++ src/shred.c
-@@ -1398,7 +1398,11 @@ wipename (char *oldname, char const *qol
- {
- if (dir_fd < 0
- || (fdatasync (dir_fd) < 0 && fsync (dir_fd) < 0))
+@@ -316,7 +316,9 @@ dosync (int fd, char const *qname)
+ return -1;
+ }
+
+#if HAVE_SYNC
- sync (); /* Force directory out */
-+#else
-+ ; /* No sync(2) call */
+ sync ();
+#endif
- if (flags->verbose)
- {
- /*
-@@ -1431,7 +1435,11 @@ wipename (char *oldname, char const *qol
- free (newname);
- err = unlink (oldname);
- if (dir_fd < 0 || (fdatasync (dir_fd) < 0 && fsync (dir_fd) < 0))
-+#if HAVE_SYNC
- sync ();
-+#else
-+ ; /* No sync(2) call */
-+#endif
- close (dir_fd);
- if (!err && flags->verbose)
- error (0, 0, _("%s: removed"), qoldname);
+ return 0;
+ }
+
diff --git a/sysutils/coreutils/patches/patch-ah b/sysutils/coreutils/patches/patch-ah
index aa3953ea310..f255543bd0d 100644
--- a/sysutils/coreutils/patches/patch-ah
+++ b/sysutils/coreutils/patches/patch-ah
@@ -1,9 +1,9 @@
-$NetBSD: patch-ah,v 1.1 2005/03/21 14:44:08 tv Exp $
+$NetBSD: patch-ah,v 1.2 2007/07/18 11:25:21 tnn Exp $
---- src/df.c.orig Tue Jan 27 10:55:38 2004
+--- src/df.c.orig 2007-03-18 22:36:43.000000000 +0100
+++ src/df.c
-@@ -923,8 +923,10 @@ main (int argc, char **argv)
- _("%scannot read table of mounted filesystems"), warning);
+@@ -943,8 +943,10 @@ main (int argc, char **argv)
+ _("%scannot read table of mounted file systems"), warning);
}
+#if HAVE_SYNC
diff --git a/sysutils/coreutils/patches/patch-ai b/sysutils/coreutils/patches/patch-ai
index 792aef87851..7701c25afbf 100644
--- a/sysutils/coreutils/patches/patch-ai
+++ b/sysutils/coreutils/patches/patch-ai
@@ -1,9 +1,9 @@
-$NetBSD: patch-ai,v 1.1 2005/03/21 14:44:08 tv Exp $
+$NetBSD: patch-ai,v 1.2 2007/07/18 11:25:21 tnn Exp $
---- src/sync.c.orig Wed Jan 21 17:27:02 2004
+--- src/sync.c.orig 2007-03-18 22:36:43.000000000 +0100
+++ src/sync.c
-@@ -70,6 +70,8 @@ main (int argc, char **argv)
- if (1 < argc)
+@@ -73,6 +73,8 @@ main (int argc, char **argv)
+ if (optind < argc)
error (0, 0, _("ignoring all arguments"));
+#if HAVE_SYNC
diff --git a/sysutils/coreutils/patches/patch-aj b/sysutils/coreutils/patches/patch-aj
deleted file mode 100644
index 9e2ae236a7c..00000000000
--- a/sysutils/coreutils/patches/patch-aj
+++ /dev/null
@@ -1,13 +0,0 @@
-$NetBSD: patch-aj,v 1.1 2006/01/09 22:45:08 joerg Exp $
-
---- src/ls.c.orig 2006-01-03 17:15:34.000000000 +0000
-+++ src/ls.c
-@@ -2528,7 +2528,7 @@ gobble_file (const char *name, enum file
- else
- {
- f->filetype = type;
--#if HAVE_STRUCT_DIRENT_D_TYPE
-+#if HAVE_STRUCT_DIRENT_D_TYPE && defined(DTTOIF)
- f->stat.st_mode = DTTOIF (type);
- #endif
- blocks = 0;
diff --git a/sysutils/coreutils/patches/patch-ak b/sysutils/coreutils/patches/patch-ak
deleted file mode 100644
index 967d1846f8b..00000000000
--- a/sysutils/coreutils/patches/patch-ak
+++ /dev/null
@@ -1,73 +0,0 @@
-$NetBSD: patch-ak,v 1.1 2006/01/09 22:45:08 joerg Exp $
-
---- src/paste.c.orig 2006-01-03 17:23:26.000000000 +0000
-+++ src/paste.c
-@@ -52,14 +52,6 @@
- /* Indicates that no delimiter should be added in the current position. */
- #define EMPTY_DELIM '\0'
-
--static FILE dummy_closed;
--/* Element marking a file that has reached EOF and been closed. */
--#define CLOSED (&dummy_closed)
--
--static FILE dummy_endlist;
--/* Element marking end of list of open files. */
--#define ENDLIST (&dummy_endlist)
--
- /* Name this program was run with. */
- char *program_name;
-
-@@ -76,6 +68,8 @@ static char *delims;
- /* A pointer to the character after the end of `delims'. */
- static char const *delim_end;
-
-+#define CLOSED NULL
-+
- static struct option const longopts[] =
- {
- {"serial", no_argument, 0, 's'},
-@@ -156,7 +150,7 @@ paste_parallel (size_t nfiles, char **fn
- store the delimiters for closed files. */
- char *delbuf;
- FILE **fileptr; /* Streams open to the files to process. */
-- size_t files_open; /* Number of files still open to process. */
-+ size_t files_open, last_file; /* Number of files still open to process. */
- bool opened_stdin = false; /* true if any fopen got fd == STDIN_FILENO */
-
- delbuf = xmalloc (nfiles + 2);
-@@ -183,7 +177,7 @@ paste_parallel (size_t nfiles, char **fn
- }
- }
-
-- fileptr[files_open] = ENDLIST;
-+ last_file = files_open;
-
- if (opened_stdin && have_read_stdin)
- error (EXIT_FAILURE, 0, _("standard input is closed"));
-@@ -200,7 +194,7 @@ paste_parallel (size_t nfiles, char **fn
- size_t delims_saved = 0; /* Number of delims saved in `delbuf'. */
- size_t i;
-
-- for (i = 0; fileptr[i] != ENDLIST && files_open; i++)
-+ for (i = 0; i < last_file && files_open; i++)
- {
- int chr IF_LINT (= 0); /* Input character. */
- size_t line_length = 0; /* Number of chars in line. */
-@@ -246,7 +240,7 @@ paste_parallel (size_t nfiles, char **fn
- files_open--;
- }
-
-- if (fileptr[i + 1] == ENDLIST)
-+ if (i + 1 == last_file)
- {
- /* End of this output line.
- Is this the end of the whole thing? */
-@@ -277,7 +271,7 @@ paste_parallel (size_t nfiles, char **fn
- somedone = true;
-
- /* Except for last file, replace last newline with delim. */
-- if (fileptr[i + 1] != ENDLIST)
-+ if (i + 1 != last_file)
- {
- if (chr != '\n' && chr != EOF)
- putc (chr, stdout);
diff --git a/sysutils/coreutils/patches/patch-ba b/sysutils/coreutils/patches/patch-ba
deleted file mode 100644
index afed34e532e..00000000000
--- a/sysutils/coreutils/patches/patch-ba
+++ /dev/null
@@ -1,15 +0,0 @@
-$NetBSD: patch-ba,v 1.1 2005/03/21 14:44:08 tv Exp $
-
---- m4/ls-mntd-fs.m4.orig Mon Jan 26 04:18:10 2004
-+++ m4/ls-mntd-fs.m4
-@@ -271,6 +271,10 @@ if test -z "$ac_list_mounted_fs"; then
- fi
- fi
-
-+case $host in
-+*-interix3*) ac_list_mounted_fs=found;;
-+esac
-+
- if test -z "$ac_list_mounted_fs"; then
- AC_MSG_ERROR([could not determine how to read list of mounted filesystems])
- # FIXME -- no need to abort building the whole package
diff --git a/sysutils/coreutils/patches/patch-bb b/sysutils/coreutils/patches/patch-bb
deleted file mode 100644
index 777d9b4f329..00000000000
--- a/sysutils/coreutils/patches/patch-bb
+++ /dev/null
@@ -1,17 +0,0 @@
-$NetBSD: patch-bb,v 1.1 2005/03/21 14:44:08 tv Exp $
-
---- m4/jm-macros.m4.orig Sat Dec 20 12:57:18 2003
-+++ m4/jm-macros.m4
-@@ -94,10 +94,12 @@ AC_DEFUN([jm_MACROS],
- mempcpy \
- mkfifo \
- realpath \
-+ setgroups \
- sethostname \
- strchr \
- strerror \
- strrchr \
-+ sync \
- sysctl \
- sysinfo \
- wcrtomb \
diff --git a/sysutils/coreutils/patches/patch-ca b/sysutils/coreutils/patches/patch-ca
deleted file mode 100644
index 7eb29f981e5..00000000000
--- a/sysutils/coreutils/patches/patch-ca
+++ /dev/null
@@ -1,36 +0,0 @@
-$NetBSD: patch-ca,v 1.2 2006/01/09 22:45:08 joerg Exp $
-
---- configure.orig 2004-03-11 08:58:11.000000000 +0000
-+++ configure
-@@ -27323,6 +27323,10 @@ _ACEOF
- fi
- fi
-
-+case $host in
-+*-interix3*) ac_list_mounted_fs=found;;
-+esac
-+
- if test -z "$ac_list_mounted_fs"; then
- { { echo "$as_me:$LINENO: error: could not determine how to read list of mounted filesystems" >&5
- echo "$as_me: error: could not determine how to read list of mounted filesystems" >&2;}
-@@ -39680,6 +39684,7 @@ done
-
-
- fp_headers='
-+# include <stdio.h>
- # if HAVE_STDIO_EXT_H
- # include <stdio_ext.h>
- # endif
-@@ -44983,10 +44988,12 @@ for ac_func in \
- mempcpy \
- mkfifo \
- realpath \
-+ setgroups \
- sethostname \
- strchr \
- strerror \
- strrchr \
-+ sync \
- sysctl \
- sysinfo \
- wcrtomb \
diff --git a/sysutils/coreutils/patches/patch-cb b/sysutils/coreutils/patches/patch-cb
deleted file mode 100644
index ee738b76fc1..00000000000
--- a/sysutils/coreutils/patches/patch-cb
+++ /dev/null
@@ -1,24 +0,0 @@
-$NetBSD: patch-cb,v 1.1 2005/03/21 14:44:08 tv Exp $
-
---- config.hin.orig Thu Mar 11 03:59:16 2004
-+++ config.hin
-@@ -669,6 +669,9 @@
- /* Define to 1 if you have run the test for working tzset. */
- #undef HAVE_RUN_TZSET_TEST
-
-+/* Define to 1 if you have the `setgroups' function. */
-+#undef HAVE_SETGROUPS
-+
- /* Define to 1 if you have the `sethostname' function. */
- #undef HAVE_SETHOSTNAME
-
-@@ -920,6 +923,9 @@
-
- /* Define if struct stat has an st_dm_mode member. */
- #undef HAVE_ST_DM_MODE
-+
-+/* Define to 1 if you have the `sync' function. */
-+#undef HAVE_SYNC
-
- /* Define to 1 if you have the `sysctl' function. */
- #undef HAVE_SYSCTL