diff --git a/Makefile b/Makefile index da76ccdac..9169f08a2 100644 --- a/Makefile +++ b/Makefile @@ -163,7 +163,8 @@ develop: # Then start installing our deps so they can be cached. Note that use of --build-options / --global-options / --install-options # disables the cache. # We need wheel>=0.26 on Python 3.5. See previous revisions. - ${PIP} install -vv -U -r dev-requirements.txt + ${PIP} install -v -U -r dev-requirements.txt + cat deps/c-ares/ares_build.h lint-py27: $(PY27) PYTHON=python2.7.13 PATH=$(BUILD_RUNTIMES)/versions/python2.7.13/bin:$(PATH) make develop travis_test_linters diff --git a/_setupares.py b/_setupares.py index ef768cb50..73f8cca64 100644 --- a/_setupares.py +++ b/_setupares.py @@ -23,6 +23,7 @@ from _setuputils import DEFINE_MACROS from _setuputils import glob_many from _setuputils import dep_abspath +from _setuputils import RUNNING_ON_TRAVIS CARES_EMBED = should_embed('c-ares') @@ -83,7 +84,8 @@ def configure_ares(bext, ext): define_macros=list(DEFINE_MACROS), depends=glob_many('src/gevent/dnshelper.c', 'src/gevent/cares_*.[ch]')) -ARES.optional = True + +ARES.optional = not RUNNING_ON_TRAVIS if CARES_EMBED: diff --git a/_setuputils.py b/_setuputils.py index f3c897d16..6f8355da0 100644 --- a/_setuputils.py +++ b/_setuputils.py @@ -22,6 +22,7 @@ PYPY = hasattr(sys, 'pypy_version_info') WIN = sys.platform.startswith('win') CFFI_WIN_BUILD_ANYWAY = os.environ.get("PYPY_WIN_BUILD_ANYWAY") +RUNNING_ON_TRAVIS = os.environ.get('TRAVIS') LIBRARIES = [] DEFINE_MACROS = [] diff --git a/setup.py b/setup.py index 847af3393..b5dc060f0 100755 --- a/setup.py +++ b/setup.py @@ -187,7 +187,7 @@ def run_setup(ext_modules, run_make): try: run_setup(EXT_MODULES, run_make=_BUILDING) except BuildFailed: - if ARES not in EXT_MODULES: + if ARES not in EXT_MODULES or not ARES.optional: raise EXT_MODULES.remove(ARES) run_setup(EXT_MODULES, run_make=_BUILDING)