diff options
author | Campbell Barton <ideasman42@gmail.com> | 2014-03-04 22:39:53 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2014-03-04 22:40:47 +0400 |
commit | 7cb8b6f538b735e0e6019663b36d39b54491b5ac (patch) | |
tree | 665f2d11e5ab219ae21671b1589269aace8ac943 /CMakeLists.txt | |
parent | 9ecf73f7036c9d8482d95075916f48f9a7a806c1 (diff) |
Build system: add cmake option to install requests
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r-- | CMakeLists.txt | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 46690f3a5b7..169aeffdbef 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -265,6 +265,10 @@ option(WITH_PYTHON_INSTALL_NUMPY "Copy system numpy into the blender install fol set(PYTHON_NUMPY_PATH "" CACHE PATH "Python to python site-packages or dist-packages containing 'numpy' module") mark_as_advanced(PYTHON_NUMPY_PATH) +if(UNIX AND NOT APPLE) + option(WITH_PYTHON_INSTALL_REQUESTS "Copy system requests into the blender install folder" ON) +endif() + # Cycles option(WITH_CYCLES "Enable cycles Render Engine" ON) option(WITH_CYCLES_STANDALONE "Build cycles standalone application" OFF) @@ -2255,6 +2259,17 @@ if(WITH_PYTHON) unset(_PY_VER_MAJOR) endif() endif() + + if(WIN32 OR APPLE) + # pass, we have this in lib/python/site-packages + elseif(WITH_PYTHON_INSTALL_REQUESTS) + if(NOT EXISTS ${PYTHON_LIBPATH}/python${PYTHON_VERSION}/site-packages/requests) + message(WARNING "'requests' path could not be found in:\n" + "'${PYTHON_LIBPATH}/python${PYTHON_VERSION}/site-packages/requests'\n" + "WITH_PYTHON_INSTALL_REQUESTS option will be ignored when installing python") + set(WITH_PYTHON_INSTALL_REQUESTS OFF) + endif() + endif() endif() if(WITH_GCC_MUDFLAP) |