Skip to content

Commit 99ea49d

Browse files
committed
Update get_library_dirs on windows
1 parent a3f6707 commit 99ea49d

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

python/pyarrow/__init__.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -431,6 +431,14 @@ def append_library_dir(library_dir):
431431
if _os.path.exists(pyarrow_libs_dir):
432432
append_library_dir(pyarrow_libs_dir)
433433

434+
# Source installations on Windows into a conda environment need to
435+
# expose the appropriate conda directories that Arrow C++ installs
436+
# to by default
437+
if _os.environ.get('CONDA_PREFIX'):
438+
prefix = _os.environ['CONDA_PREFIX']
439+
append_library_dir(_os.path.join(prefix, 'bin'))
440+
append_library_dir(_os.path.join(prefix, 'Lib'))
441+
434442
# ARROW-4074: Allow for ARROW_HOME to be set to some other directory
435443
if _os.environ.get('ARROW_HOME'):
436444
append_library_dir(_os.path.join(_os.environ['ARROW_HOME'], 'lib'))

0 commit comments

Comments
 (0)