From a50053ffbe2d0288507fe2c42630c9fe9a087292 Mon Sep 17 00:00:00 2001 From: Jun Wu Date: Tue, 9 Jan 2018 10:33:45 -0800 Subject: [PATCH] cython: build all extensions by default Summary: clindex does not use any POSIX APIs so it can work on Windows. Test Plan: `make local` on both Windows and Linux. Reviewers: durham, #mercurial Reviewed By: durham Differential Revision: https://phabricator.intern.facebook.com/D6684821 Signature: 6684821:1515523520:aa48d4669fe658563f9457fc1a6194ec7fadd937 --- setup.py | 19 ++++++------------- 1 file changed, 6 insertions(+), 13 deletions(-) diff --git a/setup.py b/setup.py index 35b4e125cd..af48f1c16c 100644 --- a/setup.py +++ b/setup.py @@ -1049,21 +1049,14 @@ cythonopts = { 'c_string_type': 'bytes', } -cythonmodules = [ +extmodules += cythonize([ + Extension('mercurial.cyext.clindex', + sources=['mercurial/cyext/clindex.pyx'], + extra_compile_args=filter(None, [STDC99, PRODUCEDEBUGSYMBOLS])), Extension('mercurial.cyext.linelog', sources=['mercurial/cyext/linelog.pyx'], - extra_compile_args=filter(None, [STDC99])) -] - -if not iswindows: - cythonmodules += [ - Extension('mercurial.cyext.clindex', - sources=['mercurial/cyext/clindex.pyx'], - extra_compile_args=filter(None, [STDC99])), - ] - -for cm in cythonmodules: - extmodules += cythonize(cm, compiler_directives=cythonopts) + extra_compile_args=filter(None, [STDC99, PRODUCEDEBUGSYMBOLS])), +], compiler_directives=cythonopts) libraries = [ ("datapack", {