diff options
author | Ian Henriksen <insertinterestingnamehere@gmail.com> | 2016-04-12 13:15:14 -0600 |
---|---|---|
committer | Stefan Behnel <stefan_ml@behnel.de> | 2016-07-15 08:18:00 +0200 |
commit | 3573565a256b9463a4f388da573de3b06b37661c (patch) | |
tree | 415f371d10facc78f67d5322de97e897ea298d8d | |
parent | 31e2afbccc819615eb700697a7cc5bae979e2f6b (diff) | |
download | cython-3573565a256b9463a4f388da573de3b06b37661c.tar.gz |
Forward define macros without specified values properly
when they are provided as commented distutils directives.
-rw-r--r-- | Cython/Build/Dependencies.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/Cython/Build/Dependencies.py b/Cython/Build/Dependencies.py index 42aacf8cc..9843da14e 100644 --- a/Cython/Build/Dependencies.py +++ b/Cython/Build/Dependencies.py @@ -209,7 +209,9 @@ class DistutilsInfo(object): if type in (list, transitive_list): value = parse_list(value) if key == 'define_macros': - value = [tuple(macro.split('=')) for macro in value] + value = [tuple(macro.split('=')) + if '=' in macro else (macro, None) + for macro in value] self.values[key] = value elif exn is not None: for key in distutils_settings: |