0001-Link-to-dl-library.patch 848 B

123456789101112131415161718192021
  1. --- cffi-1.15.1.orig/setup.py 2022-06-30 13:38:43.000000000 -0300
  2. +++ cffi-1.15.1/setup.py 2022-07-02 13:49:37.189516459 -0300
  3. @@ -1,6 +1,7 @@
  4. import sys, os, platform
  5. import subprocess
  6. import errno
  7. +import sysconfig
  8. # on Windows we give up and always import setuptools early to fix things for us
  9. if sys.platform == "win32":
  10. @@ -113,6 +114,10 @@
  11. _ask_pkg_config(library_dirs, '--libs-only-L', '-L', sysroot=True)
  12. _ask_pkg_config(extra_link_args, '--libs-only-other')
  13. _ask_pkg_config(libraries, '--libs-only-l', '-l')
  14. + # This is needed for linking to 'dlopen', 'dlclose', 'dlsym' and 'dlerror'
  15. + # from _cffi_backend.c for uClibc.
  16. + if '-ldl' in ''.join(sysconfig.get_config_vars('LIBS')).split(' '):
  17. + libraries.append('dl')
  18. def use_homebrew_for_libffi():
  19. # We can build by setting: