Skip to content

Commit 7ef2497

Browse files
committed
Fix bug, without 'exec' we need explicit exit.
Use 'exec' in `configure`.
1 parent 9e4960e commit 7ef2497

3 files changed

Lines changed: 6 additions & 2 deletions

File tree

Tools/configure/configure.awk

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
# Generated by transpile.py -- do not edit.
33
# This is a POSIX shell wrapper around an embedded AWK program.
44
# Run: /bin/sh configure [options]
5+
set -eu
56

67
# _find_awk — pick a working AWK that is not gawk.
78
# gawk 5.2.x (Ubuntu 24.04) has a crash bug ("double free or corruption")
@@ -31,6 +32,7 @@ _tmpf=$(mktemp "${TMPDIR:-/tmp}/configure.XXXXXXXXXX") || exit 1
3132
trap 'rm -f "$_tmpf"' EXIT
3233
sed '1,/^#---AWK-START---$/d' "$0" > "$_tmpf"
3334
"$_awk" -f "$_tmpf" -- "$@"
35+
exit $?
3436
#---AWK-START---
3537
# === pyconf.awk runtime ===
3638
# pyconf.awk — AWK runtime library for the configure transpiler.

Tools/configure/transpiler/transpile.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@
3434
# Generated by transpile.py -- do not edit.
3535
# This is a POSIX shell wrapper around an embedded AWK program.
3636
# Run: /bin/sh configure [options]
37+
set -eu
3738
3839
# _find_awk — pick a working AWK that is not gawk.
3940
# gawk 5.2.x (Ubuntu 24.04) has a crash bug ("double free or corruption")
@@ -63,6 +64,7 @@
6364
trap 'rm -f "$_tmpf"' EXIT
6465
sed '1,/^#---AWK-START---$/d' "$0" > "$_tmpf"
6566
"$_awk" -f "$_tmpf" -- "$@"
67+
exit $?
6668
#---AWK-START---
6769
"""
6870

configure

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)