diff options
author | Paulo Neves <ptsneves@gmail.com> | 2019-11-12 12:52:42 +0100 |
---|---|---|
committer | Jussi Pakkanen <jpakkane@gmail.com> | 2019-11-13 22:04:15 +0200 |
commit | 07389e23bc225adb9f9462e2fec1272ee24062e9 (patch) | |
tree | 425b7ed0da0de8e008a487b987ca92f31813facc /mesonbuild | |
parent | 2a73517e0808dbedb561f9670401d18309893eb0 (diff) | |
download | meson-07389e23bc225adb9f9462e2fec1272ee24062e9.zip meson-07389e23bc225adb9f9462e2fec1272ee24062e9.tar.gz meson-07389e23bc225adb9f9462e2fec1272ee24062e9.tar.bz2 |
coredata: CmdLineFileParser no longer interpolates strings.
Previously if a user tried to pass a command line build
option that contained a '%' character the command line
parser assumed that there was string interpolation to be
done. As there is no sense in such a scenario no code
provides any input for the interpolation. This then leads to
a failure.
In this commit we specifically override the defaults in
ConfigParser and set interpolation to None, which disables
command line build option interpolation.
Fixes #6157
Diffstat (limited to 'mesonbuild')
-rw-r--r-- | mesonbuild/coredata.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/mesonbuild/coredata.py b/mesonbuild/coredata.py index 05cde4d..a5898f1 100644 --- a/mesonbuild/coredata.py +++ b/mesonbuild/coredata.py @@ -776,7 +776,7 @@ class CmdLineFileParser(configparser.ConfigParser): def __init__(self): # We don't want ':' as key delimiter, otherwise it would break when # storing subproject options like "subproject:option=value" - super().__init__(delimiters=['=']) + super().__init__(delimiters=['='], interpolation=None) def get_cmd_line_file(build_dir): return os.path.join(build_dir, 'meson-private', 'cmd_line.txt') |