Skip to content

GitLab

  • Projects
  • Groups
  • Snippets
  • Help
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
pypy
pypy
  • Project overview
    • Project overview
    • Details
    • Activity
    • Releases
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 603
    • Issues 603
    • List
    • Boards
    • Labels
    • Service Desk
    • Milestones
  • Merge Requests 13
    • Merge Requests 13
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Operations
    • Operations
    • Incidents
    • Environments
  • Packages & Registries
    • Packages & Registries
    • Container Registry
  • Analytics
    • Analytics
    • CI/CD
    • Repository
    • Value Stream
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Members
    • Members
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • PyPy
  • pypypypy
  • Issues
  • #3213

Closed
Open
Created Apr 16, 2020 by Jason Madden@jamadden

PyPy2.7 7.3 on Windows: Link errors in CFFI module using PyObject_Free, PyObject_Realloc, PyGILState_Ensure

gevent uses those functions in its CFFI modules. This worked fine in PyPy2 7.2.0 on all platforms, and it works in PyPy2 7.3.0 and PyPy3.6 7.3.0 on Linux, and it works in PyPy2.7 7.3.1 on macOS.

But it fails on PyPy2 7.3.1 and 7.3.0 on Windows:

    creating build\lib.win32-2.7\gevent\libuv
 C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\BIN\link.exe /DLL /nologo /INCREMENTAL:NO /LIBPATH:C:\pypy2.7-v7.3.1-win32\libs advapi32.lib iphlpapi.lib psapi.lib shell32.lib user32.lib userenv.lib ws2_32.lib /EXPORT:init_corecffi build\temp.win32-2.7\Release\build\temp.win32-2.7\Release\gevent.libuv._corecffi.obj build\temp.win32-2.7\Release\deps\libuv\src\fs-poll.obj build\temp.win32-2.7\Release\deps\libuv\src\inet.obj build\temp.win32-2.7\Release\deps\libuv\src\threadpool.obj build\temp.win32-2.7\Release\deps\libuv\src\uv-common.obj build\temp.win32-2.7\Release\deps\libuv\src\version.obj build\temp.win32-2.7\Release\deps\libuv\src\uv-data-getter-setters.obj build\temp.win32-2.7\Release\deps\libuv\src\timer.obj build\temp.win32-2.7\Release\deps\libuv\src\idna.obj build\temp.win32-2.7\Release\deps\libuv\src\strscpy.obj build\temp.win32-2.7\Release\deps\libuv\src\win/async.obj build\temp.win32-2.7\Release\deps\libuv\src\win/core.obj build\temp.win32-2.7\Release\deps\libuv\src\win/detect-wakeup.obj build\temp.win32-2.7\Release\deps\libuv\src\win/dl.obj build\temp.win32-2.7\Release\deps\libuv\src\win/error.obj build\temp.win32-2.7\Release\deps\libuv\src\win/fs-event.obj build\temp.win32-2.7\Release\deps\libuv\src\win/fs.obj build\temp.win32-2.7\Release\deps\libuv\src\win/handle.obj build\temp.win32-2.7\Release\deps\libuv\src\win/loop-watcher.obj build\temp.win32-2.7\Release\deps\libuv\src\win/pipe.obj build\temp.win32-2.7\Release\deps\libuv\src\win/poll.obj build\temp.win32-2.7\Release\deps\libuv\src\win/process-stdio.obj build\temp.win32-2.7\Release\deps\libuv\src\win/process.obj build\temp.win32-2.7\Release\deps\libuv\src\win/signal.obj build\temp.win32-2.7\Release\deps\libuv\src\win/snprintf.obj build\temp.win32-2.7\Release\deps\libuv\src\win/stream.obj build\temp.win32-2.7\Release\deps\libuv\src\win/tcp.obj build\temp.win32-2.7\Release\deps\libuv\src\win/thread.obj build\temp.win32-2.7\Release\deps\libuv\src\win/tty.obj build\temp.win32-2.7\Release\deps\libuv\src\win/udp.obj build\temp.win32-2.7\Release\deps\libuv\src\win/util.obj build\temp.win32-2.7\Release\deps\libuv\src\win/winapi.obj build\temp.win32-2.7\Release\deps\libuv\src\win/winsock.obj /OUT:build\lib.win32-2.7\gevent\libuv\_corecffi.pypy-73.pyd /IMPLIB:build\temp.win32-2.7\Release\build\temp.win32-2.7\Release\_corecffi.pypy-73.lib /MANIFEST /MANIFESTFILE:build\temp.win32-2.7\Release\build\temp.win32-2.7\Release\_corecffi.pypy-73.pyd.manifest
    Creating library build\temp.win32-2.7\Release\build\temp.win32-2.7\Release\_corecffi.pypy-73.lib and object build\temp.win32-2.7\Release\build\temp.win32-2.7\Release\_corecffi.pypy-73.exp
 gevent.libuv._corecffi.obj : error LNK2019: unresolved external symbol __imp__PyPyObject_Free referenced in function _gevent_realloc
 gevent.libuv._corecffi.obj : error LNK2019: unresolved external symbol __imp__PyPyGILState_Ensure referenced in function _gevent_realloc
 gevent.libuv._corecffi.obj : error LNK2019: unresolved external symbol __imp__PyPyGILState_Release referenced in function _gevent_realloc
 gevent.libuv._corecffi.obj : error LNK2019: unresolved external symbol __imp__PyPyObject_Realloc referenced in function _gevent_realloc
 build\lib.win32-2.7\gevent\libuv\_corecffi.pypy-73.pyd : fatal error LNK1120: 4 unresolved externals
 error: command 'C:\\Program Files (x86)\\Microsoft Visual Studio 14.0\\VC\\BIN\\link.exe' failed with exit status 1120

I didn't spot anything in PyPy's or CFFI's release notes, and I can't see the compiler commands used on 7.2.0 for a successful build because pip hides that output. I do see those symbols defined in python27.lib that ships with PyPy. Do I need to manually add some additional library now?

Thanks for any help!

To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
None
Milestone
None
Assign milestone
Time tracking
None
Due date
None