diff options
Diffstat (limited to 'meta/recipes-extended/bash')
12 files changed, 345 insertions, 216 deletions
diff --git a/meta/recipes-extended/bash/bash.inc b/meta/recipes-extended/bash/bash.inc index db326660ea..634209c911 100644 --- a/meta/recipes-extended/bash/bash.inc +++ b/meta/recipes-extended/bash/bash.inc | |||
@@ -1,12 +1,13 @@ | |||
1 | SUMMARY = "An sh-compatible command language interpreter" | 1 | SUMMARY = "An sh-compatible command language interpreter" |
2 | HOMEPAGE = "http://tiswww.case.edu/php/chet/bash/bashtop.html" | 2 | HOMEPAGE = "http://tiswww.case.edu/php/chet/bash/bashtop.html" |
3 | DESCRIPTION = "Bash is the GNU Project's Bourne Again SHell, a complete implementation of the IEEE POSIX and Open Group shell specification with interactive command line editing, job control on architectures that support it, csh-like features such as history substitution and brace expansion, and a slew of other features." | ||
3 | SECTION = "base/shell" | 4 | SECTION = "base/shell" |
4 | 5 | ||
5 | DEPENDS = "ncurses bison-native virtual/libiconv" | 6 | DEPENDS = "ncurses bison-native virtual/libiconv" |
6 | 7 | ||
7 | inherit autotools gettext texinfo update-alternatives ptest | 8 | inherit autotools gettext texinfo update-alternatives ptest |
8 | 9 | ||
9 | EXTRA_AUTORECONF += "--exclude=autoheader" | 10 | EXTRA_AUTORECONF += "--exclude=autoheader,aclocal" |
10 | EXTRA_OECONF = "--enable-job-control --without-bash-malloc bash_cv_wexitstatus_offset=8" | 11 | EXTRA_OECONF = "--enable-job-control --without-bash-malloc bash_cv_wexitstatus_offset=8" |
11 | 12 | ||
12 | # If NON_INTERACTIVE_LOGIN_SHELLS is defined, all login shells read the | 13 | # If NON_INTERACTIVE_LOGIN_SHELLS is defined, all login shells read the |
@@ -21,18 +22,18 @@ CFLAGS += "-DHEREDOC_PIPESIZE=65536" | |||
21 | # causes a lot of garbage in non-interactive shells | 22 | # causes a lot of garbage in non-interactive shells |
22 | CFLAGS += "-DBRACKETED_PASTE_DEFAULT=0" | 23 | CFLAGS += "-DBRACKETED_PASTE_DEFAULT=0" |
23 | 24 | ||
24 | ALTERNATIVE_${PN} = "bash sh" | 25 | ALTERNATIVE:${PN} = "bash sh" |
25 | ALTERNATIVE_LINK_NAME[bash] = "${base_bindir}/bash" | 26 | ALTERNATIVE_LINK_NAME[bash] = "${base_bindir}/bash" |
26 | ALTERNATIVE_TARGET[bash] = "${base_bindir}/bash" | 27 | ALTERNATIVE_TARGET[bash] = "${base_bindir}/bash" |
27 | ALTERNATIVE_LINK_NAME[sh] = "${base_bindir}/sh" | 28 | ALTERNATIVE_LINK_NAME[sh] = "${base_bindir}/sh" |
28 | ALTERNATIVE_TARGET[sh] = "${base_bindir}/bash.${BPN}" | 29 | ALTERNATIVE_TARGET[sh] = "${base_bindir}/bash.${BPN}" |
29 | ALTERNATIVE_PRIORITY = "100" | 30 | ALTERNATIVE_PRIORITY = "100" |
30 | 31 | ||
31 | RDEPENDS_${PN} += "base-files" | 32 | RDEPENDS:${PN} += "base-files" |
32 | RDEPENDS_${PN}_class-nativesdk = "" | 33 | RDEPENDS:${PN}:class-nativesdk = "" |
33 | RDEPENDS_${PN}-ptest += "make coreutils perl sed shadow util-linux-setpriv" | 34 | RDEPENDS:${PN}-ptest += "make coreutils perl sed shadow util-linux-setpriv" |
34 | 35 | ||
35 | RDEPENDS_${PN}-ptest_append_libc-glibc = " \ | 36 | RDEPENDS:${PN}-ptest:append:libc-glibc = " \ |
36 | glibc-gconv-big5hkscs \ | 37 | glibc-gconv-big5hkscs \ |
37 | glibc-gconv-iso8859-1 \ | 38 | glibc-gconv-iso8859-1 \ |
38 | glibc-utils \ | 39 | glibc-utils \ |
@@ -45,13 +46,7 @@ RDEPENDS_${PN}-ptest_append_libc-glibc = " \ | |||
45 | 46 | ||
46 | CACHED_CONFIGUREVARS += "headersdir=${includedir}/${PN}" | 47 | CACHED_CONFIGUREVARS += "headersdir=${includedir}/${PN}" |
47 | 48 | ||
48 | do_configure_prepend () { | 49 | do_compile:prepend() { |
49 | if [ ! -e ${S}/acinclude.m4 ]; then | ||
50 | cat ${S}/aclocal.m4 > ${S}/acinclude.m4 | ||
51 | fi | ||
52 | } | ||
53 | |||
54 | do_compile_prepend() { | ||
55 | # Remove any leftover .build files. This ensures that bash always has the | 50 | # Remove any leftover .build files. This ensures that bash always has the |
56 | # same version number and keeps builds reproducible | 51 | # same version number and keeps builds reproducible |
57 | rm -f ${B}/.build | 52 | rm -f ${B}/.build |
@@ -61,14 +56,20 @@ do_compile_ptest () { | |||
61 | oe_runmake buildtest | 56 | oe_runmake buildtest |
62 | } | 57 | } |
63 | 58 | ||
64 | do_install_append () { | 59 | do_install:prepend () { |
60 | # Ensure determinism as this counter increases for each make call | ||
61 | rm -f ${B}/.build | ||
62 | } | ||
63 | |||
64 | do_install:append () { | ||
65 | # Move /usr/bin/bash to /bin/bash, if need | 65 | # Move /usr/bin/bash to /bin/bash, if need |
66 | if [ "${base_bindir}" != "${bindir}" ]; then | 66 | if [ "${base_bindir}" != "${bindir}" ]; then |
67 | mkdir -p ${D}${base_bindir} | 67 | mkdir -p ${D}${base_bindir} |
68 | mv ${D}${bindir}/bash ${D}${base_bindir} | 68 | mv ${D}${bindir}/bash ${D}${base_bindir} |
69 | fi | 69 | fi |
70 | } | 70 | } |
71 | do_install_append_class-target () { | 71 | |
72 | fix_absolute_paths () { | ||
72 | # Clean buildhost references in bashbug | 73 | # Clean buildhost references in bashbug |
73 | sed -i -e "s,--sysroot=${STAGING_DIR_TARGET},,g" \ | 74 | sed -i -e "s,--sysroot=${STAGING_DIR_TARGET},,g" \ |
74 | -e "s,-I${WORKDIR}/\S* ,,g" \ | 75 | -e "s,-I${WORKDIR}/\S* ,,g" \ |
@@ -87,12 +88,24 @@ do_install_append_class-target () { | |||
87 | ${D}${libdir}/bash/Makefile.inc | 88 | ${D}${libdir}/bash/Makefile.inc |
88 | } | 89 | } |
89 | 90 | ||
91 | do_install:append:class-target () { | ||
92 | fix_absolute_paths | ||
93 | } | ||
94 | |||
95 | do_install:append:class-nativesdk () { | ||
96 | fix_absolute_paths | ||
97 | } | ||
98 | |||
90 | do_install_ptest () { | 99 | do_install_ptest () { |
91 | make INSTALL_TEST_DIR=${D}${PTEST_PATH}/tests install-test | 100 | make INSTALL_TEST_DIR=${D}${PTEST_PATH}/tests install-test |
92 | cp ${B}/Makefile ${D}${PTEST_PATH} | 101 | cp ${B}/Makefile ${D}${PTEST_PATH} |
93 | install -D ${WORKDIR}/run-bash-ptests ${D}${PTEST_PATH}/run-bash-ptests | 102 | cp ${B}/config.h ${D}${PTEST_PATH} |
103 | cp ${B}/version.h ${D}${PTEST_PATH} | ||
104 | cp ${S}/y.tab.[ch] ${D}${PTEST_PATH} | ||
105 | install -D ${UNPACKDIR}/run-bash-ptests ${D}${PTEST_PATH}/run-bash-ptests | ||
94 | sed -i -e 's/^Makefile/_Makefile/' -e "s,--sysroot=${STAGING_DIR_TARGET},,g" \ | 106 | sed -i -e 's/^Makefile/_Makefile/' -e "s,--sysroot=${STAGING_DIR_TARGET},,g" \ |
95 | -e 's|${DEBUG_PREFIX_MAP}||g' \ | 107 | -e 's|${DEBUG_PREFIX_MAP}||g' \ |
108 | -e 's|${BUILD_LDFLAGS}||g' \ | ||
96 | -e "s,${S},,g" -e "s,${B},,g" -e "s,${STAGING_DIR_NATIVE},,g" \ | 109 | -e "s,${S},,g" -e "s,${B},,g" -e "s,${STAGING_DIR_NATIVE},,g" \ |
97 | -e 's:${HOSTTOOLS_DIR}/::g' \ | 110 | -e 's:${HOSTTOOLS_DIR}/::g' \ |
98 | -e 's:${UNINATIVE_LOADER}:${base_bindir}/false:g' \ | 111 | -e 's:${UNINATIVE_LOADER}:${base_bindir}/false:g' \ |
@@ -103,20 +116,22 @@ do_install_ptest () { | |||
103 | # hash | 116 | # hash |
104 | do_install_ptest[vardepsexclude] += "UNINATIVE_LOADER" | 117 | do_install_ptest[vardepsexclude] += "UNINATIVE_LOADER" |
105 | 118 | ||
106 | pkg_postinst_${PN} () { | 119 | pkg_postinst:${PN} () { |
107 | grep -q "^${base_bindir}/bash$" $D${sysconfdir}/shells || echo ${base_bindir}/bash >> $D${sysconfdir}/shells | 120 | grep -q "^${base_bindir}/bash$" $D${sysconfdir}/shells || echo ${base_bindir}/bash >> $D${sysconfdir}/shells |
108 | } | 121 | } |
109 | 122 | ||
110 | pkg_postrm_${PN} () { | 123 | pkg_postrm:${PN} () { |
111 | printf "$(grep -v "^${base_bindir}/bash$" $D${sysconfdir}/shells)\n" > $D${sysconfdir}/shells | 124 | printf "$(grep -v "^${base_bindir}/bash$" $D${sysconfdir}/shells)\n" > $D${sysconfdir}/shells |
112 | } | 125 | } |
113 | 126 | ||
114 | PACKAGES += "${PN}-bashbug" | 127 | PACKAGES += "${PN}-bashbug" |
115 | FILES_${PN} = "${bindir}/bash ${base_bindir}/bash.bash" | 128 | FILES:${PN} = "${bindir}/bash ${base_bindir}/bash.bash" |
116 | FILES_${PN}-bashbug = "${bindir}/bashbug" | 129 | FILES:${PN}-bashbug = "${bindir}/bashbug" |
117 | 130 | ||
118 | PACKAGE_BEFORE_PN += "${PN}-loadable" | 131 | PACKAGE_BEFORE_PN += "${PN}-loadable" |
119 | RDEPENDS_${PN}-loadable += "${PN}" | 132 | RDEPENDS:${PN}-loadable += "${PN}" |
120 | FILES_${PN}-loadable += "${libdir}/bash/*" | 133 | FILES:${PN}-loadable += "${libdir}/bash/*" |
121 | 134 | ||
122 | RPROVIDES_${PN} += "${@bb.utils.contains('DISTRO_FEATURES', 'usrmerge', '/bin/sh /bin/bash', '', d)}" | 135 | # Limit the RPROVIDES here to class target so that if usrmerge is enabled for nativesdk, it does not |
136 | # include host system paths in /bin/ | ||
137 | RPROVIDES:${PN}:append:class-target = " ${@bb.utils.contains('DISTRO_FEATURES', 'usrmerge', '/bin/sh /bin/bash', '', d)}" | ||
diff --git a/meta/recipes-extended/bash/bash/0001-changes-to-SIGINT-handler-while-waiting-for-a-child-.patch b/meta/recipes-extended/bash/bash/0001-changes-to-SIGINT-handler-while-waiting-for-a-child-.patch new file mode 100644 index 0000000000..4e73edb9b3 --- /dev/null +++ b/meta/recipes-extended/bash/bash/0001-changes-to-SIGINT-handler-while-waiting-for-a-child-.patch | |||
@@ -0,0 +1,223 @@ | |||
1 | From e4b9493ae4923595ec3ca67f85322129fb3056cf Mon Sep 17 00:00:00 2001 | ||
2 | From: Chet Ramey <chet.ramey@case.edu> | ||
3 | Date: Mon, 30 Oct 2023 12:16:07 -0400 | ||
4 | Subject: [PATCH] changes to SIGINT handler while waiting for a child; skip | ||
5 | vertical whitespace after translating an integer | ||
6 | |||
7 | Upstream-Status: Backport from | ||
8 | [https://git.savannah.gnu.org/cgit/bash.git/commit/?h=devel&id=fe24a6a55e8850298b496c5b9d82f1866eba190e] | ||
9 | |||
10 | [Adjust and drop some codes to be applicable the tree] | ||
11 | |||
12 | Signed-off-by: Xiangyu Chen <xiangyu.chen@windriver.com> | ||
13 | --- | ||
14 | general.c | 5 +++-- | ||
15 | jobs.c | 24 ++++++++++++++++-------- | ||
16 | tests/redir.right | 4 ++-- | ||
17 | tests/redir11.sub | 2 ++ | ||
18 | tests/type.right | 16 ++++++++-------- | ||
19 | tests/type.tests | 24 ++++++++++++------------ | ||
20 | 6 files changed, 43 insertions(+), 32 deletions(-) | ||
21 | |||
22 | diff --git a/general.c b/general.c | ||
23 | index bda39f4..94a5339 100644 | ||
24 | --- a/general.c | ||
25 | +++ b/general.c | ||
26 | @@ -264,8 +264,9 @@ legal_number (string, result) | ||
27 | if (errno || ep == string) | ||
28 | return 0; /* errno is set on overflow or underflow */ | ||
29 | |||
30 | - /* Skip any trailing whitespace, since strtoimax does not. */ | ||
31 | - while (whitespace (*ep)) | ||
32 | + /* Skip any trailing whitespace, since strtoimax does not, using the same | ||
33 | + test that strtoimax uses for leading whitespace. */ | ||
34 | + while (isspace ((unsigned char) *ep)) | ||
35 | ep++; | ||
36 | |||
37 | /* If *string is not '\0' but *ep is '\0' on return, the entire string | ||
38 | diff --git a/jobs.c b/jobs.c | ||
39 | index d3e4ab0..903cf9c 100644 | ||
40 | --- a/jobs.c | ||
41 | +++ b/jobs.c | ||
42 | @@ -2718,6 +2718,10 @@ wait_for_background_pids (ps) | ||
43 | #define INVALID_SIGNAL_HANDLER (SigHandler *)wait_for_background_pids | ||
44 | static SigHandler *old_sigint_handler = INVALID_SIGNAL_HANDLER; | ||
45 | |||
46 | +/* The current SIGINT handler as set by restore_sigint_handler. Only valid | ||
47 | + immediately after restore_sigint_handler, used for continuations. */ | ||
48 | +static SigHandler *cur_sigint_handler = INVALID_SIGNAL_HANDLER; | ||
49 | + | ||
50 | static int wait_sigint_received; | ||
51 | static int child_caught_sigint; | ||
52 | |||
53 | @@ -2735,6 +2739,7 @@ wait_sigint_cleanup () | ||
54 | static void | ||
55 | restore_sigint_handler () | ||
56 | { | ||
57 | + cur_sigint_handler = old_sigint_handler; | ||
58 | if (old_sigint_handler != INVALID_SIGNAL_HANDLER) | ||
59 | { | ||
60 | set_signal_handler (SIGINT, old_sigint_handler); | ||
61 | @@ -2758,8 +2763,7 @@ wait_sigint_handler (sig) | ||
62 | restore_sigint_handler (); | ||
63 | /* If we got a SIGINT while in `wait', and SIGINT is trapped, do | ||
64 | what POSIX.2 says (see builtins/wait.def for more info). */ | ||
65 | - if (this_shell_builtin && this_shell_builtin == wait_builtin && | ||
66 | - signal_is_trapped (SIGINT) && | ||
67 | + if (signal_is_trapped (SIGINT) && | ||
68 | ((sigint_handler = trap_to_sighandler (SIGINT)) == trap_handler)) | ||
69 | { | ||
70 | trap_handler (SIGINT); /* set pending_traps[SIGINT] */ | ||
71 | @@ -2782,6 +2786,8 @@ wait_sigint_handler (sig) | ||
72 | { | ||
73 | set_exit_status (128+SIGINT); | ||
74 | restore_sigint_handler (); | ||
75 | + if (cur_sigint_handler == INVALID_SIGNAL_HANDLER) | ||
76 | + set_sigint_handler (); /* XXX - only do this in one place */ | ||
77 | kill (getpid (), SIGINT); | ||
78 | } | ||
79 | |||
80 | @@ -2926,11 +2932,13 @@ wait_for (pid, flags) | ||
81 | { | ||
82 | SigHandler *temp_sigint_handler; | ||
83 | |||
84 | - temp_sigint_handler = set_signal_handler (SIGINT, wait_sigint_handler); | ||
85 | - if (temp_sigint_handler == wait_sigint_handler) | ||
86 | - internal_debug ("wait_for: recursively setting old_sigint_handler to wait_sigint_handler: running_trap = %d", running_trap); | ||
87 | - else | ||
88 | - old_sigint_handler = temp_sigint_handler; | ||
89 | + temp_sigint_handler = old_sigint_handler; | ||
90 | + old_sigint_handler = set_signal_handler (SIGINT, wait_sigint_handler); | ||
91 | + if (old_sigint_handler == wait_sigint_handler) | ||
92 | + { | ||
93 | + internal_debug ("wait_for: recursively setting old_sigint_handler to wait_sigint_handler: running_trap = %d", running_trap); | ||
94 | + old_sigint_handler = temp_sigint_handler; | ||
95 | + } | ||
96 | waiting_for_child = 0; | ||
97 | if (old_sigint_handler == SIG_IGN) | ||
98 | set_signal_handler (SIGINT, old_sigint_handler); | ||
99 | @@ -4141,7 +4149,7 @@ set_job_status_and_cleanup (job) | ||
100 | SIGINT (if we reset the sighandler to the default). | ||
101 | In this case, we have to fix things up. What a crock. */ | ||
102 | if (temp_handler == trap_handler && signal_is_trapped (SIGINT) == 0) | ||
103 | - temp_handler = trap_to_sighandler (SIGINT); | ||
104 | + temp_handler = trap_to_sighandler (SIGINT); | ||
105 | restore_sigint_handler (); | ||
106 | if (temp_handler == SIG_DFL) | ||
107 | termsig_handler (SIGINT); /* XXX */ | ||
108 | diff --git a/tests/redir.right b/tests/redir.right | ||
109 | index 8db1041..9e1403c 100644 | ||
110 | --- a/tests/redir.right | ||
111 | +++ b/tests/redir.right | ||
112 | @@ -154,10 +154,10 @@ foo | ||
113 | 1 | ||
114 | 7 | ||
115 | after: 42 | ||
116 | -./redir11.sub: line 53: $(ss= declare -i ss): ambiguous redirect | ||
117 | +./redir11.sub: line 55: $(ss= declare -i ss): ambiguous redirect | ||
118 | after: 42 | ||
119 | a+=3 | ||
120 | foo | ||
121 | foo | ||
122 | -./redir11.sub: line 75: 42: No such file or directory | ||
123 | +./redir11.sub: line 77: 42: No such file or directory | ||
124 | 42 | ||
125 | diff --git a/tests/redir11.sub b/tests/redir11.sub | ||
126 | index d417cdb..ca9854c 100644 | ||
127 | --- a/tests/redir11.sub | ||
128 | +++ b/tests/redir11.sub | ||
129 | @@ -34,6 +34,8 @@ a=4 b=7 ss=4 declare -i ss | ||
130 | a=4 b=7 foo | ||
131 | echo after: $a | ||
132 | |||
133 | +exec 7>&- 4>&- | ||
134 | + | ||
135 | unset a | ||
136 | a=4 echo foo 2>&1 >&$(foo) | { grep -q 'Bad file' || echo 'redir11 bad 3'; } | ||
137 | a=1 echo foo 2>&1 >&$(foo) | { grep -q 'Bad file' || echo 'redir11 bad 4'; } | ||
138 | diff --git a/tests/type.right b/tests/type.right | ||
139 | index bbc228e..c0c1c8b 100644 | ||
140 | --- a/tests/type.right | ||
141 | +++ b/tests/type.right | ||
142 | @@ -24,15 +24,15 @@ func () | ||
143 | } | ||
144 | while | ||
145 | while is a shell keyword | ||
146 | -./type.tests: line 56: type: m: not found | ||
147 | -alias m='more' | ||
148 | -alias m='more' | ||
149 | -m is aliased to `more' | ||
150 | +./type.tests: line 56: type: morealias: not found | ||
151 | +alias morealias='more' | ||
152 | +alias morealias='more' | ||
153 | +morealias is aliased to `more' | ||
154 | alias | ||
155 | -alias m='more' | ||
156 | -alias m='more' | ||
157 | -alias m='more' | ||
158 | -m is aliased to `more' | ||
159 | +alias morealias='more' | ||
160 | +alias morealias='more' | ||
161 | +alias morealias='more' | ||
162 | +morealias is aliased to `more' | ||
163 | builtin | ||
164 | builtin is a shell builtin | ||
165 | /bin/sh | ||
166 | diff --git a/tests/type.tests b/tests/type.tests | ||
167 | index fd39c18..ddc1540 100644 | ||
168 | --- a/tests/type.tests | ||
169 | +++ b/tests/type.tests | ||
170 | @@ -25,8 +25,6 @@ type -r ${THIS_SH} | ||
171 | type notthere | ||
172 | command -v notthere | ||
173 | |||
174 | -alias m=more | ||
175 | - | ||
176 | unset -f func 2>/dev/null | ||
177 | func() { echo this is func; } | ||
178 | |||
179 | @@ -49,24 +47,26 @@ command -V func | ||
180 | command -v while | ||
181 | command -V while | ||
182 | |||
183 | +alias morealias=more | ||
184 | + | ||
185 | # the following two lines should produce the same output | ||
186 | # post-3.0 patch makes command -v silent, as posix specifies | ||
187 | # first test with alias expansion off (should all fail or produce no output) | ||
188 | -type -t m | ||
189 | -type m | ||
190 | -command -v m | ||
191 | +type -t morealias | ||
192 | +type morealias | ||
193 | +command -v morealias | ||
194 | alias -p | ||
195 | -alias m | ||
196 | +alias morealias | ||
197 | |||
198 | # then test with alias expansion on | ||
199 | shopt -s expand_aliases | ||
200 | -type m | ||
201 | -type -t m | ||
202 | -command -v m | ||
203 | +type morealias | ||
204 | +type -t morealias | ||
205 | +command -v morealias | ||
206 | alias -p | ||
207 | -alias m | ||
208 | +alias morealias | ||
209 | |||
210 | -command -V m | ||
211 | +command -V morealias | ||
212 | shopt -u expand_aliases | ||
213 | |||
214 | command -v builtin | ||
215 | @@ -76,7 +76,7 @@ command -V /bin/sh | ||
216 | |||
217 | unset -f func | ||
218 | type func | ||
219 | -unalias m | ||
220 | +unalias morealias | ||
221 | type m | ||
222 | |||
223 | hash -r | ||
diff --git a/meta/recipes-extended/bash/bash/build-tests.patch b/meta/recipes-extended/bash/bash/build-tests.patch index ea38bace9b..4cce1ba993 100644 --- a/meta/recipes-extended/bash/bash/build-tests.patch +++ b/meta/recipes-extended/bash/bash/build-tests.patch | |||
@@ -1,24 +1,23 @@ | |||
1 | From 318b762837c2ad25319caeaf0320eff613b64daf Mon Sep 17 00:00:00 2001 | 1 | From c3f58f8b4f7a359b9d9dd97a45bcaab50a89d224 Mon Sep 17 00:00:00 2001 |
2 | From: Anders Roxell <anders.roxell@enea.com> | 2 | From: Anders Roxell <anders.roxell@enea.com> |
3 | Date: Wed, 19 Dec 2012 17:18:31 +0100 | 3 | Date: Wed, 19 Dec 2012 17:18:31 +0100 |
4 | Subject: [PATCH] Add 'ptest' target to Makefile, to run tests without checking | 4 | Subject: [PATCH] Add 'ptest' target to Makefile, to run tests without checking |
5 | dependencies. | 5 | dependencies. |
6 | 6 | ||
7 | Upstream-Status: Pending | 7 | Upstream-Status: Inappropriate [ptest specific] |
8 | Signed-off-by: Anders Roxell <anders.roxell@enea.com> | 8 | Signed-off-by: Anders Roxell <anders.roxell@enea.com> |
9 | 9 | ||
10 | Rebase to 5.0 | 10 | Rebase to 5.0 |
11 | Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com> | 11 | Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com> |
12 | |||
13 | --- | 12 | --- |
14 | Makefile.in | 24 +++++++++++++++++++----- | 13 | Makefile.in | 24 +++++++++++++++++++----- |
15 | 1 file changed, 19 insertions(+), 5 deletions(-) | 14 | 1 file changed, 19 insertions(+), 5 deletions(-) |
16 | 15 | ||
17 | diff --git a/Makefile.in b/Makefile.in | 16 | diff --git a/Makefile.in b/Makefile.in |
18 | index bc97049..937ce39 100644 | 17 | index 0b4df73..7e2a34e 100644 |
19 | --- a/Makefile.in | 18 | --- a/Makefile.in |
20 | +++ b/Makefile.in | 19 | +++ b/Makefile.in |
21 | @@ -943,20 +943,34 @@ maybe-clean: | 20 | @@ -958,20 +958,34 @@ maybe-clean: |
22 | fi | 21 | fi |
23 | 22 | ||
24 | recho$(EXEEXT): $(SUPPORT_SRC)recho.c | 23 | recho$(EXEEXT): $(SUPPORT_SRC)recho.c |
diff --git a/meta/recipes-extended/bash/bash/execute_cmd.patch b/meta/recipes-extended/bash/bash/execute_cmd.patch deleted file mode 100644 index 7a9e9a902f..0000000000 --- a/meta/recipes-extended/bash/bash/execute_cmd.patch +++ /dev/null | |||
@@ -1,28 +0,0 @@ | |||
1 | Upstream-Status: Inappropriate [embedded specific] | ||
2 | |||
3 | Rebase to 5.0 | ||
4 | Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com> | ||
5 | --- | ||
6 | execute_cmd.c | 6 +++++- | ||
7 | 1 file changed, 5 insertions(+), 1 deletion(-) | ||
8 | |||
9 | diff --git a/execute_cmd.c b/execute_cmd.c | ||
10 | index f1d74bf..31674b4 100644 | ||
11 | --- a/execute_cmd.c | ||
12 | +++ b/execute_cmd.c | ||
13 | @@ -2567,7 +2567,11 @@ execute_pipeline (command, asynchronous, pipe_in, pipe_out, fds_to_close) | ||
14 | /* If the `lastpipe' option is set with shopt, and job control is not | ||
15 | enabled, execute the last element of non-async pipelines in the | ||
16 | current shell environment. */ | ||
17 | - if (lastpipe_opt && job_control == 0 && asynchronous == 0 && pipe_out == NO_PIPE && prev > 0) | ||
18 | + if (lastpipe_opt && | ||
19 | +#if defined(JOB_CONTROL) | ||
20 | + job_control == 0 && | ||
21 | +#endif | ||
22 | + asynchronous == 0 && pipe_out == NO_PIPE && prev > 0) | ||
23 | { | ||
24 | lstdin = move_to_high_fd (0, 1, -1); | ||
25 | if (lstdin > 0) | ||
26 | -- | ||
27 | 2.7.4 | ||
28 | |||
diff --git a/meta/recipes-extended/bash/bash/fix-filesubst-errexit.patch b/meta/recipes-extended/bash/bash/fix-filesubst-errexit.patch new file mode 100644 index 0000000000..c5082ee355 --- /dev/null +++ b/meta/recipes-extended/bash/bash/fix-filesubst-errexit.patch | |||
@@ -0,0 +1,31 @@ | |||
1 | From 16951b74971c7fd38fd036dac1410a9e53cbe736 Mon Sep 17 00:00:00 2001 | ||
2 | From: Chet Ramey <chet.ramey@case.edu> | ||
3 | Date: Fri, 7 Apr 2023 00:28:46 -0700 | ||
4 | Subject: [PATCH] $(<nosuchfile) is no longer a fatal error with errexit | ||
5 | enabled | ||
6 | |||
7 | This is a trimmed-down version of a commit in the bash 'devel' branch | ||
8 | [1] that contains this fix as well as other unrelated ones. | ||
9 | |||
10 | [1] https://git.savannah.gnu.org/cgit/bash.git/commit/?h=devel&id=ec9447ce9392a0f93d96789c3741285fede8a150 | ||
11 | |||
12 | Upstream-Status: Backport | ||
13 | |||
14 | Signed-off-by: Zev Weiss <zev@bewilderbeest.net> | ||
15 | --- | ||
16 | builtins/evalstring.c | 2 +- | ||
17 | 1 file changed, 1 insertion(+), 1 deletion(-) | ||
18 | |||
19 | diff --git a/builtins/evalstring.c b/builtins/evalstring.c | ||
20 | index 53a7c0b..c5075cc 100644 | ||
21 | --- a/builtins/evalstring.c | ||
22 | +++ b/builtins/evalstring.c | ||
23 | @@ -753,7 +753,7 @@ open_redir_file (r, fnp) | ||
24 | fd = open(fn, O_RDONLY); | ||
25 | if (fd < 0) | ||
26 | { | ||
27 | - file_error (fn); | ||
28 | + internal_error ("%s: %s", fn, strerror (errno)); | ||
29 | free (fn); | ||
30 | if (fnp) | ||
31 | *fnp = 0; | ||
diff --git a/meta/recipes-extended/bash/bash/fix-run-builtins.patch b/meta/recipes-extended/bash/bash/fix-run-builtins.patch index 2fa388302e..05d0859821 100644 --- a/meta/recipes-extended/bash/bash/fix-run-builtins.patch +++ b/meta/recipes-extended/bash/bash/fix-run-builtins.patch | |||
@@ -1,4 +1,4 @@ | |||
1 | From 0c4cab9594c96c2dc435a8d9724605824bcbf917 Mon Sep 17 00:00:00 2001 | 1 | From 15601c71b073a604ccda25c7f14f0bb12e9a3b28 Mon Sep 17 00:00:00 2001 |
2 | From: Dengke Du <dengke.du@windriver.com> | 2 | From: Dengke Du <dengke.du@windriver.com> |
3 | Date: Tue, 19 Apr 2016 02:57:45 -0400 | 3 | Date: Tue, 19 Apr 2016 02:57:45 -0400 |
4 | Subject: [PATCH] fix run-builtins failed | 4 | Subject: [PATCH] fix run-builtins failed |
@@ -16,10 +16,10 @@ Signed-off-by: Dengke Du <dengke.du@windriver.com> | |||
16 | 1 file changed, 1 insertion(+), 1 deletion(-) | 16 | 1 file changed, 1 insertion(+), 1 deletion(-) |
17 | 17 | ||
18 | diff --git a/tests/builtins.tests b/tests/builtins.tests | 18 | diff --git a/tests/builtins.tests b/tests/builtins.tests |
19 | index 9d77520..63f3af8 100644 | 19 | index 8eee43e..71c9eee 100644 |
20 | --- a/tests/builtins.tests | 20 | --- a/tests/builtins.tests |
21 | +++ b/tests/builtins.tests | 21 | +++ b/tests/builtins.tests |
22 | @@ -109,7 +109,7 @@ esac | 22 | @@ -124,7 +124,7 @@ esac |
23 | 23 | ||
24 | # test options to exec | 24 | # test options to exec |
25 | (exec -a specialname ${THIS_SH} -c 'echo $0' ) | 25 | (exec -a specialname ${THIS_SH} -c 'echo $0' ) |
@@ -28,6 +28,3 @@ index 9d77520..63f3af8 100644 | |||
28 | # test `clean' environment. if /bin/sh is bash, and the script version of | 28 | # test `clean' environment. if /bin/sh is bash, and the script version of |
29 | # printenv is run, there will be variables in the environment that bash | 29 | # printenv is run, there will be variables in the environment that bash |
30 | # sets on startup. Also test code that prefixes argv[0] with a dash. | 30 | # sets on startup. Also test code that prefixes argv[0] with a dash. |
31 | -- | ||
32 | 2.8.1 | ||
33 | |||
diff --git a/meta/recipes-extended/bash/bash/makerace.patch b/meta/recipes-extended/bash/bash/makerace.patch deleted file mode 100644 index 9bd7c280fe..0000000000 --- a/meta/recipes-extended/bash/bash/makerace.patch +++ /dev/null | |||
@@ -1,52 +0,0 @@ | |||
1 | We're seeing pipesize.h being created in parallel: | ||
2 | |||
3 | /bin/sh ../../bash-5.1/builtins/psize.sh > pipesize.h | ||
4 | /bin/sh ../../bash-5.1/builtins/psize.sh > pipesize.h | ||
5 | |||
6 | ./mkbuiltins -D ../../bash-5.1/builtins ../../bash-5.1/builtins/ulimit.def | ||
7 | x86_64-pokysdk-linux-gcc --sysroot=/home/pokybuild/yocto-worker/multilib/build/build/tmp/work/x86_64-nativesdk-pokysdk-linux/nativesdk-bash/5.1-r0/recipe-sysroot -c -DHAVE_CONFIG_H -DSHELL -I. -I.. -I../../bash-5.1 -I../../bash-5.1/include -I../../bash-5.1/lib -I../../bash-5.1/builtins -O2 -pipe -fmacro-prefix-map=/home/pokybuild/yocto-worker/multilib/build/build/tmp/work/x86_64-nativesdk-pokysdk-linux/nativesdk-bash/5.1-r0=/usr/src/debug/nativesdk-bash/5.1-r0 -fdebug-prefix-map=/home/pokybuild/yocto-worker/multilib/build/build/tmp/work/x86_64-nativesdk-pokysdk-linux/nativesdk-bash/5.1-r0=/usr/src/debug/nativesdk-bash/5.1-r0 -fdebug-prefix-map=/home/pokybuild/yocto-worker/multilib/build/build/tmp/work/x86_64-nativesdk-pokysdk-linux/nativesdk-bash/5.1-r0/recipe-sysroot= -fdebug-prefix-map=/home/pokybuild/yocto-worker/multilib/build/build/tmp/work/x86_64-nativesdk-pokysdk-linux/nativesdk-bash/5.1-r0/recipe-sysroot-native= ulimit.c || ( rm -f ulimit.c ; exit 1 ) | ||
8 | make[1]: Leaving directory '/home/pokybuild/yocto-worker/multilib/build/build/tmp/work/x86_64-nativesdk-pokysdk-linux/nativesdk-bash/5.1-r0/build/builtins' | ||
9 | rm -f redir.o | ||
10 | x86_64-pokysdk-linux-gcc --sysroot=/home/pokybuild/yocto-worker/multilib/build/build/tmp/work/x86_64-nativesdk-pokysdk-linux/nativesdk-bash/5.1-r0/recipe-sysroot -DPROGRAM='"bash"' -DCONF_HOSTTYPE='"x86_64"' -DCONF_OSTYPE='"linux-gnu"' -DCONF_MACHTYPE='"x86_64-pokysdk-linux-gnu"' -DCONF_VENDOR='"pokysdk"' -DLOCALEDIR='"/opt/poky/3.2+snapshot/sysroots/x86_64-pokysdk-linux/usr/share/locale"' -DPACKAGE='"bash"' -DSHELL -DHAVE_CONFIG_H -I. -I../bash-5.1 -I../bash-5.1/include -I../bash-5.1/lib -O2 -pipe -fmacro-prefix-map=/home/pokybuild/yocto-worker/multilib/build/build/tmp/work/x86_64-nativesdk-pokysdk-linux/nativesdk-bash/5.1-r0=/usr/src/debug/nativesdk-bash/5.1-r0 -fdebug-prefix-map=/home/pokybuild/yocto-worker/multilib/build/build/tmp/work/x86_64-nativesdk-pokysdk-linux/nativesdk-bash/5.1-r0=/usr/src/debug/nativesdk-bash/5.1-r0 -fdebug-prefix-map=/home/pokybuild/yocto-worker/multilib/build/build/tmp/work/x86_64-nativesdk-pokysdk-linux/nativesdk-bash/5.1-r0/recipe-sysroot= -fdebug-prefix-map=/home/pokybuild/yocto-worker/multilib/build/build/tmp/work/x86_64-nativesdk-pokysdk-linux/nativesdk-bash/5.1-r0/recipe-sysroot-native= -c ../bash-5.1/redir.c | ||
11 | In file included from ../../bash-5.1/builtins/../../bash-5.1/builtins/ulimit.def:95: | ||
12 | pipesize.h:9:5: error: expected '=', ',', ';', 'asm' or '__attribute__' before '-' token | ||
13 | 9 | bash-5.1/builtins/psize.sh: 37: ../../bash-5.1/builtins/psize.sh: ./psize.aux: Text file busy | ||
14 | | ^ | ||
15 | make[1]: *** [Makefile:119: ulimit.o] Error 1 | ||
16 | make[1]: Leaving directory '/home/pokybuild/yocto-worker/multilib/build/build/tmp/work/x86_64-nativesdk-pokysdk-linux/nativesdk-bash/5.1-r0/build/builtins' | ||
17 | make: *** [Makefile:737: builtins/libbuiltins.a] Error 1 | ||
18 | make: *** Waiting for unfinished jobs.... | ||
19 | In file included from ../bash-5.1/redir.c:61: | ||
20 | ./builtins/pipesize.h:9:5: error: expected '=', ',', ';', 'asm' or '__attribute__' before '-' token | ||
21 | 9 | bash-5.1/builtins/psize.sh: 37: ../../bash-5.1/builtins/psize.sh: ./psize.aux: Text file busy | ||
22 | | ^ | ||
23 | make: *** [Makefile:101: redir.o] Error 1 | ||
24 | WARNING: exit code 1 from a shell command. | ||
25 | |||
26 | which happens since builtins/ulimit.o depends on pipesize.h as well as a top | ||
27 | level dependency. This means: | ||
28 | |||
29 | @(cd $(DEFDIR) && $(MAKE) $(MFLAGS) pipesize.h ) || exit 1 | ||
30 | |||
31 | races with: | ||
32 | |||
33 | @(cd $(DEFDIR) && $(MAKE) $(MFLAGS) DEBUG=${DEBUG} targets ) || exit 1 | ||
34 | |||
35 | Hack around this by forcing BUILTINS_LIBRARY onto pipesize.h as a dependency. | ||
36 | |||
37 | Upstream-Status: Submitted [https://lists.gnu.org/archive/html/bug-bash/2021-01/msg00152.html] | ||
38 | Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> | ||
39 | |||
40 | Index: bash-5.1/Makefile.in | ||
41 | =================================================================== | ||
42 | --- bash-5.1.orig/Makefile.in | ||
43 | +++ bash-5.1/Makefile.in | ||
44 | @@ -746,7 +746,7 @@ ${DEFDIR}/bashgetopt.o: $(BUILTIN_SRCDIR | ||
45 | ${DEFDIR}/builtext.h: $(BUILTIN_DEFS) | ||
46 | @(cd $(DEFDIR) && $(MAKE) $(MFLAGS) builtext.h ) || exit 1 | ||
47 | |||
48 | -${DEFDIR}/pipesize.h: | ||
49 | +${DEFDIR}/pipesize.h: $(BUILTINS_LIBRARY) | ||
50 | @(cd $(DEFDIR) && $(MAKE) $(MFLAGS) pipesize.h ) || exit 1 | ||
51 | |||
52 | $(SDIR)/man2html$(EXEEXT): ${SUPPORT_SRC}/man2html.c | ||
diff --git a/meta/recipes-extended/bash/bash/mkbuiltins_have_stringize.patch b/meta/recipes-extended/bash/bash/mkbuiltins_have_stringize.patch index a9391d6cac..eb29e7d836 100644 --- a/meta/recipes-extended/bash/bash/mkbuiltins_have_stringize.patch +++ b/meta/recipes-extended/bash/bash/mkbuiltins_have_stringize.patch | |||
@@ -1,3 +1,8 @@ | |||
1 | From d11685286144c2e5630545e435d11387b2908fd0 Mon Sep 17 00:00:00 2001 | ||
2 | From: Christopher Larson <chris_larson@mentor.com> | ||
3 | Date: Wed, 14 Nov 2012 07:55:09 -0700 | ||
4 | Subject: [PATCH] bash: fix mkbuiltins build failure | ||
5 | |||
1 | On hosts with FORTIFY_SOURCES, stringize support is required, as it's used by | 6 | On hosts with FORTIFY_SOURCES, stringize support is required, as it's used by |
2 | the macros to wrap functions (e.g. read and open in unistd.h). Those wrappers | 7 | the macros to wrap functions (e.g. read and open in unistd.h). Those wrappers |
3 | use the STRING() macro from unistd.h. A header in the bash sources overrides | 8 | use the STRING() macro from unistd.h. A header in the bash sources overrides |
@@ -13,14 +18,19 @@ stringize support, or to not define STRING() at all when FORTIFY_SOURCES is | |||
13 | defined, letting the unistd.h one be used, instead. | 18 | defined, letting the unistd.h one be used, instead. |
14 | 19 | ||
15 | Upstream-Status: Pending | 20 | Upstream-Status: Pending |
21 | --- | ||
22 | builtins/mkbuiltins.c | 1 + | ||
23 | 1 file changed, 1 insertion(+) | ||
16 | 24 | ||
17 | --- bash-4.2.orig/builtins/mkbuiltins.c | 25 | diff --git a/builtins/mkbuiltins.c b/builtins/mkbuiltins.c |
18 | +++ bash-4.2/builtins/mkbuiltins.c | 26 | index f505ebd..b5b2eed 100644 |
27 | --- a/builtins/mkbuiltins.c | ||
28 | +++ b/builtins/mkbuiltins.c | ||
19 | @@ -28,6 +28,7 @@ | 29 | @@ -28,6 +28,7 @@ |
20 | # define HAVE_STDLIB_H | 30 | # define HAVE_STDLIB_H |
21 | 31 | ||
22 | # define HAVE_RENAME | 32 | # define HAVE_RENAME |
23 | +# define HAVE_STRINGIZE | 33 | +# define HAVE_STRINGIZE |
24 | #endif /* CROSS_COMPILING */ | 34 | #endif /* CROSS_COMPILING */ |
25 | 35 | ||
26 | #if defined (HAVE_UNISTD_H) | 36 | #if defined (HAVE_UNISTD_H) |
diff --git a/meta/recipes-extended/bash/bash/test-output.patch b/meta/recipes-extended/bash/bash/test-output.patch index 0ffcc24587..3225907b66 100644 --- a/meta/recipes-extended/bash/bash/test-output.patch +++ b/meta/recipes-extended/bash/bash/test-output.patch | |||
@@ -1,7 +1,7 @@ | |||
1 | From 28eb06047ebd2deaa8c7cd2bf6655ef6a469dc14 Mon Sep 17 00:00:00 2001 | 1 | From f5cbd5a4954b89857c9e397cacceda552484f5d5 Mon Sep 17 00:00:00 2001 |
2 | From: Hongxu Jia <hongxu.jia@windriver.com> | 2 | From: Hongxu Jia <hongxu.jia@windriver.com> |
3 | Date: Tue, 15 Aug 2017 10:01:56 +0800 | 3 | Date: Tue, 15 Aug 2017 10:01:56 +0800 |
4 | Subject: [PATCH 1/2] Add FAIL/PASS output to test output. | 4 | Subject: [PATCH] Add FAIL/PASS output to test output. |
5 | MIME-Version: 1.0 | 5 | MIME-Version: 1.0 |
6 | Content-Type: text/plain; charset=UTF-8 | 6 | Content-Type: text/plain; charset=UTF-8 |
7 | Content-Transfer-Encoding: 8bit | 7 | Content-Transfer-Encoding: 8bit |
@@ -16,10 +16,10 @@ Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com> | |||
16 | 1 file changed, 10 insertions(+), 1 deletion(-) | 16 | 1 file changed, 10 insertions(+), 1 deletion(-) |
17 | 17 | ||
18 | diff --git a/tests/run-all b/tests/run-all | 18 | diff --git a/tests/run-all b/tests/run-all |
19 | index 2882fe0..e21d026 100644 | 19 | index 1f74923..ba36a1f 100644 |
20 | --- a/tests/run-all | 20 | --- a/tests/run-all |
21 | +++ b/tests/run-all | 21 | +++ b/tests/run-all |
22 | @@ -33,7 +33,16 @@ do | 22 | @@ -57,7 +57,16 @@ do |
23 | case $x in | 23 | case $x in |
24 | $0|run-minimal|run-gprof) ;; | 24 | $0|run-minimal|run-gprof) ;; |
25 | *.orig|*~) ;; | 25 | *.orig|*~) ;; |
@@ -37,6 +37,3 @@ index 2882fe0..e21d026 100644 | |||
37 | esac | 37 | esac |
38 | done | 38 | done |
39 | 39 | ||
40 | -- | ||
41 | 1.8.3.1 | ||
42 | |||
diff --git a/meta/recipes-extended/bash/bash/use_aclocal.patch b/meta/recipes-extended/bash/bash/use_aclocal.patch deleted file mode 100644 index bebaa08bfe..0000000000 --- a/meta/recipes-extended/bash/bash/use_aclocal.patch +++ /dev/null | |||
@@ -1,59 +0,0 @@ | |||
1 | Including m4 files directly like this confuses autotools.bbclass, remove | ||
2 | the references and rely upon aclocal to collect the m4 files together | ||
3 | as needed instead making it work like other autotools based projects. | ||
4 | |||
5 | Upstream-Status: Inappropriate [OE configuration specific] | ||
6 | RP 2021/1/20 | ||
7 | |||
8 | Index: bash-5.1/configure.ac | ||
9 | =================================================================== | ||
10 | --- bash-5.1.orig/configure.ac | ||
11 | +++ bash-5.1/configure.ac | ||
12 | @@ -688,47 +688,6 @@ if test x$SIZE = x; then | ||
13 | fi | ||
14 | AC_SUBST(SIZE) | ||
15 | |||
16 | -m4_include([m4/stat-time.m4]) | ||
17 | -m4_include([m4/timespec.m4]) | ||
18 | - | ||
19 | -dnl include files for gettext | ||
20 | - | ||
21 | -m4_include([m4/codeset.m4]) | ||
22 | -m4_include([m4/extern-inline.m4]) | ||
23 | -m4_include([m4/fcntl-o.m4]) | ||
24 | -m4_include([m4/gettext.m4]) | ||
25 | -m4_include([m4/glibc2.m4]) | ||
26 | -m4_include([m4/glibc21.m4]) | ||
27 | -m4_include([m4/host-cpu-c-abi.m4]) | ||
28 | -m4_include([m4/iconv.m4]) | ||
29 | -m4_include([m4/intdiv0.m4]) | ||
30 | -m4_include([m4/intl.m4]) | ||
31 | -m4_include([m4/intlmacosx.m4]) | ||
32 | -m4_include([m4/intl-thread-locale.m4]) | ||
33 | -m4_include([m4/intmax.m4]) | ||
34 | -m4_include([m4/inttypes-pri.m4]) | ||
35 | -m4_include([m4/inttypes.m4]) | ||
36 | -m4_include([m4/inttypes_h.m4]) | ||
37 | -m4_include([m4/lcmessage.m4]) | ||
38 | -m4_include([m4/lib-ld.m4]) | ||
39 | -m4_include([m4/lib-link.m4]) | ||
40 | -m4_include([m4/lib-prefix.m4]) | ||
41 | -m4_include([m4/lock.m4]) | ||
42 | -m4_include([m4/nls.m4]) | ||
43 | -m4_include([m4/po.m4]) | ||
44 | -m4_include([m4/printf-posix.m4]) | ||
45 | -m4_include([m4/progtest.m4]) | ||
46 | -m4_include([m4/pthread_rwlock_rdlock.m4]) | ||
47 | -m4_include([m4/size_max.m4]) | ||
48 | -m4_include([m4/stdint_h.m4]) | ||
49 | -m4_include([m4/threadlib.m4]) | ||
50 | -m4_include([m4/uintmax_t.m4]) | ||
51 | -m4_include([m4/ulonglong.m4]) | ||
52 | -m4_include([m4/visibility.m4]) | ||
53 | -m4_include([m4/wchar_t.m4]) | ||
54 | -m4_include([m4/wint_t.m4]) | ||
55 | -m4_include([m4/xsize.m4]) | ||
56 | - | ||
57 | dnl Turn on any extensions available in the GNU C library. | ||
58 | AC_DEFINE(_GNU_SOURCE, 1) | ||
59 | |||
diff --git a/meta/recipes-extended/bash/bash_5.1.bb b/meta/recipes-extended/bash/bash_5.1.bb deleted file mode 100644 index e5e013b734..0000000000 --- a/meta/recipes-extended/bash/bash_5.1.bb +++ /dev/null | |||
@@ -1,32 +0,0 @@ | |||
1 | require bash.inc | ||
2 | |||
3 | # GPLv2+ (< 4.0), GPLv3+ (>= 4.0) | ||
4 | LICENSE = "GPLv3+" | ||
5 | LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504" | ||
6 | |||
7 | SRC_URI = "${GNU_MIRROR}/bash/${BP}.tar.gz;name=tarball \ | ||
8 | ${GNU_MIRROR}/bash/bash-${PV}-patches/bash51-001;apply=yes;striplevel=0;name=patch001 \ | ||
9 | ${GNU_MIRROR}/bash/bash-${PV}-patches/bash51-002;apply=yes;striplevel=0;name=patch002 \ | ||
10 | ${GNU_MIRROR}/bash/bash-${PV}-patches/bash51-003;apply=yes;striplevel=0;name=patch003 \ | ||
11 | ${GNU_MIRROR}/bash/bash-${PV}-patches/bash51-004;apply=yes;striplevel=0;name=patch004 \ | ||
12 | file://execute_cmd.patch \ | ||
13 | file://mkbuiltins_have_stringize.patch \ | ||
14 | file://build-tests.patch \ | ||
15 | file://test-output.patch \ | ||
16 | file://run-ptest \ | ||
17 | file://run-bash-ptests \ | ||
18 | file://fix-run-builtins.patch \ | ||
19 | file://use_aclocal.patch \ | ||
20 | file://makerace.patch \ | ||
21 | " | ||
22 | |||
23 | SRC_URI[tarball.sha256sum] = "cc012bc860406dcf42f64431bcd3d2fa7560c02915a601aba9cd597a39329baa" | ||
24 | SRC_URI[patch001.sha256sum] = "ebb07b3dbadd98598f078125d0ae0d699295978a5cdaef6282fe19adef45b5fa" | ||
25 | SRC_URI[patch002.sha256sum] = "15ea6121a801e48e658ceee712ea9b88d4ded022046a6147550790caf04f5dbe" | ||
26 | SRC_URI[patch003.sha256sum] = "22f2cc262f056b22966281babf4b0a2f84cb7dd2223422e5dcd013c3dcbab6b1" | ||
27 | SRC_URI[patch004.sha256sum] = "9aaeb65664ef0d28c0067e47ba5652b518298b3b92d33327d84b98b28d873c86" | ||
28 | |||
29 | DEBUG_OPTIMIZATION_append_armv4 = " ${@bb.utils.contains('TUNE_CCARGS', '-mthumb', '-fomit-frame-pointer', '', d)}" | ||
30 | DEBUG_OPTIMIZATION_append_armv5 = " ${@bb.utils.contains('TUNE_CCARGS', '-mthumb', '-fomit-frame-pointer', '', d)}" | ||
31 | |||
32 | BBCLASSEXTEND = "nativesdk" | ||
diff --git a/meta/recipes-extended/bash/bash_5.2.37.bb b/meta/recipes-extended/bash/bash_5.2.37.bb new file mode 100644 index 0000000000..2c0645cbd9 --- /dev/null +++ b/meta/recipes-extended/bash/bash_5.2.37.bb | |||
@@ -0,0 +1,28 @@ | |||
1 | require bash.inc | ||
2 | |||
3 | # GPL-2.0-or-later (< 4.0), GPL-3.0-or-later (>= 4.0) | ||
4 | LICENSE = "GPL-3.0-or-later" | ||
5 | LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504" | ||
6 | |||
7 | SRC_URI = "${GNU_MIRROR}/bash/${BP}.tar.gz;name=tarball \ | ||
8 | file://mkbuiltins_have_stringize.patch \ | ||
9 | file://build-tests.patch \ | ||
10 | file://test-output.patch \ | ||
11 | file://run-ptest \ | ||
12 | file://run-bash-ptests \ | ||
13 | file://fix-run-builtins.patch \ | ||
14 | file://0001-changes-to-SIGINT-handler-while-waiting-for-a-child-.patch \ | ||
15 | file://fix-filesubst-errexit.patch \ | ||
16 | " | ||
17 | |||
18 | SRC_URI[tarball.sha256sum] = "9599b22ecd1d5787ad7d3b7bf0c59f312b3396d1e281175dd1f8a4014da621ff" | ||
19 | |||
20 | DEBUG_OPTIMIZATION:append:armv4 = " ${@bb.utils.contains('TUNE_CCARGS', '-mthumb', '-fomit-frame-pointer', '', d)}" | ||
21 | DEBUG_OPTIMIZATION:append:armv5 = " ${@bb.utils.contains('TUNE_CCARGS', '-mthumb', '-fomit-frame-pointer', '', d)}" | ||
22 | |||
23 | CFLAGS += "-std=gnu17" | ||
24 | # mkbuiltins.c is built with native toolchain and needs gnu17 as well: | ||
25 | # http://errors.yoctoproject.org/Errors/Details/853016/ | ||
26 | BUILD_CFLAGS += "-std=gnu17" | ||
27 | |||
28 | BBCLASSEXTEND = "nativesdk" | ||