[ 
https://issues.apache.org/jira/browse/ARROW-6015?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16920236#comment-16920236
 ] 

Kazuaki Ishizaki edited comment on ARROW-6015 at 9/1/19 4:21 PM:
-----------------------------------------------------------------

I think that {{numba}} (preciously {{llvmlite}}) has the same problem regarding 
the CRT DLLs. 
A DLL load error occurs before executing {{vc_redist.x64.exe}}. The error 
disappear after executing {{vc_redist.x64.exe}}.
{code:java}
> cd \numba\python-3.7.4-embed-amd64
> python -m pip install numba
Collecting numba
...
Installing collected packages: llvmlite, numba
Successfully installed llvmlite-0.29.0 numba-0.45.1

> \cygwin64\bin\find . -name "msv*"
./Lib/site-packages/numpy/distutils/msvc9compiler.py
./Lib/site-packages/numpy/distutils/msvccompiler.py
./Lib/site-packages/numpy/distutils/__pycache__/msvc9compiler.cpython-37.pyc
./Lib/site-packages/numpy/distutils/__pycache__/msvccompiler.cpython-37.pyc
./Lib/site-packages/setuptools/msvc.py
./Lib/site-packages/setuptools/__pycache__/msvc.cpython-37.pyc

> python -c "import numpy"
>  \cygwin64\bin\find . -name "msv*"
./Lib/site-packages/numpy/distutils/msvc9compiler.py
./Lib/site-packages/numpy/distutils/msvccompiler.py
./Lib/site-packages/numpy/distutils/__pycache__/msvc9compiler.cpython-37.pyc
./Lib/site-packages/numpy/distutils/__pycache__/msvccompiler.cpython-37.pyc
./Lib/site-packages/setuptools/msvc.py
./Lib/site-packages/setuptools/__pycache__/msvc.cpython-37.pyc
> type Lib\site-packages\numpy\LICENSE.txt
...
Name: Microsoft Visual C++ Runtime Files
Files: extra-dll\msvcp140.dll
License: MSVC
  
https://www.visualstudio.com/license-terms/distributable-code-microsoft-visual-studio-2015-rc-microsoft-visual-studio-2015-sdk-rc-includes-utilities-buildserver-files/#visual-c-runtime

  Subject to the License Terms for the software, you may copy and
  distribute with your program any of the files within the followng
  folder and its subfolders except as noted below. You may not modify
  these files.

    C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\redist

  You may not distribute the contents of the following folders:

    C:\Program Files (x86)\Microsoft Visual Studio 
14.0\VC\redist\debug_nonredist
    C:\Program Files (x86)\Microsoft Visual Studio 
14.0\VC\redist\onecore\debug_nonredist

  Subject to the License Terms for the software, you may copy and
  distribute the following files with your program in your programΓÇÖs
  application local folder or by deploying them into the Global
  Assembly Cache (GAC):

  VC\atlmfc\lib\mfcmifc80.dll
  VC\atlmfc\lib\amd64\mfcmifc80.dll


Name: Microsoft Visual C++ Runtime Files
Files: extra-dll\msvc*90.dll, extra-dll\Microsoft.VC90.CRT.manifest
License: MSVC
  For your convenience, we have provided the following folders for
  use when redistributing VC++ runtime files. Subject to the license
  terms for the software, you may redistribute the folder
  (unmodified) in the application local folder as a sub-folder with
  no change to the folder name. You may also redistribute all the
  files (*.dll and *.manifest) within a folder, listed below the
  folder for your convenience, as an entire set.

  \VC\redist\x86\Microsoft.VC90.ATL\
   atl90.dll
   Microsoft.VC90.ATL.manifest
  \VC\redist\ia64\Microsoft.VC90.ATL\
   atl90.dll
   Microsoft.VC90.ATL.manifest
  \VC\redist\amd64\Microsoft.VC90.ATL\
   atl90.dll
   Microsoft.VC90.ATL.manifest
  \VC\redist\x86\Microsoft.VC90.CRT\
   msvcm90.dll
   msvcp90.dll
   msvcr90.dll
   Microsoft.VC90.CRT.manifest
  \VC\redist\ia64\Microsoft.VC90.CRT\
   msvcm90.dll
   msvcp90.dll
   msvcr90.dll
   Microsoft.VC90.CRT.manifest
...

> python -c "import numba"
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "C:\numba\python-3.7.4-embed-amd64\lib\site-packages\numba\__init__.py", 
line 15, in <module>
    from . import config, errors, _runtests as runtests, types
  File "C:\numba\python-3.7.4-embed-amd64\lib\site-packages\numba\config.py", 
line 18, in <module>
    import llvmlite.binding as ll
  File 
"C:\numba\python-3.7.4-embed-amd64\lib\site-packages\llvmlite\binding\__init__.py",
 line 6, in <module>
    from .dylib import *
  File 
"C:\numba\python-3.7.4-embed-amd64\lib\site-packages\llvmlite\binding\dylib.py",
 line 4, in <module>
    from . import ffi
  File 
"C:\numba\python-3.7.4-embed-amd64\lib\site-packages\llvmlite\binding\ffi.py", 
line 154, in <module>
    raise OSError("Could not load shared object file: {}".format(_lib_name))
OSError: Could not load shared object file: llvmlite.dll
> python -c "llvmlite.binding as ll"
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File 
"C:\numba\python-3.7.4-embed-amd64\lib\site-packages\llvmlite\binding\__init__.py",
 line 6, in <module>
    from .dylib import *
  File 
"C:\numba\python-3.7.4-embed-amd64\lib\site-packages\llvmlite\binding\dylib.py",
 line 4, in <module>
    from . import ffi
  File 
"C:\numba\python-3.7.4-embed-amd64\lib\site-packages\llvmlite\binding\ffi.py", 
line 154, in <module>
    raise OSError("Could not load shared object file: {}".format(_lib_name))
OSError: Could not load shared object file: llvmlite.dll
> >bitsadmin /TRANSFER htmlget https://aka.ms/vs/16/release/vc_redist.x64.exe 
> >c:\numba\vc_redist.x64.exe
> ../vc_redist.x64.exe
> python -c "import llvmlite.binding as ll"
> python -c "import numba"
> 
{code}


was (Author: kiszk):
After installing numba package to Python, I cannot still find the CRT DLL files 
under the directory. I think that {{numpy}} statically links the CRT DLLs.

NOTE: I met the DLL loading problem of llvmlite in a fresh Windows10 instance. 
I think this is another known issue in numba.

{code}
> cd \numba\python-3.7.4-embed-amd64
> python -m pip install numba
Collecting numba
...
Installing collected packages: llvmlite, numba
Successfully installed llvmlite-0.29.0 numba-0.45.1

> \cygwin64\bin\find . -name "msv*"
./Lib/site-packages/numpy/distutils/msvc9compiler.py
./Lib/site-packages/numpy/distutils/msvccompiler.py
./Lib/site-packages/numpy/distutils/__pycache__/msvc9compiler.cpython-37.pyc
./Lib/site-packages/numpy/distutils/__pycache__/msvccompiler.cpython-37.pyc
./Lib/site-packages/setuptools/msvc.py
./Lib/site-packages/setuptools/__pycache__/msvc.cpython-37.pyc

> python -c "import numpy"
>  \cygwin64\bin\find . -name "msv*"
./Lib/site-packages/numpy/distutils/msvc9compiler.py
./Lib/site-packages/numpy/distutils/msvccompiler.py
./Lib/site-packages/numpy/distutils/__pycache__/msvc9compiler.cpython-37.pyc
./Lib/site-packages/numpy/distutils/__pycache__/msvccompiler.cpython-37.pyc
./Lib/site-packages/setuptools/msvc.py
./Lib/site-packages/setuptools/__pycache__/msvc.cpython-37.pyc
> type Lib\site-packages\numpy\LICENSE.txt
...
Name: Microsoft Visual C++ Runtime Files
Files: extra-dll\msvcp140.dll
License: MSVC
  
https://www.visualstudio.com/license-terms/distributable-code-microsoft-visual-studio-2015-rc-microsoft-visual-studio-2015-sdk-rc-includes-utilities-buildserver-files/#visual-c-runtime

  Subject to the License Terms for the software, you may copy and
  distribute with your program any of the files within the followng
  folder and its subfolders except as noted below. You may not modify
  these files.

    C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\redist

  You may not distribute the contents of the following folders:

    C:\Program Files (x86)\Microsoft Visual Studio 
14.0\VC\redist\debug_nonredist
    C:\Program Files (x86)\Microsoft Visual Studio 
14.0\VC\redist\onecore\debug_nonredist

  Subject to the License Terms for the software, you may copy and
  distribute the following files with your program in your programΓÇÖs
  application local folder or by deploying them into the Global
  Assembly Cache (GAC):

  VC\atlmfc\lib\mfcmifc80.dll
  VC\atlmfc\lib\amd64\mfcmifc80.dll


Name: Microsoft Visual C++ Runtime Files
Files: extra-dll\msvc*90.dll, extra-dll\Microsoft.VC90.CRT.manifest
License: MSVC
  For your convenience, we have provided the following folders for
  use when redistributing VC++ runtime files. Subject to the license
  terms for the software, you may redistribute the folder
  (unmodified) in the application local folder as a sub-folder with
  no change to the folder name. You may also redistribute all the
  files (*.dll and *.manifest) within a folder, listed below the
  folder for your convenience, as an entire set.

  \VC\redist\x86\Microsoft.VC90.ATL\
   atl90.dll
   Microsoft.VC90.ATL.manifest
  \VC\redist\ia64\Microsoft.VC90.ATL\
   atl90.dll
   Microsoft.VC90.ATL.manifest
  \VC\redist\amd64\Microsoft.VC90.ATL\
   atl90.dll
   Microsoft.VC90.ATL.manifest
  \VC\redist\x86\Microsoft.VC90.CRT\
   msvcm90.dll
   msvcp90.dll
   msvcr90.dll
   Microsoft.VC90.CRT.manifest
  \VC\redist\ia64\Microsoft.VC90.CRT\
   msvcm90.dll
   msvcp90.dll
   msvcr90.dll
   Microsoft.VC90.CRT.manifest
...

/// When I run numba in a fresh Window10 instance, I got the following error. 
But, I think that it is not an issue due to DLL. I will invesitgate this 
afternoon in JST.
> python -c "import numba"
C:\numba\python-3.7.4-embed-amd64>python -c "import numba"
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "C:\numba\python-3.7.4-embed-amd64\lib\site-packages\numba\__init__.py", 
line 15, in <module>
    from . import config, errors, _runtests as runtests, types
  File "C:\numba\python-3.7.4-embed-amd64\lib\site-packages\numba\config.py", 
line 18, in <module>
    import llvmlite.binding as ll
  File 
"C:\numba\python-3.7.4-embed-amd64\lib\site-packages\llvmlite\binding\__init__.py",
 line 6, in <module>
    from .dylib import *
  File 
"C:\numba\python-3.7.4-embed-amd64\lib\site-packages\llvmlite\binding\dylib.py",
 line 4, in <module>
    from . import ffi
  File 
"C:\numba\python-3.7.4-embed-amd64\lib\site-packages\llvmlite\binding\ffi.py", 
line 154, in <module>
    raise OSError("Could not load shared object file: {}".format(_lib_name))
OSError: Could not load shared object file: llvmlite.dll
{code}

> [Python] pyarrow wheel:  `DLL load failed` when importing on windows
> --------------------------------------------------------------------
>
>                 Key: ARROW-6015
>                 URL: https://issues.apache.org/jira/browse/ARROW-6015
>             Project: Apache Arrow
>          Issue Type: Bug
>          Components: Packaging, Python
>    Affects Versions: 0.14.1
>            Reporter: Ruslan Kuprieiev
>            Priority: Major
>              Labels: wheel
>             Fix For: 0.15.0
>
>
> When installing pyarrow 0.14.1 on windows 10 x64 with python 3.7, you get:
> >>> import pyarrow
> Traceback (most recent call last):
>   File "<stdin>", line 1, in <module>
>   File "C:\Python37\lib\site-packages\pyarrow\__init__.py", line 49, in 
> <module>
>     from pyarrow.lib import cpu_count, set_cpu_count
>   ImportError: DLL load failed: The specified module could not be found.
>  On 0.14.0 everything works fine.



--
This message was sent by Atlassian Jira
(v8.3.2#803003)

Reply via email to