Files
MINGW-packages/mingw-w64-python-matplotlib/setupext.py.patch
2020-03-05 08:47:22 +03:00

29 lines
1019 B
Diff

--- matplotlib-3.1.0/setupext.py.orig 2019-05-18 03:55:28.000000000 +0200
+++ matplotlib-3.1.0/setupext.py 2019-05-19 11:31:01.633173900 +0200
@@ -24,6 +24,7 @@
_log = logging.getLogger(__name__)
+MSYS = "MSYSTEM" in os.environ
def _get_xdg_cache_dir():
"""
@@ -232,7 +233,7 @@
"""
Get path to pkg-config and set up the PKG_CONFIG environment variable.
"""
- if sys.platform == 'win32':
+ if sys.platform == 'win32' and not MSYS:
return None
pkg_config = os.environ.get('PKG_CONFIG', 'pkg-config')
if shutil.which(pkg_config) is None:
@@ -276,7 +277,7 @@
# conda Windows header and library paths.
# https://github.com/conda/conda/issues/2312 re: getting the env dir.
- if sys.platform == 'win32':
+ if sys.platform == 'win32' and not MSYS:
conda_env_path = (os.getenv('CONDA_PREFIX') # conda >= 4.1
or os.getenv('CONDA_DEFAULT_ENV')) # conda < 4.1
if conda_env_path and os.path.isdir(conda_env_path):