Skip to content

Commit 3e38cca

Browse files
committed
gnu patches: move to use quilt
1 parent 8b46229 commit 3e38cca

12 files changed

+55
-41
lines changed

.github/workflows/GnuTests.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ jobs:
105105
run: |
106106
## Install dependencies
107107
sudo apt-get update
108-
sudo apt-get install -y autoconf autopoint bison texinfo gperf gcc g++ gdb python3-pyinotify jq valgrind libexpect-perl libacl1-dev libattr1-dev libcap-dev libselinux1-dev attr
108+
sudo apt-get install -y autoconf autopoint bison texinfo gperf gcc g++ gdb python3-pyinotify jq valgrind libexpect-perl libacl1-dev libattr1-dev libcap-dev libselinux1-dev attr quilt
109109
- name: Add various locales
110110
shell: bash
111111
run: |

util/build-gnu.sh

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -94,6 +94,12 @@ if [ "$(uname)" == "Linux" ]; then
9494
export SELINUX_ENABLED=1
9595
fi
9696

97+
# Set up quilt for patch management
98+
export QUILT_PATCHES="${ME_dir}/gnu-patches/"
99+
cd "$path_GNU"
100+
quilt push -a
101+
cd -
102+
97103
"${MAKE}" PROFILE="${UU_MAKE_PROFILE}"
98104

99105
cp "${UU_BUILD_DIR}/install" "${UU_BUILD_DIR}/ginstall" # The GNU tests rename this script before running, to avoid confusion with the make target
@@ -221,8 +227,6 @@ grep -rlE '/usr/local/bin/\s?/usr/local/bin' init.cfg tests/* | xargs -r sed -Ei
221227
# we should not regress our project just to match what GNU is going.
222228
# So, do some changes on the fly
223229

224-
eval cat "$path_UUTILS/util/gnu-patches/*.patch" | patch -N -r - -d "$path_GNU" -p 1 -i - || true
225-
226230
sed -i -e "s|rm: cannot remove 'e/slink'|rm: cannot remove 'e'|g" tests/rm/fail-eacces.sh
227231

228232
sed -i -e "s|rm: cannot remove 'a/b/file'|rm: cannot remove 'a'|g" tests/rm/cycle.sh

util/gnu-patches/series

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
tests_factor_factor.pl.patch
2+
tests_cksum_base64.patch
3+
tests_comm.pl.patch
4+
tests_cut_error_msg.patch
5+
tests_dup_source.patch
6+
tests_env_env-S.pl.patch
7+
tests_invalid_opt.patch
8+
tests_ls_no_cap.patch
9+
tests_sort_merge.pl.patch
10+
tests_tsort.patch

util/gnu-patches/tests_cksum_base64.patch

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
diff --git a/tests/cksum/cksum-base64.pl b/tests/cksum/cksum-base64.pl
2-
index a037a1628..c6d87d447 100755
3-
--- a/tests/cksum/cksum-base64.pl
4-
+++ b/tests/cksum/cksum-base64.pl
5-
@@ -91,8 +91,8 @@ my $prog = 'cksum';
1+
Index: gnu/tests/cksum/cksum-base64.pl
2+
===================================================================
3+
--- gnu.orig/tests/cksum/cksum-base64.pl
4+
+++ gnu/tests/cksum/cksum-base64.pl
5+
@@ -92,8 +92,8 @@ my $prog = 'cksum';
66
my $fail = run_tests ($program_name, $prog, \@Tests, $save_temps, $verbose);
77

88
# Ensure hash names from cksum --help match those in @pairs above.

util/gnu-patches/tests_comm.pl.patch

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
diff --git a/tests/misc/comm.pl b/tests/misc/comm.pl
2-
index 5bd5f56d7..8322d92ba 100755
3-
--- a/tests/misc/comm.pl
4-
+++ b/tests/misc/comm.pl
1+
Index: gnu/tests/misc/comm.pl
2+
===================================================================
3+
--- gnu.orig/tests/misc/comm.pl
4+
+++ gnu/tests/misc/comm.pl
55
@@ -73,18 +73,24 @@ my @Tests =
66

77
# invalid missing command line argument (1)

util/gnu-patches/tests_cut_error_msg.patch

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
diff --git a/tests/cut/cut.pl b/tests/cut/cut.pl
2-
index 1670db02e..ed633792a 100755
3-
--- a/tests/cut/cut.pl
4-
+++ b/tests/cut/cut.pl
1+
Index: gnu/tests/cut/cut.pl
2+
===================================================================
3+
--- gnu.orig/tests/cut/cut.pl
4+
+++ gnu/tests/cut/cut.pl
55
@@ -29,13 +29,15 @@ my $mb_locale = $ENV{LOCALE_FR_UTF8};
66

77
my $prog = 'cut';

util/gnu-patches/tests_dup_source.patch

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
diff --git a/tests/mv/dup-source.sh b/tests/mv/dup-source.sh
2-
index 7bcd82fc3..0f9005296 100755
3-
--- a/tests/mv/dup-source.sh
4-
+++ b/tests/mv/dup-source.sh
5-
@@ -83,7 +83,7 @@ $i: cannot stat 'a': No such file or directory
1+
Index: gnu/tests/mv/dup-source.sh
2+
===================================================================
3+
--- gnu.orig/tests/mv/dup-source.sh
4+
+++ gnu/tests/mv/dup-source.sh
5+
@@ -83,7 +83,7 @@ $i: cannot stat 'a': No such file or dir
66
$i: cannot stat 'a': No such file or directory
77
$i: cannot stat 'b': No such file or directory
88
$i: cannot move './b' to a subdirectory of itself, 'b/b'

util/gnu-patches/tests_env_env-S.pl.patch

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
diff --git a/tests/env/env-S.pl b/tests/env/env-S.pl
2-
index 710ca82cf..af7cf6efa 100755
3-
--- a/tests/env/env-S.pl
4-
+++ b/tests/env/env-S.pl
1+
Index: gnu/tests/env/env-S.pl
2+
===================================================================
3+
--- gnu.orig/tests/env/env-S.pl
4+
+++ gnu/tests/env/env-S.pl
55
@@ -209,27 +209,28 @@ my @Tests =
66
{ERR=>"$prog: no terminating quote in -S string\n"}],
77
['err5', q[-S'A=B\\q'], {EXIT=>125},

util/gnu-patches/tests_factor_factor.pl.patch

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
diff --git a/tests/factor/factor.pl b/tests/factor/factor.pl
2-
index b1406c266..3d97cd6a5 100755
3-
--- a/tests/factor/factor.pl
4-
+++ b/tests/factor/factor.pl
1+
Index: gnu/tests/factor/factor.pl
2+
===================================================================
3+
--- gnu.orig/tests/factor/factor.pl
4+
+++ gnu/tests/factor/factor.pl
55
@@ -61,12 +61,14 @@ my @Tests =
66
# Map newer glibc diagnostic to expected.
77
# Also map OpenBSD 5.1's "unknown option" to expected "invalid option".

util/gnu-patches/tests_invalid_opt.patch

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
diff --git a/tests/misc/invalid-opt.pl b/tests/misc/invalid-opt.pl
2-
index 4b9c4c184..4ccd89482 100755
3-
--- a/tests/misc/invalid-opt.pl
4-
+++ b/tests/misc/invalid-opt.pl
1+
Index: gnu/tests/misc/invalid-opt.pl
2+
===================================================================
3+
--- gnu.orig/tests/misc/invalid-opt.pl
4+
+++ gnu/tests/misc/invalid-opt.pl
55
@@ -74,23 +74,13 @@ foreach my $prog (@built_programs)
66
defined $out
77
or $out = '';

0 commit comments

Comments
 (0)