1 |
commit: fa8c6321e393235a14583a0a7e1b85fade2d076d |
2 |
Author: Arthur Zamarin <arthurzam <AT> gentoo <DOT> org> |
3 |
AuthorDate: Fri Aug 5 06:09:51 2022 +0000 |
4 |
Commit: Arthur Zamarin <arthurzam <AT> gentoo <DOT> org> |
5 |
CommitDate: Fri Aug 5 06:30:56 2022 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=fa8c6321 |
7 |
|
8 |
dev-python/leechcorepyc: add 2.12.0 |
9 |
|
10 |
Signed-off-by: Arthur Zamarin <arthurzam <AT> gentoo.org> |
11 |
|
12 |
dev-python/leechcorepyc/Manifest | 1 + |
13 |
.../files/leechcorepyc-2.12.0-respect-CC.patch | 41 ++++++++++++++++++++++ |
14 |
dev-python/leechcorepyc/leechcorepyc-2.12.0.ebuild | 34 ++++++++++++++++++ |
15 |
3 files changed, 76 insertions(+) |
16 |
|
17 |
diff --git a/dev-python/leechcorepyc/Manifest b/dev-python/leechcorepyc/Manifest |
18 |
index 996d1eee59a1..cacb30a5f45e 100644 |
19 |
--- a/dev-python/leechcorepyc/Manifest |
20 |
+++ b/dev-python/leechcorepyc/Manifest |
21 |
@@ -1 +1,2 @@ |
22 |
DIST leechcorepyc-2.10.2.tar.gz 119984 BLAKE2B e9bba5dd548ce5ce8c3a367d1ae21b66fca796e5614fe3cc86cdc16ddd1b589261534b551992a3964542f6d61fb6fb64bc9e2e03f8775486761107a4ffbeb958 SHA512 16048f3494452ff75fa946d65dfa36a7b0dd30c132db10c01fdc1dbe0de051c69856bf7b9830d68ee17ec1e4ce5fb29ba17a14f0facb928b81e4094ac5009716 |
23 |
+DIST leechcorepyc-2.12.0.tar.gz 120774 BLAKE2B 7e7de1388acb73bb391ae5451c5b4f3f4b6c4891a1c420f2d662c930a37d4db702731c70861d8467b82b4e29dc1c22560215b1f8fe9ec8f7675fe69b63844ae3 SHA512 bb8c4c76ab8ec610f8c879c75dbed36006b16a165c20ac17ccd8a8978e1e0b4f5543c8aa8b054ea4cf58d38e908e8b92ba13898697c2465776add1bc964762b1 |
24 |
|
25 |
diff --git a/dev-python/leechcorepyc/files/leechcorepyc-2.12.0-respect-CC.patch b/dev-python/leechcorepyc/files/leechcorepyc-2.12.0-respect-CC.patch |
26 |
new file mode 100644 |
27 |
index 000000000000..6bf48b0c6bcd |
28 |
--- /dev/null |
29 |
+++ b/dev-python/leechcorepyc/files/leechcorepyc-2.12.0-respect-CC.patch |
30 |
@@ -0,0 +1,41 @@ |
31 |
+--- a/leechcore/Makefile |
32 |
++++ b/leechcore/Makefile |
33 |
+@@ -1,7 +1,8 @@ |
34 |
+-CC=gcc |
35 |
+-CFLAGS += -I. -D LINUX -D _GNU_SOURCE -shared -fPIC -fvisibility=hidden -pthread `pkg-config libusb-1.0 --libs --cflags` |
36 |
++CC?=gcc |
37 |
++PKG_CONFIG ?= pkg-config |
38 |
++CFLAGS += -I. -D LINUX -D _GNU_SOURCE -shared -fPIC -fvisibility=hidden -pthread `$(PKG_CONFIG) libusb-1.0 --libs --cflags` |
39 |
+ #CFLAGS += -g -O0 -Wextra -Wno-unused-parameter |
40 |
+-CFLAGS += -fPIE -fPIC -pie -fstack-protector -D_FORTIFY_SOURCE=2 -O1 -Wl,-z,noexecstack |
41 |
++CFLAGS += -fPIE -fPIC -pie -D_FORTIFY_SOURCE=2 -Wl,-z,noexecstack |
42 |
+ CFLAGS += -Wall -Wno-unused-result -Wno-unused-variable -Wno-unused-value -Wno-pointer-to-int-cast -Wno-int-to-pointer-cast |
43 |
+ LDFLAGS += -g -ldl -shared |
44 |
+ DEPS = leechcore.h |
45 |
+--- a/leechcore_device_rawtcp/Makefile |
46 |
++++ b/leechcore_device_rawtcp/Makefile |
47 |
+@@ -1,4 +1,4 @@ |
48 |
+-CC=gcc |
49 |
++CC?=gcc |
50 |
+ CFLAGS += -I. -I../includes -D LINUX -shared -fPIC -fvisibility=hidden |
51 |
+ LDFLAGS += -g -shared |
52 |
+ DEPS = |
53 |
+--- a/leechcore_device_sp605tcp/Makefile |
54 |
++++ b/leechcore_device_sp605tcp/Makefile |
55 |
+@@ -1,4 +1,4 @@ |
56 |
+-CC=gcc |
57 |
++CC?=gcc |
58 |
+ CFLAGS += -I. -I../includes -D LINUX -shared -fPIC -fvisibility=hidden |
59 |
+ LDFLAGS += -g -shared |
60 |
+ DEPS = |
61 |
+--- a/leechcore_ft601_driver_linux/Makefile |
62 |
++++ b/leechcore_ft601_driver_linux/Makefile |
63 |
+@@ -1,5 +1,6 @@ |
64 |
+-CC=gcc |
65 |
+-CFLAGS += -I. -D LINUX -shared -fPIC -fvisibility=hidden `pkg-config libusb-1.0 --libs --cflags` |
66 |
++CC?=gcc |
67 |
++PKG_CONFIG ?= pkg-config |
68 |
++CFLAGS += -I. -D LINUX -shared -fPIC -fvisibility=hidden `$(PKG_CONFIG) libusb-1.0 --libs --cflags` |
69 |
+ LDFLAGS += -g -shared |
70 |
+ DEPS = leechcore_ft601_driver_linux.h |
71 |
+ OBJ = fpga_libusb.o leechcore_ft601_driver_linux.o |
72 |
|
73 |
diff --git a/dev-python/leechcorepyc/leechcorepyc-2.12.0.ebuild b/dev-python/leechcorepyc/leechcorepyc-2.12.0.ebuild |
74 |
new file mode 100644 |
75 |
index 000000000000..80330d420909 |
76 |
--- /dev/null |
77 |
+++ b/dev-python/leechcorepyc/leechcorepyc-2.12.0.ebuild |
78 |
@@ -0,0 +1,34 @@ |
79 |
+# Copyright 1999-2022 Gentoo Authors |
80 |
+# Distributed under the terms of the GNU General Public License v2 |
81 |
+ |
82 |
+EAPI=8 |
83 |
+ |
84 |
+DISTUTILS_USE_PEP517=setuptools |
85 |
+PYTHON_COMPAT=( python3_{8..10} ) |
86 |
+ |
87 |
+inherit distutils-r1 toolchain-funcs |
88 |
+ |
89 |
+DESCRIPTION="Python binding for LeechCore Physical Memory Acquisition Library" |
90 |
+HOMEPAGE="https://github.com/ufrisk/LeechCore" |
91 |
+SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz" |
92 |
+ |
93 |
+LICENSE="GPL-3" |
94 |
+SLOT="0" |
95 |
+KEYWORDS="~amd64 ~x86" |
96 |
+ |
97 |
+# leechcorepyc ships with a bundled version of the LeechCore library. So we |
98 |
+# don't depend on the library here. But we must be aware this module doesn't |
99 |
+# use the system library. |
100 |
+DEPEND="virtual/libusb:=" |
101 |
+RDEPEND="${DEPEND}" |
102 |
+BDEPEND="virtual/pkgconfig" |
103 |
+ |
104 |
+PATCHES=( |
105 |
+ "${FILESDIR}"/${PN}-2.12.0-respect-CC.patch |
106 |
+) |
107 |
+ |
108 |
+src_configure() { |
109 |
+ tc-export CC |
110 |
+ |
111 |
+ distutils-r1_src_configure |
112 |
+} |