capstone/bindings
Benno Fünfstück b446327f3b python-bindings: fix setup.py for wheel installation
When the python bindings are installed using the new wheels
infrastructure, data_files are relative to the site-packages directory
even if using absolute paths.

The following example demonstrates the bug fixed by this commit: (ran on archlinux)

```bash
$ pip install wheel       # if this package is installed, wheel installation is made the default
Collecting wheel
  Downloading wheel-0.29.0-py2.py3-none-any.whl (66kB)
    100% |################################| 71kB 124kB/s
Installing collected packages: wheel
Successfully installed wheel-0.29.0

$ pip install capstone    # this will use the wheel installation method now
Collecting capstone
  Using cached capstone-3.0.4.tar.gz
Building wheels for collected packages: capstone
  Running setup.py bdist_wheel for capstone ... done
  Stored in directory: /root/.cache/pip/wheels/7c/d1/d0/db6e2c5ef1063aabb9de2dd8b92b4c27ee6f9fd213240099b8
Successfully built capstone
Installing collected packages: capstone
Successfully installed capstone-3.0.4

$ find /usr/lib/ -name "libcapstone.so"
/usr/lib/python3.5/site-packages/usr/lib/python3.5/site-packages/capstone/libcapstone.so
```

So the path `SITE_PACKAGES` in the `data_files` specification of the
setup.py file was interpreted relative to the python site-packages
directory. The fix for this is simple: use `/capstone` instead of an
absolute path for `SITE_PACKAGES`.
2016-10-03 10:50:08 +08:00
..
java Merge pull request #766 from akihikodaki/next_test 2016-09-04 15:36:53 +08:00
ocaml ocaml: recover test_basic.ml 2016-09-04 10:13:57 +08:00
python python-bindings: fix setup.py for wheel installation 2016-10-03 10:50:08 +08:00
const_generator.py Merge branch 'm68k' into next 2015-10-06 21:54:43 +08:00
Makefile This adds M68K support to Capstone 2015-10-02 20:47:00 +02:00
README some fixes for bindings/README 2015-04-17 11:13:18 +08:00

This directory contains bindings & test code for Python, Java & OCaml.
See <language>/README for how to compile & install each binding.

More bindings created & maintained by the community are available as followings.

- Gapstone: Go binding (by Ben Nagy).

	https://github.com/bnagy/gapstone

- Crabstone: Ruby binding (by Ben Nagy).

	https://github.com/bnagy/crabstone

- Capstone-Vala: Vala binding (by Pancake).

	https://github.com/radare/capstone-vala

- Node-Capstone: NodeJS binding (by Jason Oster).

	https://github.com/parasyte/node-capstone

- CCcapstone: C++ binding (by Peter Hlavaty).

	https://github.com/zer0mem/cccapstone

- LuaCapstone: Lua binding (by Antonio Davide).

	https://github.com/Dax89/LuaCapstone

- Capstone-RS: Rust binding (by Richo Healey).

	https://github.com/richo/capstone-rs

- Capstone.NET: .NET framework binding (by Ahmed Garhy).

	https://github.com/9ee1/Capstone.NET

- C# binding (by Matt Graeber). Note: this is only for Capstone v2.0.

	https://github.com/mattifestation/capstone