1 |
commit: 8c3c9b3ee65110b260bad3d6f77384cd54151b04 |
2 |
Author: Bernard Cafarelli <voyageur <AT> gentoo <DOT> org> |
3 |
AuthorDate: Mon Dec 6 13:25:32 2021 +0000 |
4 |
Commit: Bernard Cafarelli <voyageur <AT> gentoo <DOT> org> |
5 |
CommitDate: Mon Dec 6 13:26:00 2021 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=8c3c9b3e |
7 |
|
8 |
gnustep-apps/gworkspace: fix compilation with current gnustep |
9 |
|
10 |
Thanks Antti Aspinen for the report and patch link |
11 |
Patch adapted from master commit ea0f7fef5efd798a8bcad59d20fe48eb4232d730 |
12 |
|
13 |
Package-Manager: Portage-3.0.28, Repoman-3.0.3 |
14 |
Signed-off-by: Bernard Cafarelli <voyageur <AT> gentoo.org> |
15 |
|
16 |
.../gworkspace-0.9.4-ImageViewerProtocol.patch | 186 +++++++++++++++++++++ |
17 |
gnustep-apps/gworkspace/gworkspace-0.9.4-r1.ebuild | 44 +++++ |
18 |
2 files changed, 230 insertions(+) |
19 |
|
20 |
diff --git a/gnustep-apps/gworkspace/files/gworkspace-0.9.4-ImageViewerProtocol.patch b/gnustep-apps/gworkspace/files/gworkspace-0.9.4-ImageViewerProtocol.patch |
21 |
new file mode 100644 |
22 |
index 000000000000..d2bfd54e60bf |
23 |
--- /dev/null |
24 |
+++ b/gnustep-apps/gworkspace/files/gworkspace-0.9.4-ImageViewerProtocol.patch |
25 |
@@ -0,0 +1,186 @@ |
26 |
+diff -Naur gworkspace-0.9.4.orig/Inspector/ContentViewers/ImageViewer/ImageViewer.h gworkspace-0.9.4/Inspector/ContentViewers/ImageViewer/ImageViewer.h |
27 |
+--- gworkspace-0.9.4.orig/Inspector/ContentViewers/ImageViewer/ImageViewer.h 2016-06-07 18:13:08.000000000 +0200 |
28 |
++++ gworkspace-0.9.4/Inspector/ContentViewers/ImageViewer/ImageViewer.h 2021-12-06 14:18:12.024085590 +0100 |
29 |
+@@ -1,8 +1,9 @@ |
30 |
+ /* ImageViewer.h |
31 |
+ * |
32 |
+- * Copyright (C) 2004-2016 Free Software Foundation, Inc. |
33 |
++ * Copyright (C) 2004-2020 Free Software Foundation, Inc. |
34 |
+ * |
35 |
+- * Author: Enrico Sersale <enrico@×××××.ro> |
36 |
++ * Authors: Enrico Sersale <enrico@×××××.ro> |
37 |
++ * Riccardo Mottola <rm@×××.org> |
38 |
+ * Date: January 2004 |
39 |
+ * |
40 |
+ * This file is part of the GNUstep Inspector application |
41 |
+@@ -36,6 +37,7 @@ |
42 |
+ @class NSWorkspace; |
43 |
+ @class ProgressView; |
44 |
+ @class ImageResizer; |
45 |
++ |
46 |
+ @protocol ContentInspectorProtocol |
47 |
+ |
48 |
+ - (void)contentsReadyAt:(NSString *)path; |
49 |
+@@ -51,7 +53,7 @@ |
50 |
+ |
51 |
+ @end |
52 |
+ |
53 |
+-@interface ImageViewer : NSView <ContentViewersProtocol> |
54 |
++@interface ImageViewer : NSView <ContentViewersProtocol, ImageViewerProtocol> |
55 |
+ { |
56 |
+ NSArray *extsarr; |
57 |
+ BOOL valid; |
58 |
+@@ -76,9 +78,9 @@ |
59 |
+ NSWorkspace *ws; |
60 |
+ } |
61 |
+ |
62 |
+-- (void)setResizer:(id)anObject; |
63 |
++- (oneway void)setResizer:(id)anObject; |
64 |
+ |
65 |
+-- (void)imageReady:(NSDictionary *)imginfo; |
66 |
++- (oneway void)imageReady:(NSDictionary *)imginfo; |
67 |
+ |
68 |
+ - (void)editFile:(id)sender; |
69 |
+ |
70 |
+diff -Naur gworkspace-0.9.4.orig/Inspector/ContentViewers/ImageViewer/ImageViewer.m gworkspace-0.9.4/Inspector/ContentViewers/ImageViewer/ImageViewer.m |
71 |
+--- gworkspace-0.9.4.orig/Inspector/ContentViewers/ImageViewer/ImageViewer.m 2016-06-07 18:13:08.000000000 +0200 |
72 |
++++ gworkspace-0.9.4/Inspector/ContentViewers/ImageViewer/ImageViewer.m 2021-12-06 14:18:12.024085590 +0100 |
73 |
+@@ -198,7 +198,7 @@ |
74 |
+ } |
75 |
+ } |
76 |
+ |
77 |
+-- (void)setResizer:(id)anObject |
78 |
++- (oneway void)setResizer:(id)anObject |
79 |
+ { |
80 |
+ NSSize imsize = [imview bounds].size; |
81 |
+ |
82 |
+@@ -207,6 +207,7 @@ |
83 |
+ [anObject setProtocolForProxy: @protocol(ImageResizerProtocol)]; |
84 |
+ resizer = (ImageResizer *)anObject; |
85 |
+ RETAIN (resizer); |
86 |
++ [resizer setProxy: self]; |
87 |
+ [self addSubview: progView]; |
88 |
+ [progView start]; |
89 |
+ [resizer readImageAtPath: imagePath setSize: imsize]; |
90 |
+@@ -214,7 +215,7 @@ |
91 |
+ |
92 |
+ |
93 |
+ |
94 |
+-- (void)imageReady:(NSDictionary *)imginfo |
95 |
++- (oneway void)imageReady:(NSDictionary *)imginfo |
96 |
+ { |
97 |
+ NSData *imgdata; |
98 |
+ BOOL imgok; |
99 |
+diff -Naur gworkspace-0.9.4.orig/Inspector/ContentViewers/ImageViewer/Resizer.h gworkspace-0.9.4/Inspector/ContentViewers/ImageViewer/Resizer.h |
100 |
+--- gworkspace-0.9.4.orig/Inspector/ContentViewers/ImageViewer/Resizer.h 2016-06-01 18:35:46.000000000 +0200 |
101 |
++++ gworkspace-0.9.4/Inspector/ContentViewers/ImageViewer/Resizer.h 2021-12-06 14:18:12.024085590 +0100 |
102 |
+@@ -1,9 +1,10 @@ |
103 |
+ /* Resizer.m |
104 |
+ h |
105 |
+ * |
106 |
+- * Copyright (C) 2005-2016 Free Software Foundation, Inc. |
107 |
++ * Copyright (C) 2005-2020 Free Software Foundation, Inc. |
108 |
+ * |
109 |
+- * Author: Enrico Sersale <enrico@×××××.ro> |
110 |
++ * Authors: Enrico Sersale <enrico@×××××.ro> |
111 |
++ * Riccardo Mottola <rm@×××.org> |
112 |
+ * Date: May 2016 |
113 |
+ * |
114 |
+ * This file is part of the GNUstep Inspector application |
115 |
+@@ -23,14 +24,15 @@ |
116 |
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111 USA. |
117 |
+ */ |
118 |
+ |
119 |
+- |
120 |
+-NSConnection *serverConnection; |
121 |
++#import "ContentViewersProtocol.h" |
122 |
+ |
123 |
+ @interface ImageResizer : NSObject |
124 |
+ { |
125 |
+- |
126 |
++ id <ImageViewerProtocol> imageViewerProxy; |
127 |
+ } |
128 |
+ |
129 |
++- (void)setProxy:(id <ImageViewerProtocol>)ivp; |
130 |
++ |
131 |
+ - (void)readImageAtPath:(NSString *)path |
132 |
+ setSize:(NSSize)imsize; |
133 |
+ |
134 |
+diff -Naur gworkspace-0.9.4.orig/Inspector/ContentViewers/ImageViewer/Resizer.m gworkspace-0.9.4/Inspector/ContentViewers/ImageViewer/Resizer.m |
135 |
+--- gworkspace-0.9.4.orig/Inspector/ContentViewers/ImageViewer/Resizer.m 2016-06-07 17:28:36.000000000 +0200 |
136 |
++++ gworkspace-0.9.4/Inspector/ContentViewers/ImageViewer/Resizer.m 2021-12-06 14:18:45.928073537 +0100 |
137 |
+@@ -33,24 +33,13 @@ |
138 |
+ do { if (GW_DEBUG_LOG) \ |
139 |
+ NSLog(format , ## args); } while (0) |
140 |
+ |
141 |
+-@protocol ImageViewerProtocol |
142 |
+- |
143 |
+-- (oneway void)setResizer:(id)anObject; |
144 |
+- |
145 |
+-- (oneway void)imageReady:(NSDictionary *)dict; |
146 |
+- |
147 |
+-@end |
148 |
+- |
149 |
+- |
150 |
+- |
151 |
+- |
152 |
+- |
153 |
+ @implementation ImageResizer |
154 |
+ |
155 |
+ + (void)connectWithPorts:(NSArray *)portArray |
156 |
+ { |
157 |
+ NSAutoreleasePool *pool; |
158 |
+ ImageResizer *serverObject; |
159 |
++ NSConnection *serverConnection; |
160 |
+ |
161 |
+ pool = [[NSAutoreleasePool alloc] init]; |
162 |
+ |
163 |
+@@ -77,6 +66,11 @@ |
164 |
+ |
165 |
+ #define MIX_LIM 16 |
166 |
+ |
167 |
++- (void)setProxy:(id <ImageViewerProtocol>)ivp |
168 |
++{ |
169 |
++ imageViewerProxy = ivp; |
170 |
++} |
171 |
++ |
172 |
+ - (void)readImageAtPath:(NSString *)path |
173 |
+ setSize:(NSSize)imsize |
174 |
+ { |
175 |
+@@ -191,7 +185,7 @@ |
176 |
+ |
177 |
+ RELEASE (srcImage); |
178 |
+ } |
179 |
+- [(id <ImageViewerProtocol>)[serverConnection rootProxy] imageReady: info]; |
180 |
++ [imageViewerProxy imageReady: info]; |
181 |
+ RELEASE (arp); |
182 |
+ } |
183 |
+ |
184 |
+diff -Naur gworkspace-0.9.4.orig/Inspector/ContentViewersProtocol.h gworkspace-0.9.4/Inspector/ContentViewersProtocol.h |
185 |
+--- gworkspace-0.9.4.orig/Inspector/ContentViewersProtocol.h 2010-06-16 19:45:53.000000000 +0200 |
186 |
++++ gworkspace-0.9.4/Inspector/ContentViewersProtocol.h 2021-12-06 14:18:12.025085590 +0100 |
187 |
+@@ -1,8 +1,9 @@ |
188 |
+ /* ContentViewersProtocol.h |
189 |
+ * |
190 |
+- * Copyright (C) 2004 Free Software Foundation, Inc. |
191 |
++ * Copyright (C) 2004-2020 Free Software Foundation, Inc. |
192 |
+ * |
193 |
+- * Author: Enrico Sersale <enrico@×××××.ro> |
194 |
++ * Authors: Enrico Sersale <enrico@×××××.ro> |
195 |
++ * Riccardo Mottola <rm@×××.org> |
196 |
+ * Date: January 2004 |
197 |
+ * |
198 |
+ * This file is part of the GNUstep GWorkspace application |
199 |
+@@ -48,4 +49,12 @@ |
200 |
+ |
201 |
+ @end |
202 |
+ |
203 |
++/* Proxy for DO connection */ |
204 |
+ |
205 |
++@protocol ImageViewerProtocol |
206 |
++ |
207 |
++- (oneway void)setResizer:(id)anObject; |
208 |
++ |
209 |
++- (oneway void)imageReady:(NSDictionary *)dict; |
210 |
++ |
211 |
++@end |
212 |
|
213 |
diff --git a/gnustep-apps/gworkspace/gworkspace-0.9.4-r1.ebuild b/gnustep-apps/gworkspace/gworkspace-0.9.4-r1.ebuild |
214 |
new file mode 100644 |
215 |
index 000000000000..774ee0d4ccf5 |
216 |
--- /dev/null |
217 |
+++ b/gnustep-apps/gworkspace/gworkspace-0.9.4-r1.ebuild |
218 |
@@ -0,0 +1,44 @@ |
219 |
+# Copyright 1999-2021 Gentoo Authors |
220 |
+# Distributed under the terms of the GNU General Public License v2 |
221 |
+ |
222 |
+EAPI=7 |
223 |
+inherit gnustep-2 |
224 |
+ |
225 |
+DESCRIPTION="A workspace manager for GNUstep" |
226 |
+HOMEPAGE="http://www.gnustep.org/experience/GWorkspace.html" |
227 |
+SRC_URI="ftp://ftp.gnustep.org/pub/gnustep/usr-apps/${P}.tar.gz" |
228 |
+ |
229 |
+KEYWORDS="~amd64 ~ppc ~x86" |
230 |
+LICENSE="GPL-2" |
231 |
+SLOT="0" |
232 |
+ |
233 |
+IUSE="+gwmetadata" |
234 |
+ |
235 |
+DEPEND=">=gnustep-base/gnustep-gui-0.25.0 |
236 |
+ gwmetadata? ( |
237 |
+ >=gnustep-apps/systempreferences-1.0.1_p24791 |
238 |
+ >=dev-db/sqlite-3.2.8 |
239 |
+ )" |
240 |
+RDEPEND="${DEPEND}" |
241 |
+ |
242 |
+PATCHES=( "${FILESDIR}"/${P}-ImageViewerProtocol.patch ) |
243 |
+ |
244 |
+src_configure() { |
245 |
+ local myconf="" |
246 |
+ use kernel_linux && myconf="${myconf} --with-inotify" |
247 |
+ use gwmetadata && myconf="${myconf} --enable-gwmetadata" |
248 |
+ |
249 |
+ egnustep_env |
250 |
+ econf ${myconf} |
251 |
+} |
252 |
+ |
253 |
+src_install() { |
254 |
+ egnustep_env |
255 |
+ egnustep_install |
256 |
+ |
257 |
+ if use doc; |
258 |
+ then |
259 |
+ dodir /usr/share/doc/${PF} |
260 |
+ cp "${S}"/Documentation/*.pdf "${D}"/usr/share/doc/${PF} |
261 |
+ fi |
262 |
+} |