1 |
commit: 552ebbe2ce76b2cf418fc41085ec40a94ad0bfe4 |
2 |
Author: Hans de Graaff <graaff <AT> gentoo <DOT> org> |
3 |
AuthorDate: Tue Nov 23 07:02:34 2021 +0000 |
4 |
Commit: Hans de Graaff <graaff <AT> gentoo <DOT> org> |
5 |
CommitDate: Tue Nov 23 07:04:33 2021 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=552ebbe2 |
7 |
|
8 |
sci-geosciences/viking: add 1.9 |
9 |
|
10 |
Thanks to William Pettersson for tracking down required patches. |
11 |
|
12 |
Closes: https://bugs.gentoo.org/826638 |
13 |
|
14 |
Package-Manager: Portage-3.0.28, Repoman-3.0.3 |
15 |
Signed-off-by: Hans de Graaff <graaff <AT> gentoo.org> |
16 |
|
17 |
sci-geosciences/viking/Manifest | 1 + |
18 |
.../viking/files/viking-1.9-geocache.patch | 88 ++++++++++++++++++ |
19 |
sci-geosciences/viking/viking-1.9.ebuild | 100 +++++++++++++++++++++ |
20 |
3 files changed, 189 insertions(+) |
21 |
|
22 |
diff --git a/sci-geosciences/viking/Manifest b/sci-geosciences/viking/Manifest |
23 |
index 2625c50c8b90..537ed00c87ac 100644 |
24 |
--- a/sci-geosciences/viking/Manifest |
25 |
+++ b/sci-geosciences/viking/Manifest |
26 |
@@ -1,2 +1,3 @@ |
27 |
DIST viking-1.8.tar.gz 5207444 BLAKE2B 6a9b786dd23e643a68c25d68e2e14c5a38d2fe6a4a57f6266e13d9208f8c3b49c122921ecf4c54c2630bf9a11e5288346643b4bf92aad67824e8c928de270f84 SHA512 c401e69a6038e4b20c5a2fdecb8b028156e7e8829dd9d48596b0501b6e0a364dc6cc0ab0a8c4bcc731b5c6721835d3cfb605b76ec3b266dab2426df12c321e62 |
28 |
+DIST viking-1.9.tar.gz 5962048 BLAKE2B 7997286619d55687c5f2a394c8e068432c025f4210e579eae68e344495690e08e609352af3a71f3dc10161bd3cbb1126241abd928a13555466c37d164aa1fa5c SHA512 44be8e008db369e8700f91a67f4e4fb7aaab67fa498e71da98502b2893e8efd85502caca23ce9ccba4cf0d167328c4b87b5e422e15b3f8611acf814053646697 |
29 |
DIST viking.pdf 383200 BLAKE2B 388129023e62008de2d2c402a72aa1e4a1834f99e6666bb9deedb5f5c32e8b94edeadf5a40e7b1f941aacc0057d4dcfbaf13c3098eb4efa02e3a1a8e00288201 SHA512 481c88afd43783475366d41cd46a7fa5fdbcd20fec27b3ce286fb8abe1e9efbb4164def0d19fca2380fa95b5b97e9472f25ff5e10f8d95261e85b7c4a52d29ee |
30 |
|
31 |
diff --git a/sci-geosciences/viking/files/viking-1.9-geocache.patch b/sci-geosciences/viking/files/viking-1.9-geocache.patch |
32 |
new file mode 100644 |
33 |
index 000000000000..4779c10dcd4c |
34 |
--- /dev/null |
35 |
+++ b/sci-geosciences/viking/files/viking-1.9-geocache.patch |
36 |
@@ -0,0 +1,88 @@ |
37 |
+From bdfa84467787138b8a180938006b864a39d0dec0 Mon Sep 17 00:00:00 2001 |
38 |
+From: Rob Norris <rw_norris@×××××××.com> |
39 |
+Date: Thu, 3 Jun 2021 21:30:02 +0100 |
40 |
+Subject: [PATCH] Github #128: Maintain datasource_gc.c such that it at least |
41 |
+ compiles |
42 |
+ |
43 |
+--- |
44 |
+ src/datasource_gc.c | 28 +++++++++++++++------------- |
45 |
+ 1 file changed, 15 insertions(+), 13 deletions(-) |
46 |
+ |
47 |
+diff --git a/src/datasource_gc.c b/src/datasource_gc.c |
48 |
+index 37fa425a..22292b2c 100644 |
49 |
+--- a/src/datasource_gc.c |
50 |
++++ b/src/datasource_gc.c |
51 |
+@@ -128,9 +128,9 @@ static void datasource_gc_draw_circle ( datasource_gc_widgets_t *widgets ) |
52 |
+ gdouble lat, lon; |
53 |
+ if ( widgets->circle_onscreen ) { |
54 |
+ vik_viewport_draw_arc ( widgets->vvp, widgets->circle_gc, FALSE, |
55 |
+- widgets->circle_x - widgets->circle_width/2, |
56 |
+- widgets->circle_y - widgets->circle_width/2, |
57 |
+- widgets->circle_width, widgets->circle_width, 0, 360*64 ); |
58 |
++ widgets->circle_x - widgets->circle_width/2, |
59 |
++ widgets->circle_y - widgets->circle_width/2, |
60 |
++ widgets->circle_width, widgets->circle_width, 0, 360*64, NULL ); |
61 |
+ } |
62 |
+ /* calculate widgets circle_x and circle_y */ |
63 |
+ /* split up lat,lon into lat and lon */ |
64 |
+@@ -157,13 +157,13 @@ static void datasource_gc_draw_circle ( datasource_gc_widgets_t *widgets ) |
65 |
+ pixels_per_meter = ((gdouble)vik_viewport_get_width(widgets->vvp)) / vik_coord_diff(&c1, &c2); |
66 |
+ |
67 |
+ /* this is approximate */ |
68 |
+- widgets->circle_width = gtk_spin_button_get_value_as_float ( GTK_SPIN_BUTTON(widgets->miles_radius_spin) ) |
69 |
++ widgets->circle_width = gtk_spin_button_get_value ( GTK_SPIN_BUTTON(widgets->miles_radius_spin) ) |
70 |
+ * METERSPERMILE * pixels_per_meter * 2; |
71 |
+ |
72 |
+ vik_viewport_draw_arc ( widgets->vvp, widgets->circle_gc, FALSE, |
73 |
+- widgets->circle_x - widgets->circle_width/2, |
74 |
+- widgets->circle_y - widgets->circle_width/2, |
75 |
+- widgets->circle_width, widgets->circle_width, 0, 360*64 ); |
76 |
++ widgets->circle_x - widgets->circle_width/2, |
77 |
++ widgets->circle_y - widgets->circle_width/2, |
78 |
++ widgets->circle_width, widgets->circle_width, 0, 360*64, NULL ); |
79 |
+ |
80 |
+ widgets->circle_onscreen = TRUE; |
81 |
+ } else |
82 |
+@@ -172,7 +172,7 @@ static void datasource_gc_draw_circle ( datasource_gc_widgets_t *widgets ) |
83 |
+ |
84 |
+ /* see if onscreen */ |
85 |
+ /* okay */ |
86 |
+- vik_viewport_sync ( widgets->vvp ); |
87 |
++ vik_viewport_sync ( widgets->vvp, NULL ); |
88 |
+ } |
89 |
+ |
90 |
+ static void datasource_gc_add_setup_widgets ( GtkWidget *dialog, VikViewport *vvp, gpointer user_data ) |
91 |
+@@ -197,7 +197,9 @@ static void datasource_gc_add_setup_widgets ( GtkWidget *dialog, VikViewport *vv |
92 |
+ |
93 |
+ widgets->vvp = vvp; |
94 |
+ widgets->circle_gc = vik_viewport_new_gc ( vvp, "#000000", 3 ); |
95 |
++#if !GTK_CHECK_VERSION (3,0,0) |
96 |
+ gdk_gc_set_function ( widgets->circle_gc, GDK_INVERT ); |
97 |
++#endif |
98 |
+ widgets->circle_onscreen = TRUE; |
99 |
+ datasource_gc_draw_circle ( widgets ); |
100 |
+ |
101 |
+@@ -240,7 +242,7 @@ static void datasource_gc_get_process_options ( datasource_gc_widgets_t *widgets |
102 |
+ po->shell_command = g_strdup_printf( "rm -f ~/.geo/caches/*.html ; %s -H ~/.geo/caches -P -n%d -r%.1fM -u %s -p %s %s %s ; %s -z ~/.geo/caches/*.html ", |
103 |
+ GC_PROGRAM1, |
104 |
+ gtk_spin_button_get_value_as_int ( GTK_SPIN_BUTTON(widgets->num_spin) ), |
105 |
+- gtk_spin_button_get_value_as_float ( GTK_SPIN_BUTTON(widgets->miles_radius_spin) ), |
106 |
++ gtk_spin_button_get_value ( GTK_SPIN_BUTTON(widgets->miles_radius_spin) ), |
107 |
+ safe_user, |
108 |
+ safe_pass, |
109 |
+ slat, slon, |
110 |
+@@ -256,10 +258,10 @@ static void datasource_gc_cleanup ( datasource_gc_widgets_t *widgets ) |
111 |
+ { |
112 |
+ if ( widgets->circle_onscreen ) { |
113 |
+ vik_viewport_draw_arc ( widgets->vvp, widgets->circle_gc, FALSE, |
114 |
+- widgets->circle_x - widgets->circle_width/2, |
115 |
+- widgets->circle_y - widgets->circle_width/2, |
116 |
+- widgets->circle_width, widgets->circle_width, 0, 360*64 ); |
117 |
+- vik_viewport_sync( widgets->vvp ); |
118 |
++ widgets->circle_x - widgets->circle_width/2, |
119 |
++ widgets->circle_y - widgets->circle_width/2, |
120 |
++ widgets->circle_width, widgets->circle_width, 0, 360*64, NULL ); |
121 |
++ vik_viewport_sync( widgets->vvp, NULL ); |
122 |
+ } |
123 |
+ g_free ( widgets ); |
124 |
+ } |
125 |
|
126 |
diff --git a/sci-geosciences/viking/viking-1.9.ebuild b/sci-geosciences/viking/viking-1.9.ebuild |
127 |
new file mode 100644 |
128 |
index 000000000000..3a74ac41d23c |
129 |
--- /dev/null |
130 |
+++ b/sci-geosciences/viking/viking-1.9.ebuild |
131 |
@@ -0,0 +1,100 @@ |
132 |
+# Copyright 1999-2021 Gentoo Authors |
133 |
+# Distributed under the terms of the GNU General Public License v2 |
134 |
+ |
135 |
+EAPI=8 |
136 |
+ |
137 |
+inherit autotools xdg-utils |
138 |
+ |
139 |
+DESCRIPTION="GPS data editor and analyzer" |
140 |
+HOMEPAGE="https://github.com/viking-gps/viking/" |
141 |
+IUSE="doc +exif libexif geoclue gps +magic nls oauth" |
142 |
+SRC_URI=" |
143 |
+ https://github.com/viking-gps/${PN}/archive/${P}.tar.gz |
144 |
+ doc? ( https://github.com/viking-gps/${PN}/releases/download/${P}/${PN}.pdf )" |
145 |
+ |
146 |
+LICENSE="GPL-2" |
147 |
+SLOT="0" |
148 |
+KEYWORDS="~amd64 ~x86" |
149 |
+ |
150 |
+COMMONDEPEND=" |
151 |
+ app-arch/bzip2 |
152 |
+ >=dev-tcltk/expect-5.45.4 |
153 |
+ dev-db/sqlite:3 |
154 |
+ dev-libs/expat |
155 |
+ >=dev-libs/glib-2.44:2 |
156 |
+ >=dev-libs/json-glib-0.16 |
157 |
+ dev-libs/nettle |
158 |
+ net-misc/curl |
159 |
+ sys-libs/zlib |
160 |
+ >=x11-libs/gdk-pixbuf-2.26:2 |
161 |
+ >=x11-libs/gtk+-3.22:3 |
162 |
+ geoclue? ( >=app-misc/geoclue-2.4.4:2.0 ) |
163 |
+ gps? ( >=sci-geosciences/gpsd-3.20 ) |
164 |
+ exif? ( libexif? ( media-libs/libexif ) !libexif? ( media-libs/gexiv2 ) ) |
165 |
+ magic? ( sys-apps/file ) |
166 |
+ oauth? ( net-libs/liboauth ) |
167 |
+" |
168 |
+RDEPEND="${COMMONDEPEND} |
169 |
+ sci-geosciences/gpsbabel |
170 |
+" |
171 |
+DEPEND="${COMMONDEPEND} |
172 |
+ app-text/yelp-tools |
173 |
+ dev-util/intltool |
174 |
+ dev-util/gtk-doc |
175 |
+ dev-util/gtk-doc-am |
176 |
+ dev-libs/libxslt |
177 |
+ virtual/pkgconfig |
178 |
+ sys-devel/gettext |
179 |
+" |
180 |
+ |
181 |
+S="${WORKDIR}/${PN}-${P}" |
182 |
+ |
183 |
+PATCHES=( "${FILESDIR}/${P}-geocache.patch" ) |
184 |
+ |
185 |
+src_prepare() |
186 |
+{ |
187 |
+ default |
188 |
+ eautoreconf |
189 |
+} |
190 |
+ |
191 |
+src_configure() { |
192 |
+ econf \ |
193 |
+ --disable-deprecations \ |
194 |
+ --with-libcurl \ |
195 |
+ --with-expat \ |
196 |
+ --enable-google \ |
197 |
+ --enable-nettle \ |
198 |
+ --enable-terraserver \ |
199 |
+ --enable-expedia \ |
200 |
+ --enable-openstreetmap \ |
201 |
+ --enable-bluemarble \ |
202 |
+ --enable-geonames \ |
203 |
+ --enable-geocaches \ |
204 |
+ --disable-dem24k \ |
205 |
+ --disable-mapnik \ |
206 |
+ --enable-mbtiles \ |
207 |
+ $(use_enable exif geotag) \ |
208 |
+ $(use_with libexif ) \ |
209 |
+ $(use_enable geoclue) \ |
210 |
+ $(use_enable gps realtime-gps-tracking) \ |
211 |
+ $(use_enable magic) \ |
212 |
+ $(use_enable nls) \ |
213 |
+ $(use_enable oauth) |
214 |
+} |
215 |
+ |
216 |
+src_install() { |
217 |
+ default |
218 |
+ if use doc; then |
219 |
+ dodoc "${DISTDIR}"/${PN}.pdf |
220 |
+ fi |
221 |
+} |
222 |
+ |
223 |
+pkg_postinst() { |
224 |
+ xdg_icon_cache_update |
225 |
+ xdg_desktop_database_update |
226 |
+} |
227 |
+ |
228 |
+pkg_postrm() { |
229 |
+ xdg_icon_cache_update |
230 |
+ xdg_desktop_database_update |
231 |
+} |