1 |
commit: 4aeba69bce7a023f4c6756a1c73c934189de546e |
2 |
Author: Rick Farina <zerochaos <AT> gentoo <DOT> org> |
3 |
AuthorDate: Thu Sep 29 13:52:39 2022 +0000 |
4 |
Commit: Rick Farina <zerochaos <AT> gentoo <DOT> org> |
5 |
CommitDate: Thu Sep 29 13:57:42 2022 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=4aeba69b |
7 |
|
8 |
net-libs/libhackrf: bump to 2022.09.1 |
9 |
|
10 |
Fix open bugs |
11 |
|
12 |
Closes: https://bugs.gentoo.org/724906 |
13 |
Closes: https://bugs.gentoo.org/848921 |
14 |
Signed-off-by: Rick Farina <zerochaos <AT> gentoo.org> |
15 |
|
16 |
net-libs/libhackrf/Manifest | 1 + |
17 |
.../files/hackrf-disable-static-2022.09.1.patch | 30 ++++++++++++++++++++++ |
18 |
net-libs/libhackrf/libhackrf-2021.03.1.ebuild | 9 ++++++- |
19 |
...2021.03.1.ebuild => libhackrf-2022.09.1.ebuild} | 16 +++++++++--- |
20 |
net-libs/libhackrf/libhackrf-9999.ebuild | 18 ++++++++++--- |
21 |
5 files changed, 66 insertions(+), 8 deletions(-) |
22 |
|
23 |
diff --git a/net-libs/libhackrf/Manifest b/net-libs/libhackrf/Manifest |
24 |
index d7597c7d3297..7e62402c90df 100644 |
25 |
--- a/net-libs/libhackrf/Manifest |
26 |
+++ b/net-libs/libhackrf/Manifest |
27 |
@@ -1 +1,2 @@ |
28 |
DIST hackrf-2021.03.1.tar.xz 13661964 BLAKE2B 0a00b2d24cc6ac7ca36f66e8f5b3029cfd446a6c5b5427f7d25db6dd191693c1e1c010abd85907813d55c6bd367780c70860b4f7e7f83fb9970d425311893780 SHA512 4a88b877a9f6fee0c8d9496eb265655af4baa678e862ca6147596cd3a1d85dd50315da6531efa54d050847ce5068c4726393b4897d40576888d10a898ad57139 |
29 |
+DIST hackrf-2022.09.1.tar.xz 21534956 BLAKE2B fd1b3469372fdb0558465c84f3645859791af9bd1302f63c63185ce7c47d24779ed0baf47eccbfc8ddb771e9737edb2a37a073fb749377d87f4e67c11eb6ef76 SHA512 c3b8b6f18cb80e3506c09dc71f2c01c127ad6d88ed028be3b659953cf7bb1e36b9dba83b4bb04c916bd7c2b66faeae1e602c53368e1e56454d6fe831961e01ee |
30 |
|
31 |
diff --git a/net-libs/libhackrf/files/hackrf-disable-static-2022.09.1.patch b/net-libs/libhackrf/files/hackrf-disable-static-2022.09.1.patch |
32 |
new file mode 100644 |
33 |
index 000000000000..f7e9fa39cc5e |
34 |
--- /dev/null |
35 |
+++ b/net-libs/libhackrf/files/hackrf-disable-static-2022.09.1.patch |
36 |
@@ -0,0 +1,30 @@ |
37 |
+diff -Naur libhackrf-orig/src/CMakeLists.txt libhackrf/src/CMakeLists.txt |
38 |
+--- libhackrf-orig/src/CMakeLists.txt 2022-09-29 09:47:10.899630179 -0400 |
39 |
++++ libhackrf/src/CMakeLists.txt 2022-09-29 09:47:30.835629516 -0400 |
40 |
+@@ -31,15 +31,11 @@ |
41 |
+ set_target_properties(hackrf PROPERTIES VERSION ${MAJOR_VERSION}.${MINOR_VERSION}.0 SOVERSION 0) |
42 |
+ |
43 |
+ # Static library |
44 |
+-add_library(hackrf-static STATIC ${c_sources}) |
45 |
+ if(MSVC) |
46 |
+ set_target_properties(hackrf-static PROPERTIES OUTPUT_NAME "hackrf_static") |
47 |
+-else() |
48 |
+- set_target_properties(hackrf-static PROPERTIES OUTPUT_NAME "hackrf") |
49 |
+ endif() |
50 |
+ |
51 |
+ set_target_properties(hackrf PROPERTIES CLEAN_DIRECT_OUTPUT 1) |
52 |
+-set_target_properties(hackrf-static PROPERTIES CLEAN_DIRECT_OUTPUT 1) |
53 |
+ |
54 |
+ # Dependencies |
55 |
+ target_link_libraries(hackrf ${LIBUSB_LIBRARIES} ${CMAKE_THREAD_LIBS_INIT}) |
56 |
+@@ -55,10 +51,6 @@ |
57 |
+ LIBRARY DESTINATION lib${LIB_SUFFIX} |
58 |
+ COMPONENT sharedlibs |
59 |
+ ) |
60 |
+- install(TARGETS hackrf-static |
61 |
+- ARCHIVE DESTINATION lib${LIB_SUFFIX} |
62 |
+- COMPONENT staticlibs |
63 |
+- ) |
64 |
+ install(FILES ${c_headers} |
65 |
+ DESTINATION include/${PROJECT_NAME} |
66 |
+ COMPONENT headers |
67 |
|
68 |
diff --git a/net-libs/libhackrf/libhackrf-2021.03.1.ebuild b/net-libs/libhackrf/libhackrf-2021.03.1.ebuild |
69 |
index 8021c6bcf616..764d01a827d6 100644 |
70 |
--- a/net-libs/libhackrf/libhackrf-2021.03.1.ebuild |
71 |
+++ b/net-libs/libhackrf/libhackrf-2021.03.1.ebuild |
72 |
@@ -40,5 +40,12 @@ src_configure() { |
73 |
} |
74 |
|
75 |
pkg_postinst() { |
76 |
- use udev && einfo "Users in the usb group can use hackrf." |
77 |
+ if use udev; then |
78 |
+ einfo "Users in the usb group can use hackrf." |
79 |
+ udev_reload |
80 |
+ fi |
81 |
+} |
82 |
+ |
83 |
+pkg_postrm() { |
84 |
+ udev_reload |
85 |
} |
86 |
|
87 |
diff --git a/net-libs/libhackrf/libhackrf-2021.03.1.ebuild b/net-libs/libhackrf/libhackrf-2022.09.1.ebuild |
88 |
similarity index 76% |
89 |
copy from net-libs/libhackrf/libhackrf-2021.03.1.ebuild |
90 |
copy to net-libs/libhackrf/libhackrf-2022.09.1.ebuild |
91 |
index 8021c6bcf616..586e9f4bd1ec 100644 |
92 |
--- a/net-libs/libhackrf/libhackrf-2021.03.1.ebuild |
93 |
+++ b/net-libs/libhackrf/libhackrf-2022.09.1.ebuild |
94 |
@@ -1,7 +1,7 @@ |
95 |
# Copyright 1999-2022 Gentoo Authors |
96 |
# Distributed under the terms of the GNU General Public License v2 |
97 |
|
98 |
-EAPI=7 |
99 |
+EAPI=8 |
100 |
|
101 |
inherit cmake udev |
102 |
|
103 |
@@ -16,7 +16,7 @@ if [[ ${PV} == "9999" ]] ; then |
104 |
else |
105 |
S="${WORKDIR}/hackrf-${PV}/host/libhackrf" |
106 |
SRC_URI="https://github.com/greatscottgadgets/hackrf/releases/download/v${PV}/hackrf-${PV}.tar.xz" |
107 |
- KEYWORDS="amd64 ~arm ~ppc ~riscv x86" |
108 |
+ KEYWORDS="~amd64 ~arm ~ppc ~riscv ~x86" |
109 |
fi |
110 |
|
111 |
LICENSE="BSD" |
112 |
@@ -26,6 +26,9 @@ IUSE="+udev" |
113 |
DEPEND="virtual/libusb:1" |
114 |
RDEPEND="${DEPEND}" |
115 |
|
116 |
+# https://github.com/greatscottgadgets/hackrf/issues/1193 |
117 |
+PATCHES=( "${FILESDIR}/hackrf-disable-static-${PV}.patch" ) |
118 |
+ |
119 |
src_configure() { |
120 |
local mycmakeargs=( |
121 |
-DINSTALL_UDEV_RULES="$(usex udev)" |
122 |
@@ -40,5 +43,12 @@ src_configure() { |
123 |
} |
124 |
|
125 |
pkg_postinst() { |
126 |
- use udev && einfo "Users in the usb group can use hackrf." |
127 |
+ if use udev; then |
128 |
+ einfo "Users in the usb group can use hackrf." |
129 |
+ udev_reload |
130 |
+ fi |
131 |
+} |
132 |
+ |
133 |
+pkg_postrm() { |
134 |
+ udev_reload |
135 |
} |
136 |
|
137 |
diff --git a/net-libs/libhackrf/libhackrf-9999.ebuild b/net-libs/libhackrf/libhackrf-9999.ebuild |
138 |
index aacd79049ae5..586e9f4bd1ec 100644 |
139 |
--- a/net-libs/libhackrf/libhackrf-9999.ebuild |
140 |
+++ b/net-libs/libhackrf/libhackrf-9999.ebuild |
141 |
@@ -1,7 +1,7 @@ |
142 |
-# Copyright 1999-2021 Gentoo Authors |
143 |
+# Copyright 1999-2022 Gentoo Authors |
144 |
# Distributed under the terms of the GNU General Public License v2 |
145 |
|
146 |
-EAPI=7 |
147 |
+EAPI=8 |
148 |
|
149 |
inherit cmake udev |
150 |
|
151 |
@@ -16,7 +16,7 @@ if [[ ${PV} == "9999" ]] ; then |
152 |
else |
153 |
S="${WORKDIR}/hackrf-${PV}/host/libhackrf" |
154 |
SRC_URI="https://github.com/greatscottgadgets/hackrf/releases/download/v${PV}/hackrf-${PV}.tar.xz" |
155 |
- KEYWORDS="~amd64 ~arm ~ppc ~x86" |
156 |
+ KEYWORDS="~amd64 ~arm ~ppc ~riscv ~x86" |
157 |
fi |
158 |
|
159 |
LICENSE="BSD" |
160 |
@@ -26,6 +26,9 @@ IUSE="+udev" |
161 |
DEPEND="virtual/libusb:1" |
162 |
RDEPEND="${DEPEND}" |
163 |
|
164 |
+# https://github.com/greatscottgadgets/hackrf/issues/1193 |
165 |
+PATCHES=( "${FILESDIR}/hackrf-disable-static-${PV}.patch" ) |
166 |
+ |
167 |
src_configure() { |
168 |
local mycmakeargs=( |
169 |
-DINSTALL_UDEV_RULES="$(usex udev)" |
170 |
@@ -40,5 +43,12 @@ src_configure() { |
171 |
} |
172 |
|
173 |
pkg_postinst() { |
174 |
- use udev && einfo "Users in the usb group can use hackrf." |
175 |
+ if use udev; then |
176 |
+ einfo "Users in the usb group can use hackrf." |
177 |
+ udev_reload |
178 |
+ fi |
179 |
+} |
180 |
+ |
181 |
+pkg_postrm() { |
182 |
+ udev_reload |
183 |
} |