Compare commits
22 Commits
rawhide
...
main-riscv
Author | SHA1 | Date |
---|---|---|
David Abdurachmanov | 297e58a1e6 | |
David Abdurachmanov | 4871d493fd | |
Lukáš Zaoral | bf0817f5a5 | |
Fedora Release Engineering | 21acecbf27 | |
Kamil Dudka | 6e05a62913 | |
Kamil Dudka | 3040113a7a | |
Kamil Dudka | 1c60283cdf | |
Kamil Dudka | f33a14f44f | |
Lukáš Zaoral | 6bd7dce39d | |
Kamil Dudka | cce55f8f56 | |
Kamil Dudka | 24c306d28d | |
Kamil Dudka | 2c4d4b8151 | |
Kamil Dudka | 43d181cda7 | |
Fedora Release Engineering | f8035e385d | |
Kamil Dudka | ea41467a56 | |
Kamil Dudka | 9d850274b1 | |
Kamil Dudka | ad57d2b8e8 | |
Kamil Dudka | 31230267ea | |
Kamil Dudka | cd953e11dd | |
Kamil Dudka | 23b297bf58 | |
Kamil Dudka | f3c6ff7e2c | |
David Abdurachmanov | 1f29da6364 |
|
@ -1,44 +0,0 @@
|
|||
src/uname.c | 16 +++++++++++++++-
|
||||
1 file changed, 15 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/src/uname.c b/src/uname.c
|
||||
index 6371ca2..1ad8fd7 100644
|
||||
--- a/src/uname.c
|
||||
+++ b/src/uname.c
|
||||
@@ -322,6 +322,12 @@ main (int argc, char **argv)
|
||||
# elif defined __ppc__ || defined __ppc64__
|
||||
element = "powerpc";
|
||||
# endif
|
||||
+#else
|
||||
+ {
|
||||
+ static struct utsname u;
|
||||
+ uname(&u);
|
||||
+ element = u.machine;
|
||||
+ }
|
||||
#endif
|
||||
#if HAVE_SYSINFO && defined SI_ARCHITECTURE
|
||||
if (element == unknown)
|
||||
@@ -347,7 +353,7 @@ main (int argc, char **argv)
|
||||
|
||||
if (toprint & PRINT_HARDWARE_PLATFORM)
|
||||
{
|
||||
- char const *element = unknown;
|
||||
+ char *element = unknown;
|
||||
#if HAVE_SYSINFO && defined SI_PLATFORM
|
||||
{
|
||||
static char hardware_platform[257];
|
||||
@@ -355,6 +361,14 @@ main (int argc, char **argv)
|
||||
hardware_platform, sizeof hardware_platform))
|
||||
element = hardware_platform;
|
||||
}
|
||||
+#else
|
||||
+ {
|
||||
+ static struct utsname u;
|
||||
+ uname(&u);
|
||||
+ element = u.machine;
|
||||
+ if(strlen(element)==4 && element[0]=='i' && element[2]=='8' && element[3]=='6')
|
||||
+ element[1]='3';
|
||||
+ }
|
||||
#endif
|
||||
#ifdef UNAME_HARDWARE_PLATFORM
|
||||
if (element == unknown)
|
|
@ -14,23 +14,23 @@ index b465771..ad42b09 100644
|
|||
+++ b/DIR_COLORS
|
||||
@@ -1,3 +1,7 @@
|
||||
+# This file goes in the /etc directory, and must be world readable.
|
||||
+# You can copy this file to .dir_colors in your $HOME directory to override
|
||||
+# the system defaults.
|
||||
+# You can override the system defaults by making a copy of this file
|
||||
+# as ~/.dir_colors
|
||||
+
|
||||
# Configuration file for dircolors, a utility to help you set the
|
||||
# LS_COLORS environment variable used by GNU ls with the --color option.
|
||||
|
||||
@@ -10,6 +14,9 @@
|
||||
@@ -11,6 +15,9 @@
|
||||
|
||||
# Global config options can be specified before TERM or COLORTERM entries
|
||||
|
||||
+# For compatibility, the pattern "^COLOR.*none" is recognized as a way to
|
||||
+# disable colorization. See https://bugzilla.redhat.com/1349579 for details.
|
||||
+
|
||||
# Below are TERM or COLORTERM entries, which can be glob patterns, which
|
||||
# restrict following config to systems with matching environment variables.
|
||||
COLORTERM ?*
|
||||
@@ -62,7 +69,7 @@ DOOR 01;35 # door
|
||||
# ===================================================================
|
||||
# Terminal filters
|
||||
# ===================================================================
|
||||
@@ -69,7 +76,7 @@ DOOR 01;35 # door
|
||||
BLK 40;33;01 # block device driver
|
||||
CHR 40;33;01 # character device driver
|
||||
ORPHAN 40;31;01 # symlink to nonexistent file, or non-stat'able file ...
|
||||
|
@ -47,23 +47,23 @@ index eab6258..1627b63 100644
|
|||
+# Configuration file for the color ls utility - modified for lighter backgrounds
|
||||
+
|
||||
+# This file goes in the /etc directory, and must be world readable.
|
||||
+# You can copy this file to .dir_colors in your $HOME directory to override
|
||||
+# the system defaults.
|
||||
+# You can override the system defaults by making a copy of this file
|
||||
+# as ~/.dir_colors
|
||||
+
|
||||
# Configuration file for dircolors, a utility to help you set the
|
||||
# LS_COLORS environment variable used by GNU ls with the --color option.
|
||||
|
||||
@@ -10,6 +16,9 @@
|
||||
@@ -11,6 +17,9 @@
|
||||
|
||||
# Global config options can be specified before TERM or COLORTERM entries
|
||||
|
||||
+# For compatibility, the pattern "^COLOR.*none" is recognized as a way to
|
||||
+# disable colorization. See https://bugzilla.redhat.com/1349579 for details.
|
||||
+
|
||||
# Below are TERM or COLORTERM entries, which can be glob patterns, which
|
||||
# restrict following config to systems with matching environment variables.
|
||||
COLORTERM ?*
|
||||
@@ -52,17 +61,17 @@ TERM xterm*
|
||||
# ===================================================================
|
||||
# Terminal filters
|
||||
# ===================================================================
|
||||
@@ -59,17 +68,17 @@ TERM xterm*
|
||||
#NORMAL 00 # no color code at all
|
||||
#FILE 00 # regular file: use no color at all
|
||||
RESET 0 # reset to "normal" color
|
||||
|
@ -86,15 +86,15 @@ index eab6258..1627b63 100644
|
|||
SETUID 37;41 # file that is setuid (u+s)
|
||||
SETGID 30;43 # file that is setgid (g+s)
|
||||
CAPABILITY 00 # file with capability (very expensive to lookup)
|
||||
@@ -71,7 +80,7 @@ OTHER_WRITABLE 34;42 # dir that is other-writable (o+w) and not sticky
|
||||
@@ -78,7 +87,7 @@ OTHER_WRITABLE 34;42 # dir that is other-writable (o+w) and not sticky
|
||||
STICKY 37;44 # dir with the sticky bit set (+t) and not other-writable
|
||||
|
||||
# This is for files with execute permission:
|
||||
-EXEC 01;32
|
||||
+EXEC 00;32
|
||||
|
||||
# List any file extensions like '.gz' or '.tar' that you would like ls
|
||||
# to color below. Put the extension, a space, and the color init string.
|
||||
# ===================================================================
|
||||
# File extension attributes
|
||||
--
|
||||
2.34.1
|
||||
|
||||
|
|
|
@ -1,13 +0,0 @@
|
|||
diff --git a/doc/coreutils.texi b/doc/coreutils.texi
|
||||
index 400e135..47e4480 100644
|
||||
--- a/doc/coreutils.texi
|
||||
+++ b/doc/coreutils.texi
|
||||
@@ -10829,6 +10829,8 @@ incorrect. @xref{Directory Setuid and Setgid}, for how the
|
||||
set-user-ID and set-group-ID bits of directories are inherited unless
|
||||
overridden in this way.
|
||||
|
||||
+Note: The @option{--mode},@option{-m} option only applies to the right-most directories listed on the command line. When combined with @option{--parents}, @option{-p} option, any parent directories are created with @samp{u+wx} modified by umask.
|
||||
+
|
||||
@item -p
|
||||
@itemx --parents
|
||||
@opindex -p
|
|
@ -0,0 +1,28 @@
|
|||
From 2616c6be1c244424617997151c67bcab2dacbcfe Mon Sep 17 00:00:00 2001
|
||||
From: rpm-build <rpm-build>
|
||||
Date: Thu, 31 Aug 2023 14:34:05 +0200
|
||||
Subject: [PATCH] coreutils-9.4-systemd-coredump.patch
|
||||
|
||||
Cherry picked from gnulib upstream commits:
|
||||
* 1e6a26f9312bb47e070f94b17b14dc1a6ffbb74f ("readutmp: fix core dump if --enable-systemd")
|
||||
* 3af1d7b0ce3a8e3ae565e7cea10cee6fd7cb8109 ("readutmp: Fix memory leak introduced by last commit.")
|
||||
---
|
||||
lib/readutmp.c | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/lib/readutmp.c b/lib/readutmp.c
|
||||
index 0173b7e..ec09feb 100644
|
||||
--- a/lib/readutmp.c
|
||||
+++ b/lib/readutmp.c
|
||||
@@ -795,7 +795,7 @@ read_utmp_from_systemd (idx_t *n_entries, STRUCT_UTMP **utmp_buf, int options)
|
||||
{
|
||||
char **sessions;
|
||||
int num_sessions = sd_get_sessions (&sessions);
|
||||
- if (num_sessions >= 0)
|
||||
+ if (num_sessions >= 0 && sessions != NULL)
|
||||
{
|
||||
char **session_ptr;
|
||||
for (session_ptr = sessions; *session_ptr != NULL; session_ptr++)
|
||||
--
|
||||
2.41.0
|
||||
|
|
@ -53,16 +53,16 @@ index 48025b9..c8efa5b 100644
|
|||
|
||||
static struct option const long_options[] =
|
||||
{
|
||||
{"all", no_argument, NULL, 'a'},
|
||||
{"block-size", required_argument, NULL, 'B'},
|
||||
+ {"direct", no_argument, NULL, DIRECT_OPTION},
|
||||
{"inodes", no_argument, NULL, 'i'},
|
||||
{"human-readable", no_argument, NULL, 'h'},
|
||||
{"si", no_argument, NULL, 'H'},
|
||||
{"all", no_argument, nullptr, 'a'},
|
||||
{"block-size", required_argument, nullptr, 'B'},
|
||||
+ {"direct", no_argument, nullptr, DIRECT_OPTION},
|
||||
{"inodes", no_argument, nullptr, 'i'},
|
||||
{"human-readable", no_argument, nullptr, 'h'},
|
||||
{"si", no_argument, nullptr, 'H'},
|
||||
@@ -583,7 +588,10 @@ get_header (void)
|
||||
for (col = 0; col < ncolumns; col++)
|
||||
{
|
||||
char *cell = NULL;
|
||||
char *cell = nullptr;
|
||||
- char const *header = _(columns[col]->caption);
|
||||
+ char const *header = (columns[col]->field == TARGET_FIELD
|
||||
+ && direct_statfs)?
|
||||
|
@ -79,11 +79,11 @@ index 48025b9..c8efa5b 100644
|
|||
+ {
|
||||
+ char *resolved = canonicalize_file_name (name);
|
||||
+ if (resolved)
|
||||
+ {
|
||||
+ get_dev (NULL, resolved, name, NULL, NULL, false, false, NULL, false);
|
||||
+ free (resolved);
|
||||
+ return;
|
||||
+ }
|
||||
+ {
|
||||
+ get_dev (NULL, resolved, name, NULL, NULL, false, false, NULL, false);
|
||||
+ free (resolved);
|
||||
+ return;
|
||||
+ }
|
||||
+ }
|
||||
+
|
||||
if ((S_ISBLK (statp->st_mode) || S_ISCHR (statp->st_mode))
|
||||
|
@ -114,7 +114,7 @@ index 48025b9..c8efa5b 100644
|
|||
+ if (direct_statfs && show_local_fs)
|
||||
+ {
|
||||
+ error (0, 0, _("options --direct and --local (-l) are mutually "
|
||||
+ "exclusive"));
|
||||
+ "exclusive"));
|
||||
+ usage (EXIT_FAILURE);
|
||||
+ }
|
||||
+
|
||||
|
|
|
@ -1,94 +0,0 @@
|
|||
diff --git a/lib/getugroups.c b/lib/getugroups.c
|
||||
index 299bae6..8ece29b 100644
|
||||
--- a/lib/getugroups.c
|
||||
+++ b/lib/getugroups.c
|
||||
@@ -19,6 +19,9 @@
|
||||
|
||||
#include <config.h>
|
||||
|
||||
+/* We do not need this code if getgrouplist(3) is available. */
|
||||
+#ifndef HAVE_GETGROUPLIST
|
||||
+
|
||||
#include "getugroups.h"
|
||||
|
||||
#include <errno.h>
|
||||
@@ -126,3 +129,4 @@ getugroups (int maxcount, gid_t *grouplist, char const *username,
|
||||
}
|
||||
|
||||
#endif /* HAVE_GRP_H */
|
||||
+#endif /* have getgrouplist */
|
||||
diff --git a/lib/mgetgroups.c b/lib/mgetgroups.c
|
||||
index 76474c2..0a9d221 100644
|
||||
--- a/lib/mgetgroups.c
|
||||
+++ b/lib/mgetgroups.c
|
||||
@@ -31,6 +31,7 @@
|
||||
#endif
|
||||
|
||||
#include "getugroups.h"
|
||||
+#include "xalloc.h"
|
||||
#include "xalloc-oversized.h"
|
||||
|
||||
/* Work around an incompatibility of OS X 10.11: getgrouplist
|
||||
@@ -119,9 +120,17 @@ mgetgroups (char const *username, gid_t gid, gid_t **groups)
|
||||
/* else no username, so fall through and use getgroups. */
|
||||
#endif
|
||||
|
||||
- max_n_groups = (username
|
||||
- ? getugroups (0, NULL, username, gid)
|
||||
- : getgroups (0, NULL));
|
||||
+ if (!username)
|
||||
+ max_n_groups = getgroups(0, NULL);
|
||||
+ else
|
||||
+ {
|
||||
+#ifdef HAVE_GETGROUPLIST
|
||||
+ max_n_groups = 0;
|
||||
+ getgrouplist (username, gid, NULL, &max_n_groups);
|
||||
+#else
|
||||
+ max_n_groups = getugroups (0, NULL, username, gid);
|
||||
+#endif
|
||||
+ }
|
||||
|
||||
/* If we failed to count groups because there is no supplemental
|
||||
group support, then return an array containing just GID.
|
||||
@@ -143,10 +152,25 @@ mgetgroups (char const *username, gid_t gid, gid_t **groups)
|
||||
if (g == NULL)
|
||||
return -1;
|
||||
|
||||
- ng = (username
|
||||
- ? getugroups (max_n_groups, g, username, gid)
|
||||
- : getgroups (max_n_groups - (gid != (gid_t) -1),
|
||||
- g + (gid != (gid_t) -1)));
|
||||
+ if (!username)
|
||||
+ ng = getgroups (max_n_groups - (gid != (gid_t)-1), g + (gid != (gid_t)-1));
|
||||
+ else
|
||||
+ {
|
||||
+#ifdef HAVE_GETGROUPLIST
|
||||
+ int e;
|
||||
+ ng = max_n_groups;
|
||||
+ while ((e = getgrouplist (username, gid, g, &ng)) == -1
|
||||
+ && ng > max_n_groups)
|
||||
+ {
|
||||
+ max_n_groups = ng;
|
||||
+ g = xrealloc (g, max_n_groups * sizeof (GETGROUPS_T));
|
||||
+ }
|
||||
+ if (e == -1)
|
||||
+ ng = -1;
|
||||
+#else
|
||||
+ ng = getugroups (max_n_groups, g, username, gid);
|
||||
+#endif
|
||||
+ }
|
||||
|
||||
if (ng < 0)
|
||||
{
|
||||
diff --git a/m4/jm-macros.m4 b/m4/jm-macros.m4
|
||||
index 62777c7..5180243 100644
|
||||
--- a/m4/jm-macros.m4
|
||||
+++ b/m4/jm-macros.m4
|
||||
@@ -68,6 +68,7 @@ AC_DEFUN([coreutils_MACROS],
|
||||
fchown
|
||||
fchmod
|
||||
ftruncate
|
||||
+ getgrouplist
|
||||
iswspace
|
||||
mkfifo
|
||||
mbrlen
|
File diff suppressed because it is too large
Load Diff
|
@ -1,9 +0,0 @@
|
|||
Provides: bundled(gnulib)
|
||||
|
||||
# make it possible to install the latest available Adobe Reader RPM for Linux
|
||||
Provides: /bin/cat
|
||||
Provides: /bin/chmod
|
||||
Provides: /bin/echo
|
||||
Provides: /bin/ln
|
||||
Provides: /bin/rm
|
||||
Provides: /bin/touch
|
|
@ -1,136 +1,87 @@
|
|||
From d70ddb3eb845c494280e7365e2b889242e7e1bb9 Mon Sep 17 00:00:00 2001
|
||||
From 88ba186955add2b230c017749d5622f7a0d62177 Mon Sep 17 00:00:00 2001
|
||||
From: rpm-build <rpm-build>
|
||||
Date: Mon, 4 Oct 2021 08:45:53 +0200
|
||||
Date: Wed, 30 Aug 2023 17:19:58 +0200
|
||||
Subject: [PATCH] coreutils-selinux.patch
|
||||
|
||||
---
|
||||
doc/coreutils.texi | 5 +++++
|
||||
man/chcon.x | 2 +-
|
||||
man/runcon.x | 2 +-
|
||||
src/cp.c | 16 +++++++++++++++-
|
||||
src/install.c | 10 ++++++++--
|
||||
5 files changed, 30 insertions(+), 5 deletions(-)
|
||||
src/cp.c | 19 ++++++++++++++++++-
|
||||
src/install.c | 12 +++++++++++-
|
||||
2 files changed, 29 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/doc/coreutils.texi b/doc/coreutils.texi
|
||||
index 6810c15..19b535c 100644
|
||||
--- a/doc/coreutils.texi
|
||||
+++ b/doc/coreutils.texi
|
||||
@@ -8766,6 +8766,11 @@ done
|
||||
exit $fail
|
||||
@end example
|
||||
|
||||
+@item -c
|
||||
+@cindex SELinux security context information, preserving
|
||||
+Preserve SELinux security context of the original files if possible.
|
||||
+Some file systems don't support storing of SELinux security context.
|
||||
+
|
||||
@item --copy-contents
|
||||
@cindex directories, copying recursively
|
||||
@cindex copying directories recursively
|
||||
diff --git a/man/chcon.x b/man/chcon.x
|
||||
index 8c1ff6f..c84fb96 100644
|
||||
--- a/man/chcon.x
|
||||
+++ b/man/chcon.x
|
||||
@@ -1,4 +1,4 @@
|
||||
[NAME]
|
||||
-chcon \- change file security context
|
||||
+chcon \- change file SELinux security context
|
||||
[DESCRIPTION]
|
||||
.\" Add any additional description here
|
||||
diff --git a/man/runcon.x b/man/runcon.x
|
||||
index d2df13e..5c5f5d8 100644
|
||||
--- a/man/runcon.x
|
||||
+++ b/man/runcon.x
|
||||
@@ -1,5 +1,5 @@
|
||||
[NAME]
|
||||
-runcon \- run command with specified security context
|
||||
+runcon \- run command with specified SELinux security context
|
||||
[DESCRIPTION]
|
||||
Run COMMAND with completely-specified CONTEXT, or with current or
|
||||
transitioned security context modified by one or more of LEVEL,
|
||||
diff --git a/src/cp.c b/src/cp.c
|
||||
index c97a675..89fb8ec 100644
|
||||
index 04a5cbe..7a364e5 100644
|
||||
--- a/src/cp.c
|
||||
+++ b/src/cp.c
|
||||
@@ -191,6 +191,9 @@ Copy SOURCE to DEST, or multiple SOURCE(s) to DIRECTORY.\n\
|
||||
additional attributes: context, links, xattr,\
|
||||
\n\
|
||||
all\n\
|
||||
+"), stdout);
|
||||
+ fputs (_("\
|
||||
+ -c deprecated, same as --preserve=context\n\
|
||||
"), stdout);
|
||||
fputs (_("\
|
||||
--no-preserve=ATTR_LIST don't preserve the specified attributes\n\
|
||||
@@ -954,7 +957,7 @@ main (int argc, char **argv)
|
||||
@@ -989,7 +989,7 @@ main (int argc, char **argv)
|
||||
selinux_enabled = (0 < is_selinux_enabled ());
|
||||
cp_option_init (&x);
|
||||
|
||||
- while ((c = getopt_long (argc, argv, "abdfHilLnprst:uvxPRS:TZ",
|
||||
+ while ((c = getopt_long (argc, argv, "abcdfHilLnprst:uvxPRS:TZ",
|
||||
long_opts, NULL))
|
||||
long_opts, nullptr))
|
||||
!= -1)
|
||||
{
|
||||
@@ -1002,6 +1005,17 @@ main (int argc, char **argv)
|
||||
@@ -1041,6 +1041,23 @@ main (int argc, char **argv)
|
||||
copy_contents = true;
|
||||
break;
|
||||
|
||||
+ case 'c':
|
||||
+ fprintf (stderr, "%s: warning: option '-c' is deprecated, please use '--preserve=context' instead\n", argv[0]);
|
||||
+ if ( x.set_security_context ) {
|
||||
+ (void) fprintf(stderr, "%s: cannot force target context and preserve it\n", argv[0]);
|
||||
+ exit( 1 );
|
||||
+ }
|
||||
+ else if (selinux_enabled) {
|
||||
+ fprintf (stderr, "%s: warning: option '-c' is deprecated,"
|
||||
+ " please use '--preserve=context' instead\n", argv[0]);
|
||||
+ if (x.set_security_context)
|
||||
+ {
|
||||
+ fprintf (stderr,
|
||||
+ "%s: cannot force target context and preserve it\n",
|
||||
+ argv[0]);
|
||||
+ exit (1);
|
||||
+ }
|
||||
+ else if (selinux_enabled)
|
||||
+ {
|
||||
+ x.preserve_security_context = true;
|
||||
+ x.require_preserve_context = true;
|
||||
+ }
|
||||
+ }
|
||||
+ break;
|
||||
+
|
||||
case 'd':
|
||||
x.preserve_links = true;
|
||||
x.dereference = DEREF_NEVER;
|
||||
diff --git a/src/install.c b/src/install.c
|
||||
index c9456fe..2b1bee9 100644
|
||||
index 31a48f1..ce9fa2d 100644
|
||||
--- a/src/install.c
|
||||
+++ b/src/install.c
|
||||
@@ -638,7 +638,7 @@ In the 4th form, create all components of the given DIRECTORY(ies).\n\
|
||||
-v, --verbose print the name of each directory as it is created\n\
|
||||
"), stdout);
|
||||
fputs (_("\
|
||||
- --preserve-context preserve SELinux security context\n\
|
||||
+ -P, --preserve-context preserve SELinux security context (-P deprecated)\n\
|
||||
-Z set SELinux security context of destination\n\
|
||||
file and each created directory to default type\n\
|
||||
--context[=CTX] like -Z, or if CTX is specified then set the\n\
|
||||
@@ -790,7 +790,7 @@ main (int argc, char **argv)
|
||||
@@ -807,7 +807,7 @@ main (int argc, char **argv)
|
||||
dir_arg = false;
|
||||
umask (0);
|
||||
|
||||
- while ((optc = getopt_long (argc, argv, "bcCsDdg:m:o:pt:TvS:Z", long_options,
|
||||
+ while ((optc = getopt_long (argc, argv, "bcCsDdg:m:o:pPt:TvS:Z", long_options,
|
||||
NULL)) != -1)
|
||||
nullptr))
|
||||
!= -1)
|
||||
{
|
||||
switch (optc)
|
||||
@@ -851,6 +851,8 @@ main (int argc, char **argv)
|
||||
@@ -872,6 +872,9 @@ main (int argc, char **argv)
|
||||
no_target_directory = true;
|
||||
break;
|
||||
|
||||
+ case 'P':
|
||||
+ fprintf (stderr, "%s: warning: option '-P' is deprecated, please use '--preserve-context' instead\n", argv[0]);
|
||||
+ fprintf (stderr, "%s: warning: option '-P' is deprecated,"
|
||||
+ " please use '--preserve-context' instead\n", argv[0]);
|
||||
case PRESERVE_CONTEXT_OPTION:
|
||||
if (! selinux_enabled)
|
||||
{
|
||||
@@ -858,6 +860,10 @@ main (int argc, char **argv)
|
||||
@@ -879,6 +882,13 @@ main (int argc, char **argv)
|
||||
"this kernel is not SELinux-enabled"));
|
||||
break;
|
||||
}
|
||||
+ if ( x.set_security_context ) {
|
||||
+ (void) fprintf(stderr, "%s: cannot force target context and preserve it\n", argv[0]);
|
||||
+ exit( 1 );
|
||||
+ }
|
||||
+ if (x.set_security_context)
|
||||
+ {
|
||||
+ fprintf (stderr,
|
||||
+ "%s: cannot force target context and preserve it\n",
|
||||
+ argv[0]);
|
||||
+ exit (1);
|
||||
+ }
|
||||
x.preserve_security_context = true;
|
||||
use_default_selinux_context = false;
|
||||
break;
|
||||
--
|
||||
2.31.1
|
||||
2.41.0
|
||||
|
||||
|
|
|
@ -1,8 +1,9 @@
|
|||
Summary: A set of basic GNU tools commonly used in shell scripts
|
||||
Name: coreutils
|
||||
Version: 9.1
|
||||
Release: 4%{?dist}
|
||||
License: GPLv3+
|
||||
Version: 9.4
|
||||
Release: 1.0.riscv64%{?dist}
|
||||
# some used parts of gnulib are under various variants of LGPL
|
||||
License: GPL-3.0-or-later AND GFDL-1.3-no-invariants-or-later AND LGPL-2.1-or-later AND LGPL-3.0-or-later
|
||||
Url: https://www.gnu.org/software/coreutils/
|
||||
Source0: https://ftp.gnu.org/gnu/%{name}/%{name}-%{version}.tar.xz
|
||||
Source1: https://ftp.gnu.org/gnu/%{name}/%{name}-%{version}.tar.xz.sig
|
||||
|
@ -10,46 +11,35 @@ Source1: https://ftp.gnu.org/gnu/%{name}/%{name}-%{version}.tar.xz.sig
|
|||
# which is linked as project keyring on https://savannah.gnu.org/projects/coreutils
|
||||
Source2: coreutils-keyring.gpg
|
||||
Source50: supported_utils
|
||||
Source51: coreutils-provides.inc
|
||||
Source105: coreutils-colorls.sh
|
||||
Source106: coreutils-colorls.csh
|
||||
|
||||
# do not make coreutils-single depend on /usr/bin/coreutils
|
||||
%global __requires_exclude ^%{_bindir}/coreutils$
|
||||
|
||||
# Make simple backups in correct dir; broken in 9.1
|
||||
Patch1: gnulib-simple-backup-fix.patch
|
||||
|
||||
# disable the test-lock gnulib test prone to deadlock
|
||||
Patch100: coreutils-8.26-test-lock.patch
|
||||
|
||||
# require_selinux_(): use selinuxenabled(8) if available
|
||||
Patch105: coreutils-8.26-selinuxenable.patch
|
||||
Patch101: coreutils-8.26-selinuxenable.patch
|
||||
|
||||
# downstream changes to default DIR_COLORS
|
||||
Patch102: coreutils-8.32-DIR_COLORS.patch
|
||||
# to be removed (#548834)
|
||||
Patch103: coreutils-8.2-uname-processortype.patch
|
||||
#df --direct
|
||||
Patch104: coreutils-df-direct.patch
|
||||
#add note about mkdir --mode behaviour into info documentation(#610559)
|
||||
Patch107: coreutils-8.4-mkdir-modenote.patch
|
||||
|
||||
# sh-utils
|
||||
#add info about TZ envvar to date manpage
|
||||
Patch703: sh-utils-2.0.11-dateman.patch
|
||||
# df --direct
|
||||
Patch104: coreutils-df-direct.patch
|
||||
|
||||
# fix crash with --enable-systemd
|
||||
Patch105: coreutils-9.4-systemd-coredump.patch
|
||||
|
||||
# (sb) lin18nux/lsb compliance - multibyte functionality patch
|
||||
Patch800: coreutils-i18n.patch
|
||||
|
||||
#getgrouplist() patch from Ulrich Drepper.
|
||||
Patch908: coreutils-getgrouplist.patch
|
||||
|
||||
#SELINUX Patch - implements Redhat changes
|
||||
#(upstream did some SELinux implementation unlike with RedHat patch)
|
||||
# downstream SELinux options deprecated since 2009
|
||||
Patch950: coreutils-selinux.patch
|
||||
|
||||
Conflicts: filesystem < 3
|
||||
|
||||
# To avoid clobbering installs
|
||||
Conflicts: coreutils-single
|
||||
|
||||
|
@ -86,7 +76,7 @@ BuildRequires: glibc-langpack-ko
|
|||
Requires: %{name}-common = %{version}-%{release}
|
||||
|
||||
Provides: coreutils-full = %{version}-%{release}
|
||||
%include %{SOURCE51}
|
||||
Provides: bundled(gnulib)
|
||||
Obsoletes: %{name} < 8.24-100
|
||||
|
||||
%description
|
||||
|
@ -98,7 +88,7 @@ Summary: coreutils multicall binary
|
|||
Suggests: coreutils-common
|
||||
Provides: coreutils = %{version}-%{release}
|
||||
Provides: coreutils%{?_isa} = %{version}-%{release}
|
||||
%include %{SOURCE51}
|
||||
Provides: bundled(gnulib)
|
||||
# To avoid clobbering installs
|
||||
Conflicts: coreutils < 8.24-100
|
||||
# Note RPM doesn't support separate buildroots for %files
|
||||
|
@ -187,6 +177,7 @@ for type in separate single; do
|
|||
--cache-file=../config.cache \
|
||||
--enable-install-program=arch \
|
||||
--enable-no-install-program=kill,uptime \
|
||||
--enable-systemd \
|
||||
--with-tty-group \
|
||||
DEFAULT_POSIX2_VERSION=200112 alternative=199209 || :
|
||||
%make_build all V=1
|
||||
|
@ -202,7 +193,11 @@ cp %SOURCE50 .
|
|||
%check
|
||||
for type in separate single; do
|
||||
test $type = 'single' && subdirs='SUBDIRS=.' # Only check gnulib once
|
||||
%ifnarch riscv64
|
||||
(cd $type && make check %{?_smp_mflags} $subdirs)
|
||||
%else
|
||||
(cd $type && make check %{?_smp_mflags} $subdirs || :)
|
||||
%endif
|
||||
done
|
||||
|
||||
%install
|
||||
|
@ -265,6 +260,56 @@ rm -f $RPM_BUILD_ROOT%{_infodir}/dir
|
|||
%license COPYING
|
||||
|
||||
%changelog
|
||||
* Mon Jan 01 2024 David Abdurachmanov <davidlt@rivosinc.com> - 9.4-1.0.riscv64
|
||||
- Ignore tests results on riscv64
|
||||
|
||||
* Fri Sep 15 2023 Lukáš Zaoral <lzaoral@redhat.com> - 9.4-1
|
||||
- new upstream release 9.4 (#2235759)
|
||||
- enable integration with systemd
|
||||
- fix the license field
|
||||
|
||||
* Wed Jul 19 2023 Fedora Release Engineering <releng@fedoraproject.org> - 9.3-2
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild
|
||||
|
||||
* Tue Apr 18 2023 Kamil Dudka <kdudka@redhat.com> - 9.3-1
|
||||
- remove obsolete Provides for absolute paths
|
||||
- new upstream release 9.3
|
||||
|
||||
* Tue Apr 11 2023 Lukáš Zaoral <lzaoral@redhat.com> - 9.2-4
|
||||
- migrate to SPDX license format
|
||||
|
||||
* Fri Mar 24 2023 Kamil Dudka <kdudka@redhat.com> - 9.2-3
|
||||
- copy: fix --reflink=auto to fallback in more cases (#2180056)
|
||||
- cksum: fix reporting of failed checks (#2180056)
|
||||
|
||||
* Wed Mar 22 2023 Kamil Dudka <kdudka@redhat.com> - 9.2-2
|
||||
- coreutils-getgrouplist.patch: drop a patch no longer needed
|
||||
|
||||
* Wed Mar 22 2023 Kamil Dudka <kdudka@redhat.com> - 9.2-1
|
||||
- new upstream release 9.2
|
||||
|
||||
* Thu Jan 19 2023 Fedora Release Engineering <releng@fedoraproject.org>
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild
|
||||
|
||||
* Mon Jan 02 2023 Kamil Dudka <kdudka@redhat.com> - 9.1-10
|
||||
- drop obsolete downstream-only extension of date(1) man page
|
||||
- undocument downstream SELinux options deprecated since 2009
|
||||
|
||||
* Mon Jan 02 2023 Kamil Dudka <kdudka@redhat.com> - 9.1-9
|
||||
- basic support for checking NFSv4 ACLs (#2137866)
|
||||
|
||||
* Mon Sep 19 2022 Kamil Dudka <kdudka@redhat.com> - 9.1-8
|
||||
- remove obsolete extension of mkdir(1) info documentation
|
||||
|
||||
* Tue Aug 23 2022 Kamil Dudka <kdudka@redhat.com> - 9.1-7
|
||||
- remove non-upstream patch for uname -i/-p (#548834)
|
||||
|
||||
* Mon Aug 08 2022 Kamil Dudka <kdudka@redhat.com> - 9.1-6
|
||||
- improve wording of a comment in /etc/DIR_COLORS (#2112593)
|
||||
|
||||
* Mon Aug 08 2022 Kamil Dudka <kdudka@redhat.com> - 9.1-5
|
||||
- improve handling of control characters in unexpand (#2112870)
|
||||
|
||||
* Mon Aug 01 2022 Kamil Dudka <kdudka@redhat.com> - 9.1-4
|
||||
- prevent unexpand from failing on control characters (#2112870)
|
||||
|
||||
|
|
|
@ -1,36 +0,0 @@
|
|||
commit 7347caeb9d902d3fca2c11f69a55a3e578d93bfe
|
||||
Author: Paul Eggert <eggert@cs.ucla.edu>
|
||||
Date: Wed Apr 20 19:34:57 2022 -0700
|
||||
|
||||
backupfile: fix bug when renaming simple backups
|
||||
|
||||
* lib/backupfile.c (backupfile_internal): Fix bug when RENAME
|
||||
and when doing simple backups. Problem reported by Steve Ward in:
|
||||
https://bugs.gnu.org/55029
|
||||
|
||||
diff --git a/lib/backupfile.c b/lib/backupfile.c
|
||||
index 1e9290a187..d9f465a3e0 100644
|
||||
--- a/lib/backupfile.c
|
||||
+++ b/lib/backupfile.c
|
||||
@@ -332,7 +332,7 @@ backupfile_internal (int dir_fd, char const *file,
|
||||
return s;
|
||||
|
||||
DIR *dirp = NULL;
|
||||
- int sdir = AT_FDCWD;
|
||||
+ int sdir = dir_fd;
|
||||
idx_t base_max = 0;
|
||||
while (true)
|
||||
{
|
||||
@@ -371,10 +371,9 @@ backupfile_internal (int dir_fd, char const *file,
|
||||
if (! rename)
|
||||
break;
|
||||
|
||||
- int olddirfd = sdir < 0 ? dir_fd : sdir;
|
||||
- idx_t offset = sdir < 0 ? 0 : base_offset;
|
||||
+ idx_t offset = backup_type == simple_backups ? 0 : base_offset;
|
||||
unsigned flags = backup_type == simple_backups ? 0 : RENAME_NOREPLACE;
|
||||
- if (renameatu (olddirfd, file + offset, sdir, s + offset, flags) == 0)
|
||||
+ if (renameatu (sdir, file + offset, sdir, s + offset, flags) == 0)
|
||||
break;
|
||||
int e = errno;
|
||||
if (! (e == EEXIST && extended))
|
|
@ -1,12 +0,0 @@
|
|||
diff -urNp coreutils-5.97-orig/man/date.x coreutils-5.97/man/date.x
|
||||
--- coreutils-5.97-orig/man/date.x 1999-11-02 15:07:36.000000000 +0100
|
||||
+++ coreutils-5.97/man/date.x 2008-10-15 10:13:31.000000000 +0200
|
||||
@@ -11,3 +11,8 @@ calendar date, time of day, time zone, day of week, relative time,
|
||||
relative date, and numbers. An empty string indicates the beginning
|
||||
of the day. The date string format is more complex than is easily
|
||||
documented here but is fully described in the info documentation.
|
||||
+[ENVIRONMENT]
|
||||
+.TP
|
||||
+TZ
|
||||
+Specifies the timezone, unless overridden by command line parameters.
|
||||
+If neither is specified, the setting from /etc/localtime is used.
|
4
sources
4
sources
|
@ -1,2 +1,2 @@
|
|||
SHA512 (coreutils-9.1.tar.xz.sig) = 9f0766531afd4faa3e2c337730f61db55605cf06729e9c61f644594883732c2e0b1ddb0005b492be309c53e6f45b8ff875398163a48699d52517ea49e9bdbc91
|
||||
SHA512 (coreutils-9.1.tar.xz) = a6ee2c549140b189e8c1b35e119d4289ec27244ec0ed9da0ac55202f365a7e33778b1dc7c4e64d1669599ff81a8297fe4f5adbcc8a3a2f75c919a43cd4b9bdfa
|
||||
SHA512 (coreutils-9.4.tar.xz) = 7c55ee23b685a0462bbbd118b04d25278c902604a0dcf3bf4f8bf81faa0500dee5a7813cba6f586d676c98e520cafd420f16479619305e94ea6798d8437561f5
|
||||
SHA512 (coreutils-9.4.tar.xz.sig) = 9674f783f592c4f3e5c708ff31426ac009bf132fd0005019571bf39c8a1627efb5351c6cecc7faecb1eff8fa2970318666593bffc0eda9c750159e174ef42524
|
||||
|
|
Loading…
Reference in New Issue