diff options
| author | Guillaume Poirier-Morency <guillaumepoiriermorency@gmail.com> | 2017-05-02 16:48:30 -0400 |
|---|---|---|
| committer | Guillaume Poirier-Morency <guillaumepoiriermorency@gmail.com> | 2017-05-02 16:54:13 -0400 |
| commit | 253201d9bf1adb0e2cd55fb29dbbd22c3328ef32 (patch) | |
| tree | 480a5c68ccf2654ca7632ff689cd81601ca145cf | |
| parent | ce2e36fd6e6c6fa966ae5d1da72f0f3ef588dab4 (diff) | |
| download | meson-253201d9bf1adb0e2cd55fb29dbbd22c3328ef32.tar.gz | |
ninjabackend: Add a set of raw names
| -rw-r--r-- | mesonbuild/backend/ninjabackend.py | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/mesonbuild/backend/ninjabackend.py b/mesonbuild/backend/ninjabackend.py index d14ad6a38..19adb2ae0 100644 --- a/mesonbuild/backend/ninjabackend.py +++ b/mesonbuild/backend/ninjabackend.py @@ -112,11 +112,12 @@ class NinjaBuildElement: line = line.replace('\\', '/') outfile.write(line) + # All the entries that should remain unquoted + raw_names = {'DEPFILE', 'DESC', 'pool', 'description'} + for e in self.elems: (name, elems) = e - should_quote = True - if name == 'DEPFILE' or name == 'DESC' or name == 'pool' or name == 'description': - should_quote = False + should_quote = name not in raw_names line = ' %s = ' % name q_templ = quote_char + "%s" + quote_char noq_templ = "%s" |
