From 48c4334e08aedbe7dbeb1fb316a4c9fcb68149b3 Mon Sep 17 00:00:00 2001 From: stf <7o5rfu92t@ctrlc.hu> Date: Fri, 18 Oct 2019 21:06:06 +0000 Subject: community/capstone: fix search patch for python binding's lib without this fix the following happens: ``` % python3 -m capstone Traceback (most recent call last): File "/usr/lib/python3.7/runpy.py", line 183, in _run_module_as_main mod_name, mod_spec, code = _get_module_details(mod_name, _Error) File "/usr/lib/python3.7/runpy.py", line 142, in _get_module_details return _get_module_details(pkg_main_name, error) File "/usr/lib/python3.7/runpy.py", line 109, in _get_module_details __import__(pkg_name) File "/usr/lib/python3.7/site-packages/capstone/__init__.py", line 315, in raise ImportError("ERROR: fail to load the dynamic library.") ImportError: ERROR: fail to load the dynamic library. ``` it also adds a -static subpkg --- community/capstone/py-path-fix.patch | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 community/capstone/py-path-fix.patch (limited to 'community/capstone/py-path-fix.patch') diff --git a/community/capstone/py-path-fix.patch b/community/capstone/py-path-fix.patch new file mode 100644 index 0000000000..bf57d16e61 --- /dev/null +++ b/community/capstone/py-path-fix.patch @@ -0,0 +1,11 @@ +diff -urw src/capstone-4.0.1/bindings/python/capstone/__init__.py capstone-4.0.1/bindings/python/capstone/__init__.py +--- src/capstone-4.0.1/bindings/python/capstone/__init__.py 2019-01-10 13:45:56.000000000 +0000 ++++ capstone-4.0.1/bindings/python/capstone/__init__.py 2019-10-18 20:56:27.509240524 +0000 +@@ -301,6 +301,7 @@ + # - last-gasp attempt at some hardcoded paths on darwin and linux + + _path_list = [os.getenv('LIBCAPSTONE_PATH', None), ++ '/usr/lib/', + pkg_resources.resource_filename(__name__, 'lib'), + join(split(__file__)[0], 'lib'), + '', -- cgit v1.2.3