diff options
author | Dean Moldovan <dean0x7d@gmail.com> | 2016-06-11 01:03:43 +0200 |
---|---|---|
committer | Dean Moldovan <dean0x7d@gmail.com> | 2016-06-12 01:53:46 +0200 |
commit | 22a3c2d10f342239f90908e5beba59928622a534 (patch) | |
tree | 74f023c5cc2838a7ad1c73a5270de6cf66ed9df6 /setup.py | |
parent | b6d1cd61b55e84583fe3505a462e3852fee8d7bd (diff) |
Fix compiler error on Windows
Diffstat (limited to 'setup.py')
-rw-r--r-- | setup.py | 4 |
1 files changed, 3 insertions, 1 deletions
@@ -78,11 +78,13 @@ class BuildExt(build_ext): def build_extensions(self): ct = self.compiler.compiler_type opts = self.c_opts.get(ct, []) - opts.append('-DVERSION_INFO="%s"' % self.distribution.get_version()) if ct == 'unix': + opts.append('-DVERSION_INFO="%s"' % self.distribution.get_version()) opts.append(cpp_flag(self.compiler)) if has_flag(self.compiler, '-fvisibility=hidden'): opts.append('-fvisibility=hidden') + elif ct == 'msvc': + opts.append('/DVERSION_INFO=\\"%s\\"' % self.distribution.get_version()) for ext in self.extensions: ext.extra_compile_args = opts build_ext.build_extensions(self) |