1 |
commit: ffcb70d5dc733edf8419c1435a0b5f8c03a838f5 |
2 |
Author: Robin H. Johnson <robbat2 <AT> gentoo <DOT> org> |
3 |
AuthorDate: Thu Oct 3 05:13:17 2019 +0000 |
4 |
Commit: Robin H. Johnson <robbat2 <AT> gentoo <DOT> org> |
5 |
CommitDate: Fri Oct 4 18:59:32 2019 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=ffcb70d5 |
7 |
|
8 |
sci-geosciences/gpsd: bump, partial cleanups |
9 |
|
10 |
Bump for security vulnerability, start cleanups. |
11 |
|
12 |
Fixes: https://bugs.gentoo.org/673372 |
13 |
Fixes: https://bugs.gentoo.org/673382 |
14 |
Fixes: https://bugs.gentoo.org/678474 |
15 |
Package-Manager: Portage-2.3.76, Repoman-2.3.17 |
16 |
Signed-off-by: Robin H. Johnson <robbat2 <AT> gentoo.org> |
17 |
|
18 |
sci-geosciences/gpsd/Manifest | 2 + |
19 |
.../gpsd/files/gpsd-3.18.1-do_not_rm_library.patch | 11 ++ |
20 |
.../gpsd/files/gpsd-3.19-do_not_rm_library.patch | 11 ++ |
21 |
sci-geosciences/gpsd/gpsd-3.18.1.ebuild | 192 +++++++++++++++++++++ |
22 |
sci-geosciences/gpsd/gpsd-3.19.ebuild | 192 +++++++++++++++++++++ |
23 |
5 files changed, 408 insertions(+) |
24 |
|
25 |
diff --git a/sci-geosciences/gpsd/Manifest b/sci-geosciences/gpsd/Manifest |
26 |
index 3352663f8ca..02f03645cf4 100644 |
27 |
--- a/sci-geosciences/gpsd/Manifest |
28 |
+++ b/sci-geosciences/gpsd/Manifest |
29 |
@@ -1 +1,3 @@ |
30 |
DIST gpsd-3.17.tar.gz 8755304 BLAKE2B d1f82b5734fd90fe903a6f2fe8835fe8292fe3e729306e7abe4054821971fece4c23f382c08a233503f07ad66b7b3a02a52a000e55c08491bf254ab6e99378b5 SHA512 71085053f600730e0f2de269c59ce0a17ae106ef01403f02d78418b267c6adb9818d541fba59eb23bf71cdb67c5442c82b4948d262ef7e74bb993dcae677a1b1 |
31 |
+DIST gpsd-3.18.1.tar.gz 9031595 BLAKE2B 170863740c7281ea111c3f4db2dfeb67f4366da7e9e8d2f7f3bbddacbc9d2083558379b1fe60c9293c31a6428288d205aba565694fedde6f1dfe67999a6782c6 SHA512 b381b177fcd29089a61aa11f5df2c67473720a6bbc5590ca1c4fda627331c407de01c62caceeddae780626b9a02392e9a770d52a143357e1babdcc2fbff0ed38 |
32 |
+DIST gpsd-3.19.tar.gz 10581777 BLAKE2B 0801919c968b8027c357047dabdc8587e1d5950cb0d80f89d6d62678a11b3dfc76a6a89ae59123680dac3188a695d0c37618d3f83280f5e584e10c1fa9a5dc03 SHA512 c9f9a9ff65759f852771ec4cf97ab15343c9176a149dd5ea6c2e2dc18b47aa7c7bf9ff1f2e8523121564d33a34ae6aa08169c5454847b4fe7848e616fd20a814 |
33 |
|
34 |
diff --git a/sci-geosciences/gpsd/files/gpsd-3.18.1-do_not_rm_library.patch b/sci-geosciences/gpsd/files/gpsd-3.18.1-do_not_rm_library.patch |
35 |
new file mode 100644 |
36 |
index 00000000000..0500f385d79 |
37 |
--- /dev/null |
38 |
+++ b/sci-geosciences/gpsd/files/gpsd-3.18.1-do_not_rm_library.patch |
39 |
@@ -0,0 +1,11 @@ |
40 |
+--- gpsd-3.18.1/SConstruct.orig 2018-10-19 12:45:40.000000000 -0700 |
41 |
++++ gpsd-3.18.1/SConstruct 2019-10-02 11:49:00.848685223 -0700 |
42 |
+@@ -1796,8 +1796,6 @@ # third-party client programs should not |
43 |
+ binaryinstall.append(env.Install(installdir('bindir'), bin_binaries)) |
44 |
+ binaryinstall.append(LibraryInstall(env, installdir('libdir'), compiled_gpslib, |
45 |
+ libgps_version)) |
46 |
+-# Work around a minor bug in InstallSharedLib() link handling |
47 |
+-env.AddPreAction(binaryinstall, 'rm -f %s/libgps.*' % (installdir('libdir'), )) |
48 |
+ |
49 |
+ if qt_env: |
50 |
+ binaryinstall.append(LibraryInstall(qt_env, installdir('libdir'), |
51 |
|
52 |
diff --git a/sci-geosciences/gpsd/files/gpsd-3.19-do_not_rm_library.patch b/sci-geosciences/gpsd/files/gpsd-3.19-do_not_rm_library.patch |
53 |
new file mode 100644 |
54 |
index 00000000000..8008dd54fe9 |
55 |
--- /dev/null |
56 |
+++ b/sci-geosciences/gpsd/files/gpsd-3.19-do_not_rm_library.patch |
57 |
@@ -0,0 +1,11 @@ |
58 |
+--- gpsd-3.19/SConstruct.orig 2019-07-01 19:00:17.000000000 -0700 |
59 |
++++ gpsd-3.19/SConstruct 2019-10-02 11:49:06.080655901 -0700 |
60 |
+@@ -1980,8 +1980,6 @@ # third-party client programs should not |
61 |
+ binaryinstall.append(env.Install(installdir('bindir'), bin_binaries)) |
62 |
+ binaryinstall.append(LibraryInstall(env, installdir('libdir'), libgps_shared, |
63 |
+ libgps_version)) |
64 |
+-# Work around a minor bug in InstallSharedLib() link handling |
65 |
+-env.AddPreAction(binaryinstall, 'rm -f %s/libgps.*' % (installdir('libdir'), )) |
66 |
+ |
67 |
+ if qt_env: |
68 |
+ binaryinstall.append(LibraryInstall(qt_env, installdir('libdir'), |
69 |
|
70 |
diff --git a/sci-geosciences/gpsd/gpsd-3.18.1.ebuild b/sci-geosciences/gpsd/gpsd-3.18.1.ebuild |
71 |
new file mode 100644 |
72 |
index 00000000000..6cba45913e0 |
73 |
--- /dev/null |
74 |
+++ b/sci-geosciences/gpsd/gpsd-3.18.1.ebuild |
75 |
@@ -0,0 +1,192 @@ |
76 |
+# Copyright 1999-2019 Gentoo Authors |
77 |
+# Distributed under the terms of the GNU General Public License v2 |
78 |
+ |
79 |
+EAPI=5 |
80 |
+ |
81 |
+DISTUTILS_OPTIONAL=1 |
82 |
+PYTHON_COMPAT=( python2_7 python3_5 python3_6 ) |
83 |
+SCONS_MIN_VERSION="2.3.0" |
84 |
+ |
85 |
+inherit eutils udev user multilib distutils-r1 scons-utils toolchain-funcs |
86 |
+ |
87 |
+if [[ ${PV} == "9999" ]] ; then |
88 |
+ EGIT_REPO_URI="https://gitlab.com/gpsd/gpsd.git" |
89 |
+ inherit git-r3 |
90 |
+else |
91 |
+ SRC_URI="mirror://nongnu/${PN}/${P}.tar.gz" |
92 |
+ KEYWORDS="~amd64 ~arm ~ppc ~ppc64 ~sparc ~x86" |
93 |
+fi |
94 |
+ |
95 |
+DESCRIPTION="GPS daemon and library for USB/serial GPS devices and GPS/mapping clients" |
96 |
+HOMEPAGE="https://gpsd.gitlab.io/gpsd/" |
97 |
+ |
98 |
+LICENSE="BSD" |
99 |
+SLOT="0/24" |
100 |
+ |
101 |
+GPSD_PROTOCOLS=( |
102 |
+ aivdm ashtech earthmate evermore fury fv18 garmin garmintxt geostar |
103 |
+ gpsclock greis isync itrax mtk3301 navcom nmea0183 nmea2000 ntrip |
104 |
+ oceanserver oncore passthrough rtcm104v2 rtcm104v3 sirf skytraq |
105 |
+ superstar2 tnt tripmate tsip ublox |
106 |
+) |
107 |
+IUSE_GPSD_PROTOCOLS=${GPSD_PROTOCOLS[@]/#/+gpsd_protocols_} |
108 |
+IUSE="${IUSE_GPSD_PROTOCOLS} bluetooth +cxx dbus debug ipv6 latency-timing ncurses ntp python qt5 +shm +sockets static test udev usb X" |
109 |
+REQUIRED_USE="X? ( python ) |
110 |
+ gpsd_protocols_nmea2000? ( gpsd_protocols_aivdm ) |
111 |
+ gpsd_protocols_isync? ( gpsd_protocols_ublox ) |
112 |
+ gpsd_protocols_ublox? ( python ) |
113 |
+ gpsd_protocols_greis? ( python ) |
114 |
+ python? ( ${PYTHON_REQUIRED_USE} ) |
115 |
+ qt5? ( cxx )" |
116 |
+RESTRICT="!test? ( test )" |
117 |
+ |
118 |
+RDEPEND=" |
119 |
+ >=net-misc/pps-tools-0.0.20120407 |
120 |
+ bluetooth? ( net-wireless/bluez ) |
121 |
+ dbus? ( |
122 |
+ sys-apps/dbus |
123 |
+ dev-libs/dbus-glib |
124 |
+ ) |
125 |
+ ncurses? ( sys-libs/ncurses:= ) |
126 |
+ ntp? ( || ( |
127 |
+ net-misc/ntp |
128 |
+ net-misc/ntpsec |
129 |
+ net-misc/chrony |
130 |
+ ) ) |
131 |
+ qt5? ( |
132 |
+ dev-qt/qtcore:5 |
133 |
+ dev-qt/qtnetwork:5 |
134 |
+ ) |
135 |
+ python? ( ${PYTHON_DEPS} ) |
136 |
+ gpsd_protocols_ublox? ( dev-python/pyserial ) |
137 |
+ gpsd_protocols_greis? ( dev-python/pyserial ) |
138 |
+ usb? ( virtual/libusb:1 ) |
139 |
+ X? ( dev-python/pygobject:3[cairo,${PYTHON_USEDEP}] )" |
140 |
+DEPEND="${RDEPEND} |
141 |
+ virtual/pkgconfig |
142 |
+ test? ( sys-devel/bc )" |
143 |
+ |
144 |
+# xml packages are for man page generation |
145 |
+if [[ ${PV} == *9999* ]] ; then |
146 |
+ DEPEND+=" |
147 |
+ app-text/xmlto |
148 |
+ =app-text/docbook-xml-dtd-4.1*" |
149 |
+fi |
150 |
+ |
151 |
+src_prepare() { |
152 |
+ # Make sure our list matches the source. |
153 |
+ local src_protocols=$(echo $( |
154 |
+ sed -n '/# GPS protocols/,/# Time service/{s:#.*::;s:[(",]::g;p}' "${S}"/SConstruct | awk '{print $1}' | LC_ALL=C sort |
155 |
+ ) ) |
156 |
+ if [[ ${src_protocols} != ${GPSD_PROTOCOLS[*]} ]] ; then |
157 |
+ eerror "Detected protocols: ${src_protocols}" |
158 |
+ eerror "Ebuild protocols: ${GPSD_PROTOCOLS[*]}" |
159 |
+ die "please sync ebuild & source" |
160 |
+ fi |
161 |
+ |
162 |
+ epatch "${FILESDIR}"/${P}-do_not_rm_library.patch |
163 |
+ # Merged upstream |
164 |
+ #epatch "${FILESDIR}"/${P}-scons-print.patch |
165 |
+ #epatch "${FILESDIR}"/${P}-scons-py3.patch |
166 |
+ |
167 |
+ # Avoid useless -L paths to the install dir |
168 |
+ sed -i \ |
169 |
+ -e 's:\<STAGING_PREFIX\>:SYSROOT:g' \ |
170 |
+ SConstruct || die |
171 |
+ |
172 |
+ default |
173 |
+ |
174 |
+ use python && distutils-r1_src_prepare |
175 |
+} |
176 |
+ |
177 |
+python_prepare_all() { |
178 |
+ python_setup |
179 |
+ python_export |
180 |
+ |
181 |
+ # Extract python info out of SConstruct so we can use saner distribute |
182 |
+ pyvar() { sed -n "/^ *$1 *=/s:.*= *::p" SConstruct ; } |
183 |
+ local pybins=$(pyvar python_progs | tail -1) |
184 |
+ # Handle conditional tools manually. #666734 |
185 |
+ use X && pybins+="+ ['xgps', 'xgpsspeed']" |
186 |
+ use gpsd_protocols_ublox && pybins+="+ ['ubxtool']" |
187 |
+ use gpsd_protocols_greis && pybins+="+ ['zerk']" |
188 |
+ local pysrcs=$(sed -n '/^ *python_extensions = {/,/}/{s:^ *::;s:os[.]sep:"/":g;p}' SConstruct) |
189 |
+ local packet=$("${PYTHON}" -c "${pysrcs}; print(python_extensions['gps/packet'])") |
190 |
+ local client=$("${PYTHON}" -c "${pysrcs}; print(python_extensions['gps/clienthelpers'])") |
191 |
+ sed \ |
192 |
+ -e "s|@VERSION@|$(pyvar gpsd_version)|" \ |
193 |
+ -e "s|@URL@|$(pyvar website)|" \ |
194 |
+ -e "s|@EMAIL@|$(pyvar devmail)|" \ |
195 |
+ -e "s|@SCRIPTS@|${pybins}|" \ |
196 |
+ -e "s|@GPS_PACKET_SOURCES@|${packet}|" \ |
197 |
+ -e "s|@GPS_CLIENT_SOURCES@|${client}|" \ |
198 |
+ -e "s|@SCRIPTS@|${pybins}|" \ |
199 |
+ "${FILESDIR}"/${PN}-3.3-setup.py > setup.py || die |
200 |
+ distutils-r1_python_prepare_all |
201 |
+} |
202 |
+ |
203 |
+src_configure() { |
204 |
+ myesconsargs=( |
205 |
+ prefix="${EPREFIX}/usr" |
206 |
+ libdir="\$prefix/$(get_libdir)" |
207 |
+ udevdir="$(get_udevdir)" |
208 |
+ chrpath=False |
209 |
+ gpsd_user=gpsd |
210 |
+ gpsd_group=uucp |
211 |
+ nostrip=True |
212 |
+ manbuild=False |
213 |
+ shared=$(usex !static True False) |
214 |
+ $(use_scons bluetooth bluez) |
215 |
+ $(use_scons cxx libgpsmm) |
216 |
+ $(use_scons debug clientdebug) |
217 |
+ $(use_scons dbus dbus_export) |
218 |
+ $(use_scons ipv6) |
219 |
+ $(use_scons latency-timing timing) |
220 |
+ $(use_scons ncurses) |
221 |
+ $(use_scons ntp ntpshm) |
222 |
+ $(use_scons ntp pps) |
223 |
+ $(use_scons python) |
224 |
+ $(use_scons qt5 qt) |
225 |
+ $(use_scons shm shm_export) |
226 |
+ $(use_scons sockets socket_export) |
227 |
+ $(use_scons usb) |
228 |
+ ) |
229 |
+ |
230 |
+ use X && myesconsargs+=( xgps=1 xgpsspeed=1 ) |
231 |
+ use qt5 && myesconsargs+=( qt_versioned=5 ) |
232 |
+ |
233 |
+ # enable specified protocols |
234 |
+ local protocol |
235 |
+ for protocol in ${GPSD_PROTOCOLS[@]} ; do |
236 |
+ myesconsargs+=( $(use_scons gpsd_protocols_${protocol} ${protocol}) ) |
237 |
+ done |
238 |
+} |
239 |
+ |
240 |
+src_compile() { |
241 |
+ export CHRPATH= |
242 |
+ tc-export CC CXX PKG_CONFIG |
243 |
+ export SHLINKFLAGS=${LDFLAGS} LINKFLAGS=${LDFLAGS} |
244 |
+ escons |
245 |
+ |
246 |
+ use python && distutils-r1_src_compile |
247 |
+} |
248 |
+ |
249 |
+src_install() { |
250 |
+ DESTDIR="${D}" escons install $(usex udev udev-install "") |
251 |
+ |
252 |
+ newconfd "${FILESDIR}"/gpsd.conf-2 gpsd |
253 |
+ newinitd "${FILESDIR}"/gpsd.init-2 gpsd |
254 |
+ |
255 |
+ # Cleanup bad alt copy due to Scons |
256 |
+ rm -rf "${D}"/usr/local/$(get_libdir)/python*/site-packages/gps* |
257 |
+ find "${D}"/usr/local/ -type d -delete |
258 |
+ # Install correct multi-python copy |
259 |
+ use python && distutils-r1_src_install |
260 |
+ |
261 |
+} |
262 |
+ |
263 |
+pkg_preinst() { |
264 |
+ # Run the gpsd daemon as gpsd and group uucp; create it here |
265 |
+ # as it doesn't seem to be needed during compile/install ... |
266 |
+ enewuser gpsd -1 -1 -1 "uucp" |
267 |
+} |
268 |
|
269 |
diff --git a/sci-geosciences/gpsd/gpsd-3.19.ebuild b/sci-geosciences/gpsd/gpsd-3.19.ebuild |
270 |
new file mode 100644 |
271 |
index 00000000000..6cba45913e0 |
272 |
--- /dev/null |
273 |
+++ b/sci-geosciences/gpsd/gpsd-3.19.ebuild |
274 |
@@ -0,0 +1,192 @@ |
275 |
+# Copyright 1999-2019 Gentoo Authors |
276 |
+# Distributed under the terms of the GNU General Public License v2 |
277 |
+ |
278 |
+EAPI=5 |
279 |
+ |
280 |
+DISTUTILS_OPTIONAL=1 |
281 |
+PYTHON_COMPAT=( python2_7 python3_5 python3_6 ) |
282 |
+SCONS_MIN_VERSION="2.3.0" |
283 |
+ |
284 |
+inherit eutils udev user multilib distutils-r1 scons-utils toolchain-funcs |
285 |
+ |
286 |
+if [[ ${PV} == "9999" ]] ; then |
287 |
+ EGIT_REPO_URI="https://gitlab.com/gpsd/gpsd.git" |
288 |
+ inherit git-r3 |
289 |
+else |
290 |
+ SRC_URI="mirror://nongnu/${PN}/${P}.tar.gz" |
291 |
+ KEYWORDS="~amd64 ~arm ~ppc ~ppc64 ~sparc ~x86" |
292 |
+fi |
293 |
+ |
294 |
+DESCRIPTION="GPS daemon and library for USB/serial GPS devices and GPS/mapping clients" |
295 |
+HOMEPAGE="https://gpsd.gitlab.io/gpsd/" |
296 |
+ |
297 |
+LICENSE="BSD" |
298 |
+SLOT="0/24" |
299 |
+ |
300 |
+GPSD_PROTOCOLS=( |
301 |
+ aivdm ashtech earthmate evermore fury fv18 garmin garmintxt geostar |
302 |
+ gpsclock greis isync itrax mtk3301 navcom nmea0183 nmea2000 ntrip |
303 |
+ oceanserver oncore passthrough rtcm104v2 rtcm104v3 sirf skytraq |
304 |
+ superstar2 tnt tripmate tsip ublox |
305 |
+) |
306 |
+IUSE_GPSD_PROTOCOLS=${GPSD_PROTOCOLS[@]/#/+gpsd_protocols_} |
307 |
+IUSE="${IUSE_GPSD_PROTOCOLS} bluetooth +cxx dbus debug ipv6 latency-timing ncurses ntp python qt5 +shm +sockets static test udev usb X" |
308 |
+REQUIRED_USE="X? ( python ) |
309 |
+ gpsd_protocols_nmea2000? ( gpsd_protocols_aivdm ) |
310 |
+ gpsd_protocols_isync? ( gpsd_protocols_ublox ) |
311 |
+ gpsd_protocols_ublox? ( python ) |
312 |
+ gpsd_protocols_greis? ( python ) |
313 |
+ python? ( ${PYTHON_REQUIRED_USE} ) |
314 |
+ qt5? ( cxx )" |
315 |
+RESTRICT="!test? ( test )" |
316 |
+ |
317 |
+RDEPEND=" |
318 |
+ >=net-misc/pps-tools-0.0.20120407 |
319 |
+ bluetooth? ( net-wireless/bluez ) |
320 |
+ dbus? ( |
321 |
+ sys-apps/dbus |
322 |
+ dev-libs/dbus-glib |
323 |
+ ) |
324 |
+ ncurses? ( sys-libs/ncurses:= ) |
325 |
+ ntp? ( || ( |
326 |
+ net-misc/ntp |
327 |
+ net-misc/ntpsec |
328 |
+ net-misc/chrony |
329 |
+ ) ) |
330 |
+ qt5? ( |
331 |
+ dev-qt/qtcore:5 |
332 |
+ dev-qt/qtnetwork:5 |
333 |
+ ) |
334 |
+ python? ( ${PYTHON_DEPS} ) |
335 |
+ gpsd_protocols_ublox? ( dev-python/pyserial ) |
336 |
+ gpsd_protocols_greis? ( dev-python/pyserial ) |
337 |
+ usb? ( virtual/libusb:1 ) |
338 |
+ X? ( dev-python/pygobject:3[cairo,${PYTHON_USEDEP}] )" |
339 |
+DEPEND="${RDEPEND} |
340 |
+ virtual/pkgconfig |
341 |
+ test? ( sys-devel/bc )" |
342 |
+ |
343 |
+# xml packages are for man page generation |
344 |
+if [[ ${PV} == *9999* ]] ; then |
345 |
+ DEPEND+=" |
346 |
+ app-text/xmlto |
347 |
+ =app-text/docbook-xml-dtd-4.1*" |
348 |
+fi |
349 |
+ |
350 |
+src_prepare() { |
351 |
+ # Make sure our list matches the source. |
352 |
+ local src_protocols=$(echo $( |
353 |
+ sed -n '/# GPS protocols/,/# Time service/{s:#.*::;s:[(",]::g;p}' "${S}"/SConstruct | awk '{print $1}' | LC_ALL=C sort |
354 |
+ ) ) |
355 |
+ if [[ ${src_protocols} != ${GPSD_PROTOCOLS[*]} ]] ; then |
356 |
+ eerror "Detected protocols: ${src_protocols}" |
357 |
+ eerror "Ebuild protocols: ${GPSD_PROTOCOLS[*]}" |
358 |
+ die "please sync ebuild & source" |
359 |
+ fi |
360 |
+ |
361 |
+ epatch "${FILESDIR}"/${P}-do_not_rm_library.patch |
362 |
+ # Merged upstream |
363 |
+ #epatch "${FILESDIR}"/${P}-scons-print.patch |
364 |
+ #epatch "${FILESDIR}"/${P}-scons-py3.patch |
365 |
+ |
366 |
+ # Avoid useless -L paths to the install dir |
367 |
+ sed -i \ |
368 |
+ -e 's:\<STAGING_PREFIX\>:SYSROOT:g' \ |
369 |
+ SConstruct || die |
370 |
+ |
371 |
+ default |
372 |
+ |
373 |
+ use python && distutils-r1_src_prepare |
374 |
+} |
375 |
+ |
376 |
+python_prepare_all() { |
377 |
+ python_setup |
378 |
+ python_export |
379 |
+ |
380 |
+ # Extract python info out of SConstruct so we can use saner distribute |
381 |
+ pyvar() { sed -n "/^ *$1 *=/s:.*= *::p" SConstruct ; } |
382 |
+ local pybins=$(pyvar python_progs | tail -1) |
383 |
+ # Handle conditional tools manually. #666734 |
384 |
+ use X && pybins+="+ ['xgps', 'xgpsspeed']" |
385 |
+ use gpsd_protocols_ublox && pybins+="+ ['ubxtool']" |
386 |
+ use gpsd_protocols_greis && pybins+="+ ['zerk']" |
387 |
+ local pysrcs=$(sed -n '/^ *python_extensions = {/,/}/{s:^ *::;s:os[.]sep:"/":g;p}' SConstruct) |
388 |
+ local packet=$("${PYTHON}" -c "${pysrcs}; print(python_extensions['gps/packet'])") |
389 |
+ local client=$("${PYTHON}" -c "${pysrcs}; print(python_extensions['gps/clienthelpers'])") |
390 |
+ sed \ |
391 |
+ -e "s|@VERSION@|$(pyvar gpsd_version)|" \ |
392 |
+ -e "s|@URL@|$(pyvar website)|" \ |
393 |
+ -e "s|@EMAIL@|$(pyvar devmail)|" \ |
394 |
+ -e "s|@SCRIPTS@|${pybins}|" \ |
395 |
+ -e "s|@GPS_PACKET_SOURCES@|${packet}|" \ |
396 |
+ -e "s|@GPS_CLIENT_SOURCES@|${client}|" \ |
397 |
+ -e "s|@SCRIPTS@|${pybins}|" \ |
398 |
+ "${FILESDIR}"/${PN}-3.3-setup.py > setup.py || die |
399 |
+ distutils-r1_python_prepare_all |
400 |
+} |
401 |
+ |
402 |
+src_configure() { |
403 |
+ myesconsargs=( |
404 |
+ prefix="${EPREFIX}/usr" |
405 |
+ libdir="\$prefix/$(get_libdir)" |
406 |
+ udevdir="$(get_udevdir)" |
407 |
+ chrpath=False |
408 |
+ gpsd_user=gpsd |
409 |
+ gpsd_group=uucp |
410 |
+ nostrip=True |
411 |
+ manbuild=False |
412 |
+ shared=$(usex !static True False) |
413 |
+ $(use_scons bluetooth bluez) |
414 |
+ $(use_scons cxx libgpsmm) |
415 |
+ $(use_scons debug clientdebug) |
416 |
+ $(use_scons dbus dbus_export) |
417 |
+ $(use_scons ipv6) |
418 |
+ $(use_scons latency-timing timing) |
419 |
+ $(use_scons ncurses) |
420 |
+ $(use_scons ntp ntpshm) |
421 |
+ $(use_scons ntp pps) |
422 |
+ $(use_scons python) |
423 |
+ $(use_scons qt5 qt) |
424 |
+ $(use_scons shm shm_export) |
425 |
+ $(use_scons sockets socket_export) |
426 |
+ $(use_scons usb) |
427 |
+ ) |
428 |
+ |
429 |
+ use X && myesconsargs+=( xgps=1 xgpsspeed=1 ) |
430 |
+ use qt5 && myesconsargs+=( qt_versioned=5 ) |
431 |
+ |
432 |
+ # enable specified protocols |
433 |
+ local protocol |
434 |
+ for protocol in ${GPSD_PROTOCOLS[@]} ; do |
435 |
+ myesconsargs+=( $(use_scons gpsd_protocols_${protocol} ${protocol}) ) |
436 |
+ done |
437 |
+} |
438 |
+ |
439 |
+src_compile() { |
440 |
+ export CHRPATH= |
441 |
+ tc-export CC CXX PKG_CONFIG |
442 |
+ export SHLINKFLAGS=${LDFLAGS} LINKFLAGS=${LDFLAGS} |
443 |
+ escons |
444 |
+ |
445 |
+ use python && distutils-r1_src_compile |
446 |
+} |
447 |
+ |
448 |
+src_install() { |
449 |
+ DESTDIR="${D}" escons install $(usex udev udev-install "") |
450 |
+ |
451 |
+ newconfd "${FILESDIR}"/gpsd.conf-2 gpsd |
452 |
+ newinitd "${FILESDIR}"/gpsd.init-2 gpsd |
453 |
+ |
454 |
+ # Cleanup bad alt copy due to Scons |
455 |
+ rm -rf "${D}"/usr/local/$(get_libdir)/python*/site-packages/gps* |
456 |
+ find "${D}"/usr/local/ -type d -delete |
457 |
+ # Install correct multi-python copy |
458 |
+ use python && distutils-r1_src_install |
459 |
+ |
460 |
+} |
461 |
+ |
462 |
+pkg_preinst() { |
463 |
+ # Run the gpsd daemon as gpsd and group uucp; create it here |
464 |
+ # as it doesn't seem to be needed during compile/install ... |
465 |
+ enewuser gpsd -1 -1 -1 "uucp" |
466 |
+} |