]> git.ipfire.org Git - thirdparty/automake.git/commitdiff
python: Don't use '\n' in sed substitution
authorMathieu Lirzin <mthl@gnu.org>
Sun, 8 Jul 2018 21:41:42 +0000 (23:41 +0200)
committerMathieu Lirzin <mthl@gnu.org>
Sun, 8 Jul 2018 21:57:10 +0000 (23:57 +0200)
This change fixes automake bug#31222.

On macOS, 'sed' interprets '\n' in the substitution text as the letter 'n'
instead of as a newline.

* lib/am/python.am [?FIRST?] (am__pep3147_tweak): Use a space instead of '\n'.
* NEWS: Update.

NEWS
lib/am/python.am

diff --git a/NEWS b/NEWS
index a49787d685d8709959f0a4e5b95d460f73eabd52..8d6eb3aae53bc40694968fa9549d0e70c16ef66f 100644 (file)
--- a/NEWS
+++ b/NEWS
 
 New in ?.?.?:
 
+* Bugs fixed
+
+  - When cleaning the compiled python files, '\n' is not used anymore in the
+    substitution text of 'sed' transformations.  This is done to preserve
+    compatibility with the 'sed' implementation provided by macOS which
+    considers '\n' as the 'n' character instead of a newline.
+    (automake bug#31222)
+
 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 
 New in 1.16.1:
index 21e6f842cadb35ddc451da1a44fff1720d3171df..c855cddaca33a7b3de9842c2b530f440eb9016d0 100644 (file)
@@ -97,7 +97,7 @@ endif %?INSTALL%
 if %?INSTALL%
 
 ?FIRST?am__pep3147_tweak = \
-?FIRST?  sed -e 's|\.py$$||' -e 's|[^/]*$$|&.*.pyc\n&.*.pyo|'
+?FIRST?  sed -e 's|\.py$$||' -e 's|[^/]*$$|&.*.pyc &.*.pyo|'
 
 .PHONY uninstall-am: uninstall-%DIR%PYTHON
 uninstall-%DIR%PYTHON: