Skip to content

Commit d81161a

Browse files
committed
unix: work around sed -i portability issues
1 parent e14fb9f commit d81161a

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

cpython-unix/build-cpython.sh

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,8 @@ EOF
9898
# ``#ifdef __APPLE__`` instead of a more specific feature flag. All
9999
# occurrences of __APPLE__ in that file are related to libedit. So we
100100
# just replace the content.
101-
sed -i s/__APPLE__/USE_LIBEDIT/g Modules/readline-libedit.c
101+
sed s/__APPLE__/USE_LIBEDIT/g Modules/readline-libedit.c > tmp
102+
mv tmp Modules/readline-libedit.c
102103

103104
# Most bits look at CFLAGS. But setup.py only looks at CPPFLAGS.
104105
# So we need to set both.

0 commit comments

Comments
 (0)