Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

pip install get an error #38

Open
wangzhichao1990 opened this issue Apr 7, 2024 · 1 comment
Open

pip install get an error #38

wangzhichao1990 opened this issue Apr 7, 2024 · 1 comment

Comments

@wangzhichao1990
Copy link

Hi,
when pip install rds2py, there is an error.

Building wheels for collected packages: rds2py
  Building wheel for rds2py (pyproject.toml) ... error
  error: subprocess-exited-with-error

  × Building wheel for rds2py (pyproject.toml) did not run successfully.
  │ exit code: 1
  ╰─> [70 lines of output]
      running bdist_wheel
      running build
      running build_py
      creating build
      creating build\lib.win-amd64-cpython-311
      creating build\lib.win-amd64-cpython-311\rds2py
      copying src\rds2py\granges.py -> build\lib.win-amd64-cpython-311\rds2py
      copying src\rds2py\interface.py -> build\lib.win-amd64-cpython-311\rds2py
      copying src\rds2py\parser.py -> build\lib.win-amd64-cpython-311\rds2py
      copying src\rds2py\pdf.py -> build\lib.win-amd64-cpython-311\rds2py
      copying src\rds2py\__init__.py -> build\lib.win-amd64-cpython-311\rds2py
      running egg_info
      writing src\rds2py.egg-info\PKG-INFO
      writing dependency_links to src\rds2py.egg-info\dependency_links.txt
      writing requirements to src\rds2py.egg-info\requires.txt
      writing top-level names to src\rds2py.egg-info\top_level.txt
      dependency C:\Users\wangzc6\AppData\Local\Temp\pip-build-env-w1d4em1u\overlay\Lib\site-packages\numpy\core\include\numpy\arrayobject.h won't be automatically included in the manifest: the path must be relative
      dependency C:\Users\wangzc6\AppData\Local\Temp\pip-build-env-w1d4em1u\overlay\Lib\site-packages\numpy\core\include\numpy\arrayscalars.h won't be automatically included in the manifest: the path must be relative
      dependency C:\Users\wangzc6\AppData\Local\Temp\pip-build-env-w1d4em1u\overlay\Lib\site-packages\numpy\core\include\numpy\ndarrayobject.h won't be automatically included in the manifest: the path must be relative
      dependency C:\Users\wangzc6\AppData\Local\Temp\pip-build-env-w1d4em1u\overlay\Lib\site-packages\numpy\core\include\numpy\ndarraytypes.h won't be automatically included in the manifest: the path must be relative
      dependency C:\Users\wangzc6\AppData\Local\Temp\pip-build-env-w1d4em1u\overlay\Lib\site-packages\numpy\core\include\numpy\ufuncobject.h won't be automatically included in the manifest: the path must be relative
      ERROR setuptools_scm._file_finders.git listing git files failed - pretending there aren't any
      reading manifest file 'src\rds2py.egg-info\SOURCES.txt'
      reading manifest template 'MANIFEST.in'
      warning: manifest_maker: MANIFEST.in, line 1: path 'src/rds2py/lib/' cannot end with '/'

      adding license file 'LICENSE.txt'
      writing manifest file 'src\rds2py.egg-info\SOURCES.txt'
      creating build\lib.win-amd64-cpython-311\rds2py\lib
      copying src\rds2py\lib\parser.cpp -> build\lib.win-amd64-cpython-311\rds2py\lib
      copying src\rds2py\lib\parser.pxd -> build\lib.win-amd64-cpython-311\rds2py\lib
      copying src\rds2py\lib\parser.pyx -> build\lib.win-amd64-cpython-311\rds2py\lib
      copying src\rds2py\lib\rds_parser.cpp -> build\lib.win-amd64-cpython-311\rds2py\lib
      running build_ext
      building 'rds2py.core' extension
      creating build\temp.win-amd64-cpython-311
      creating build\temp.win-amd64-cpython-311\Release
      creating build\temp.win-amd64-cpython-311\Release\src
      creating build\temp.win-amd64-cpython-311\Release\src\rds2py
      creating build\temp.win-amd64-cpython-311\Release\src\rds2py\lib
      "C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\VC\Tools\MSVC\14.39.33519\bin\HostX86\x64\cl.exe" /c /nologo /O2 /W3 /GL /DNDEBUG /MD -Isrc/rds2py/lib -Iextern/rds2cpp/include -Iextern/rds2cpp/_deps/byteme-src/include -IC:\Users\wangzc6\AppData\Local\Temp\pip-build-env-w1d4em1u\overlay\Lib\site-packages\numpy\core\include -IC:\Users\wangzc6\AppData\Local\Programs\Python\Python311\include -IC:\Users\wangzc6\AppData\Local\Programs\Python\Python311\Include "-IC:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\VC\Tools\MSVC\14.39.33519\include" "-IC:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\VC\Auxiliary\VS\include" "-IC:\Program Files (x86)\Windows Kits\10\include\10.0.22621.0\ucrt" "-IC:\Program Files (x86)\Windows Kits\10\\include\10.0.22621.0\\um" "-IC:\Program Files (x86)\Windows Kits\10\\include\10.0.22621.0\\shared" "-IC:\Program Files (x86)\Windows Kits\10\\include\10.0.22621.0\\winrt" "-IC:\Program Files (x86)\Windows Kits\10\\include\10.0.22621.0\\cppwinrt" /EHsc /Tpsrc/rds2py/lib/parser.cpp /Fobuild\temp.win-amd64-cpython-311\Release\src/rds2py/lib/parser.obj -std=c++17
      cl: 命令行 warning D9002 :忽略未知选项“-std=c++17”
      parser.cpp
      C:\Users\wangzc6\AppData\Local\Temp\pip-install-37aj9oqi\rds2py_7099a0424826431a89ef09af5d1a5ae6\extern\rds2cpp\_deps\byteme-src\include\byteme\ChunkedBufferReader.hpp(28): warning C4146: 一元负运算符应用于无符号类型,结果仍为无符号类型
      C:\Users\wangzc6\AppData\Local\Temp\pip-install-37aj9oqi\rds2py_7099a0424826431a89ef09af5d1a5ae6\extern\rds2cpp\include\rds2cpp\utils_write.hpp(23): warning C4267: “参数”: 从“size_t”转换到“int32_t”,可能丢失数据
      extern/rds2cpp/_deps/byteme-src/include\byteme/GzipFileWriter.hpp(65): error C3646: “gz”: 未知重写说明符
      extern/rds2cpp/_deps/byteme-src/include\byteme/GzipFileWriter.hpp(65): error C4430: 缺少类型说明符 - 假定为 int。注意: C++ 不支持默认 int
      extern/rds2cpp/_deps/byteme-src/include\byteme/GzipFileWriter.hpp(29): error C2614: “byteme::GzipFileWriter”: 非法的成员初始化:“gz”不是基或成员
      extern/rds2cpp/_deps/byteme-src/include\byteme/GzipFileWriter.hpp(30): error C2065: “gz”: 未声明的标识符
      extern/rds2cpp/_deps/byteme-src/include\byteme/GzipFileWriter.hpp(30): error C3861: “gzbuffer”: 找不到标识符
      extern/rds2cpp/_deps/byteme-src/include\byteme/GzipFileWriter.hpp(33): error C2065: “gz”: 未声明的标识符
      extern/rds2cpp/_deps/byteme-src/include\byteme/GzipFileWriter.hpp(33): error C2065: “Z_DEFAULT_STRATEGY”: 未声明的标识符
      extern/rds2cpp/_deps/byteme-src/include\byteme/GzipFileWriter.hpp(33): error C3861: “gzsetparams”: 找不到标识符
      extern/rds2cpp/_deps/byteme-src/include\byteme/GzipFileWriter.hpp(33): error C2065: “Z_OK”: 未声明的标识符
      extern/rds2cpp/_deps/byteme-src/include\byteme/GzipFileWriter.hpp(50): error C2065: “gz”: 未声明的标识符
      extern/rds2cpp/_deps/byteme-src/include\byteme/GzipFileWriter.hpp(50): error C3861: “gzwrite”: 找不到标识符
      extern/rds2cpp/_deps/byteme-src/include\byteme/GzipFileWriter.hpp(58): error C2065: “gz”: 未声明的标识符
      extern/rds2cpp/_deps/byteme-src/include\byteme/GzipFileWriter.hpp(59): error C2065: “gz”: 未声明的标识符
      extern/rds2cpp/_deps/byteme-src/include\byteme/GzipFileWriter.hpp(59): error C3861: “gzclose”: 找不到标识符
      extern/rds2cpp/_deps/byteme-src/include\byteme/GzipFileWriter.hpp(59): error C2065: “Z_OK”: 未声明的标识符
      C:\Users\wangzc6\AppData\Local\Temp\pip-build-env-w1d4em1u\overlay\Lib\site-packages\numpy\core\include\numpy\npy_1_7_deprecated_api.h(14) : Warning Msg: Using deprecated NumPy API, disable it with #define NPY_NO_DEPRECATED_API NPY_1_7_API_VERSION
      src/rds2py/lib/parser.cpp(26908): warning C4146: 一元负运算符应用于无符号类型,结果仍为无符号类型
      src/rds2py/lib/parser.cpp(31388): warning C4551: 缺少参数列表的函数调用


      An error occurred while building the project, please ensure you have the most updated version of setuptools, setuptools_scm and wheel with:
         pip install -U setuptools setuptools_scm wheel


      error: command 'C:\\Program Files (x86)\\Microsoft Visual Studio\\2022\\BuildTools\\VC\\Tools\\MSVC\\14.39.33519\\bin\\HostX86\\x64\\cl.exe' failed with exit code 2
      [end of output]

  note: This error originates from a subprocess, and is likely not a problem with pip.
  ERROR: Failed building wheel for rds2py
Failed to build rds2py
ERROR: Could not build wheels for rds2py, which is required to install pyproject.toml-based projects

Can you take a look at how to handle it? Thank you.

@jkanche
Copy link
Member

jkanche commented Apr 8, 2024

I don't have a lot of experience building wheels for/on windows based systems, but looking at the log stack, it seems to be missing the zlib headers. Is that something you can install and try? I would love if you can help us solve this!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants