Commit f58f2f72 authored by Jason Madden's avatar Jason Madden

Do the build for libuv if needed.

parent 94f34f04
...@@ -44,6 +44,7 @@ from _setuplibev import CORE ...@@ -44,6 +44,7 @@ from _setuplibev import CORE
from _setupares import ARES from _setupares import ARES
from _setuplibuv import LIBUV from _setuplibuv import LIBUV
from _setuplibuv import configure_libuv
SEMAPHORE = Extension(name="gevent._semaphore", SEMAPHORE = Extension(name="gevent._semaphore",
sources=["src/gevent/gevent._semaphore.c"]) sources=["src/gevent/gevent._semaphore.c"])
...@@ -60,6 +61,7 @@ EXT_MODULES = [ ...@@ -60,6 +61,7 @@ EXT_MODULES = [
] ]
LIBEV_CFFI_MODULE = 'src/gevent/libev/_corecffi_build.py:ffi' LIBEV_CFFI_MODULE = 'src/gevent/libev/_corecffi_build.py:ffi'
LIBUV_CFFI_MODULE = 'src/gevent/libuv/_corecffi_build.py:ffi'
cffi_modules = [] cffi_modules = []
if not WIN: if not WIN:
...@@ -77,7 +79,7 @@ if not WIN: ...@@ -77,7 +79,7 @@ if not WIN:
EXT_MODULES.append(LIBUV) EXT_MODULES.append(LIBUV)
if not WIN or PYPY: if not WIN or PYPY:
cffi_modules.append('src/gevent/libuv/_corecffi_build.py:ffi') cffi_modules.append(LIBUV_CFFI_MODULE)
if PYPY: if PYPY:
install_requires = [] install_requires = []
...@@ -140,6 +142,8 @@ def run_setup(ext_modules, run_make): ...@@ -140,6 +142,8 @@ def run_setup(ext_modules, run_make):
# TODO: Generalize this. # TODO: Generalize this.
if LIBEV_CFFI_MODULE in cffi_modules and not WIN: if LIBEV_CFFI_MODULE in cffi_modules and not WIN:
system(libev_configure_command) system(libev_configure_command)
if LIBUV_CFFI_MODULE in cffi_modules and PYPY and WIN:
configure_libuv(None, None) # This actually also builds it too
MakeSdist.make() MakeSdist.make()
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment