1 |
opfer 07/09/27 17:43:46 |
2 |
|
3 |
Added: gnotime-2.2.2-guile-1_8.patch |
4 |
digest-gnotime-2.2.2-r1 |
5 |
Log: |
6 |
revision bump with patch for Guile 1.8, provided by Serhij S. Stasyuk <stas@××××××××.net> in bug 171141; -r0 changed to test for USE=deprecated in Guile 1.8 and stable for x86; removed some unneeded documentation files (COPYING, INSTALL) and adjusted DESCRIPTION |
7 |
(Portage version: 2.1.3.9) |
8 |
|
9 |
Revision Changes Path |
10 |
1.1 app-office/gnotime/files/gnotime-2.2.2-guile-1_8.patch |
11 |
|
12 |
file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/app-office/gnotime/files/gnotime-2.2.2-guile-1_8.patch?rev=1.1&view=markup |
13 |
plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/app-office/gnotime/files/gnotime-2.2.2-guile-1_8.patch?rev=1.1&content-type=text/plain |
14 |
|
15 |
Index: gnotime-2.2.2-guile-1_8.patch |
16 |
=================================================================== |
17 |
diff -Nru gnotime-2.2.2.orig/ghtml/C/basic-invoice.ghtml gnotime-2.2.2/ghtml/C/basic-invoice.ghtml |
18 |
--- gnotime-2.2.2.orig/ghtml/C/basic-invoice.ghtml 2004-04-25 06:19:17.000000000 +0300 |
19 |
+++ gnotime-2.2.2/ghtml/C/basic-invoice.ghtml 2007-02-12 20:55:56.000000000 +0200 |
20 |
@@ -57,7 +57,7 @@ |
21 |
''"<td>" gtt-task-time-str ''"</td>\n" |
22 |
''"<td>" gtt-task-value-str ''"</td>\n" |
23 |
''"<td>" gtt-task-billable-value-str ''"</td>\n" |
24 |
- ''</tr> |
25 |
+ ''"</tr>" |
26 |
) |
27 |
) |
28 |
|
29 |
@@ -92,7 +92,7 @@ |
30 |
''"<td>" gtt-task-time-str ''"</td>\n" |
31 |
''"<td>" gtt-task-value-str ''"</td>\n" |
32 |
''"<td>" gtt-task-billable-value-str ''"</td>\n" |
33 |
- ''</tr> |
34 |
+ ''"</tr>" |
35 |
) |
36 |
) |
37 |
|
38 |
@@ -127,7 +127,7 @@ |
39 |
''"<td>" gtt-task-time-str ''"</td>\n" |
40 |
''"<td>" gtt-task-value-str ''"</td>\n" |
41 |
''"<td>" gtt-task-billable-value-str ''"</td>\n" |
42 |
- ''</tr> |
43 |
+ ''"</tr>" |
44 |
) |
45 |
) |
46 |
|
47 |
diff -Nru gnotime-2.2.2.orig/ghtml/C/invoice.ghtml gnotime-2.2.2/ghtml/C/invoice.ghtml |
48 |
--- gnotime-2.2.2.orig/ghtml/C/invoice.ghtml 2004-04-25 06:19:17.000000000 +0300 |
49 |
+++ gnotime-2.2.2/ghtml/C/invoice.ghtml 2007-02-12 20:55:31.000000000 +0200 |
50 |
@@ -72,7 +72,7 @@ |
51 |
''"<td>" gtt-task-time-str ''"</td>\n" |
52 |
''"<td align=right>" gtt-task-value-str ''"</td>\n" |
53 |
''"<td align=right>" gtt-task-billable-value-str ''"</td>\n" |
54 |
- ''</tr> |
55 |
+ ''"</tr>" |
56 |
) |
57 |
) |
58 |
(gtt-show '" </table> </center>\n") |
59 |
@@ -114,7 +114,7 @@ |
60 |
''"<td>" gtt-task-time-str ''"</td>\n" |
61 |
''"<td align=right>" gtt-task-value-str ''"</td>\n" |
62 |
''"<td align=right>" gtt-task-billable-value-str ''"</td>\n" |
63 |
- ''</tr> |
64 |
+ ''"</tr>" |
65 |
) |
66 |
) |
67 |
(gtt-show '" </table> </center>\n") |
68 |
@@ -156,7 +156,7 @@ |
69 |
''"<td>" gtt-task-time-str ''"</td>\n" |
70 |
''"<td align=right>" gtt-task-value-str ''"</td>\n" |
71 |
''"<td align=right>" gtt-task-billable-value-str ''"</td>\n" |
72 |
- ''</tr> |
73 |
+ ''"</tr>" |
74 |
) |
75 |
) |
76 |
(gtt-show '" </table> </center>\n") |
77 |
diff -Nru gnotime-2.2.2.orig/ghtml/C/primer.ghtml gnotime-2.2.2/ghtml/C/primer.ghtml |
78 |
--- gnotime-2.2.2.orig/ghtml/C/primer.ghtml 2004-05-18 22:59:24.000000000 +0300 |
79 |
+++ gnotime-2.2.2/ghtml/C/primer.ghtml 2007-02-12 20:55:38.000000000 +0200 |
80 |
@@ -279,7 +279,7 @@ |
81 |
''"<td>" gtt-task-time-str ''"</td>\n" |
82 |
''"<td>" gtt-task-value-str ''"</td>\n" |
83 |
''"<td>" gtt-task-billable-value-str ''"</td>\n" |
84 |
- ''</tr> |
85 |
+ ''"</tr>" |
86 |
) |
87 |
) |
88 |
|
89 |
diff -Nru gnotime-2.2.2.orig/src/ghtml.c gnotime-2.2.2/src/ghtml.c |
90 |
--- gnotime-2.2.2.orig/src/ghtml.c 2005-09-02 03:33:15.000000000 +0300 |
91 |
+++ gnotime-2.2.2/src/ghtml.c 2007-02-12 20:51:06.000000000 +0200 |
92 |
@@ -65,7 +65,7 @@ |
93 |
static SCM |
94 |
do_ret_did_query (GttGhtml *ghtml) |
95 |
{ |
96 |
- return SCM_BOOL (ghtml->did_query); |
97 |
+ return scm_from_bool (ghtml->did_query); |
98 |
} |
99 |
|
100 |
static SCM |
101 |
@@ -84,7 +84,7 @@ |
102 |
SCM rc, node; |
103 |
rc = SCM_EOL; |
104 |
|
105 |
- while (FALSE == SCM_NULLP(node_list)) |
106 |
+ while (!scm_is_null (node_list)) |
107 |
{ |
108 |
node = SCM_CAR (node_list); |
109 |
rc = scm_cons (node, rc); |
110 |
@@ -114,11 +114,11 @@ |
111 |
SCM (*ivl_func)(GttGhtml *, GttInterval *)) |
112 |
{ |
113 |
/* Either a 'symbol or a "quoted string" */ |
114 |
- if (SCM_SYMBOLP(node) || SCM_STRINGP (node)) |
115 |
+ if (scm_is_symbol(node) || scm_is_string (node)) |
116 |
{ |
117 |
SCM rc = SCM_EOL; |
118 |
- char *str = SCM_STRING_CHARS (node); |
119 |
- int len = SCM_STRING_LENGTH (node); |
120 |
+ char *str = scm_to_locale_string (node); |
121 |
+ int len = strlen (str); |
122 |
if ((0<len) && str_func) rc = str_func (ghtml, str); |
123 |
return rc; |
124 |
} |
125 |
@@ -130,20 +130,23 @@ |
126 |
switch (cur_type) |
127 |
{ |
128 |
case GTT_PRJ: { |
129 |
- GttProject *prj = (GttProject *) scm_num2ulong (node, |
130 |
- SCM_ARG1, "GnoTime::do-apply-based-on-type==project"); |
131 |
+// GttProject *prj = (GttProject *) scm_num2ulong (node, |
132 |
+// SCM_ARG1, "GnoTime::do-apply-based-on-type==project"); |
133 |
+ GttProject *prj = (GttProject *) scm_to_ulong (node); |
134 |
if (prj_func) rc = prj_func (ghtml, prj); |
135 |
break; |
136 |
} |
137 |
case GTT_TASK: { |
138 |
- GttTask *tsk = (GttTask *) scm_num2ulong (node, |
139 |
- SCM_ARG1, "GnoTime::do-apply-based-on-type==task"); |
140 |
+// GttTask *tsk = (GttTask *) scm_num2ulong (node, |
141 |
+// SCM_ARG1, "GnoTime::do-apply-based-on-type==task"); |
142 |
+ GttTask *tsk = (GttTask *) scm_to_ulong (node); |
143 |
if (tsk_func) rc = tsk_func (ghtml, tsk); |
144 |
break; |
145 |
} |
146 |
case GTT_IVL: { |
147 |
- GttInterval *ivl = (GttInterval *) scm_num2ulong (node, |
148 |
- SCM_ARG1, "GnoTime::do-apply-based-on-type==interval"); |
149 |
+// GttInterval *ivl = (GttInterval *) scm_num2ulong (node, |
150 |
+// SCM_ARG1, "GnoTime::do-apply-based-on-type==interval"); |
151 |
+ GttInterval *ivl = (GttInterval *) scm_to_ulong (node); |
152 |
if (ivl_func) rc = ivl_func (ghtml, ivl); |
153 |
break; |
154 |
} |
155 |
@@ -155,7 +158,7 @@ |
156 |
} |
157 |
|
158 |
/* If its a list, then process the list */ |
159 |
- if (SCM_CONSP(node)) |
160 |
+ if (scm_is_pair(node)) |
161 |
{ |
162 |
SCM rc = SCM_EOL; |
163 |
SCM node_list = node; |
164 |
@@ -164,14 +167,14 @@ |
165 |
* type. If so, then strip off the label, and pass back |
166 |
* car to ourselves, and passing the corrected type. |
167 |
*/ |
168 |
- if (FALSE == SCM_NULLP(node)) |
169 |
+ if (!scm_is_null (node)) |
170 |
{ |
171 |
SCM type; |
172 |
type = SCM_CDR (node); |
173 |
- if (SCM_SYMBOLP(type) || SCM_STRINGP (type)) |
174 |
+ if (scm_is_symbol(type) || scm_is_string (type)) |
175 |
{ |
176 |
cur_type = GTT_NONE; |
177 |
- char *buff = SCM_STRING_CHARS (type); |
178 |
+ char *buff = scm_to_locale_string (type); |
179 |
|
180 |
if ((!strncmp (buff, "gtt-project-ptr",15)) || |
181 |
(!strncmp (buff, "gtt-project-list",16))) |
182 |
@@ -199,7 +202,7 @@ |
183 |
/* Otherwise, we have just a list. Walk that list, |
184 |
* apply recursively to it. |
185 |
*/ |
186 |
- while (FALSE == SCM_NULLP(node_list)) |
187 |
+ while (!scm_is_null (node_list)) |
188 |
{ |
189 |
SCM evl; |
190 |
node = SCM_CAR (node_list); |
191 |
@@ -207,7 +210,7 @@ |
192 |
evl = do_apply_based_on_type (ghtml, node, cur_type, |
193 |
str_func, prj_func, tsk_func, ivl_func); |
194 |
|
195 |
- if (FALSE == SCM_NULLP (evl)) |
196 |
+ if (!scm_is_null (evl)) |
197 |
{ |
198 |
rc = scm_cons (evl, rc); |
199 |
} |
200 |
@@ -222,7 +225,7 @@ |
201 |
} |
202 |
|
203 |
/* If its a null list, do nothing */ |
204 |
- if (SCM_NULLP (node)) |
205 |
+ if (scm_is_null (node)) |
206 |
{ |
207 |
return node; |
208 |
} |
209 |
@@ -280,7 +283,9 @@ |
210 |
if (!val) return SCM_EOL; |
211 |
str = kvp_value_get_string (val); |
212 |
if (!str) return SCM_EOL; |
213 |
- return scm_mem2string (str, strlen (str)); |
214 |
+// return scm_mem2string (str, strlen (str)); |
215 |
+// return scm_from_locale_stringn (str, strlen (str)); |
216 |
+ return scm_from_locale_string (str); |
217 |
} |
218 |
|
219 |
static SCM |
220 |
@@ -310,7 +315,8 @@ |
221 |
double x; |
222 |
long ix; |
223 |
|
224 |
- x = scm_num2dbl (node, "GnoTime::do_show_scm"); |
225 |
+// x = scm_to_double (node, "GnoTime::do_show_scm"); |
226 |
+ x = scm_to_double (node); |
227 |
ix = (long) x; |
228 |
|
229 |
/* If the number is representable in 32 bits, |
230 |
@@ -330,14 +336,14 @@ |
231 |
} |
232 |
else |
233 |
/* either a 'symbol or a "quoted string" */ |
234 |
- if (SCM_SYMBOLP(node) || SCM_STRINGP (node)) |
235 |
+ if (scm_is_symbol(node) || scm_is_string (node)) |
236 |
{ |
237 |
- str = SCM_STRING_CHARS (node); |
238 |
- len = SCM_STRING_LENGTH (node); |
239 |
+ str = scm_to_locale_string (node); |
240 |
+ len = strlen (str); |
241 |
if (0<len) (ghtml->write_stream) (ghtml, str, len, ghtml->user_data); |
242 |
} |
243 |
else |
244 |
- if (SCM_CONSP(node)) |
245 |
+ if (scm_is_pair(node)) |
246 |
{ |
247 |
SCM node_list = node; |
248 |
do |
249 |
@@ -346,19 +352,19 @@ |
250 |
do_show_scm (ghtml, node); |
251 |
node_list = SCM_CDR (node_list); |
252 |
} |
253 |
- while (SCM_CONSP(node_list)); |
254 |
+ while (scm_is_pair(node_list)); |
255 |
do_show_scm (ghtml, node_list); |
256 |
} |
257 |
else |
258 |
- if (SCM_BOOLP(node)) |
259 |
+ if (scm_is_bool(node)) |
260 |
{ |
261 |
const char *str; |
262 |
- if (SCM_FALSEP(node)) str = _("False"); |
263 |
+ if (scm_is_false (node)) str = _("False"); |
264 |
else str = _("True"); |
265 |
(ghtml->write_stream) (ghtml, str, strlen(str), ghtml->user_data); |
266 |
} |
267 |
else |
268 |
- if (SCM_NULLP(node)) |
269 |
+ if (scm_is_null (node)) |
270 |
{ |
271 |
/* No op; maybe this should be a warning? */ |
272 |
} |
273 |
@@ -394,10 +400,13 @@ |
274 |
do_ret_project (GttGhtml *ghtml, GttProject *prj) |
275 |
{ |
276 |
SCM node,rc; |
277 |
- rc = scm_ulong2num ((unsigned long) prj); |
278 |
+// rc = scm_ulong2num ((unsigned long) prj); |
279 |
+ rc = scm_from_ulong ((unsigned long) prj); |
280 |
|
281 |
/* Label the pointer with a type identifier */ |
282 |
- node = scm_mem2string ("gtt-project-ptr", 15); |
283 |
+// node = scm_mem2string ("gtt-project-ptr", 15); |
284 |
+// node = scm_from_locale_stringn ("gtt-project-ptr", 15); |
285 |
+ node = scm_from_locale_string ("gtt-project-ptr"); |
286 |
rc = scm_cons (rc, node); |
287 |
|
288 |
return rc; |
289 |
@@ -474,14 +483,14 @@ |
290 |
do_include_file_scm (GttGhtml *ghtml, SCM node) |
291 |
{ |
292 |
/* either a 'symbol or a "quoted string" */ |
293 |
- if (SCM_SYMBOLP(node) || SCM_STRINGP (node)) |
294 |
+ if (scm_is_symbol(node) || scm_is_string (node)) |
295 |
{ |
296 |
- const char * filepath = SCM_STRING_CHARS (node); |
297 |
+ const char * filepath = scm_to_locale_string (node); |
298 |
filepath = gtt_ghtml_resolve_path(filepath, ghtml->ref_path); |
299 |
gtt_ghtml_display (ghtml, filepath, NULL); |
300 |
} |
301 |
else |
302 |
- if (SCM_CONSP(node)) |
303 |
+ if (scm_is_pair(node)) |
304 |
{ |
305 |
SCM node_list = node; |
306 |
do |
307 |
@@ -490,11 +499,11 @@ |
308 |
do_include_file_scm (ghtml, node); |
309 |
node_list = SCM_CDR (node_list); |
310 |
} |
311 |
- while (SCM_CONSP(node_list)); |
312 |
+ while (scm_is_pair(node_list)); |
313 |
do_include_file_scm (ghtml, node_list); |
314 |
} |
315 |
else |
316 |
- if (SCM_NULLP(node)) |
317 |
+ if (scm_is_null (node)) |
318 |
{ |
319 |
/* No op; maybe this should be a warning? */ |
320 |
} |
321 |
@@ -537,13 +546,16 @@ |
322 |
/* Walk backwards, creating a scheme list */ |
323 |
for (n= gplist; n; n=n->prev) |
324 |
{ |
325 |
- node = scm_ulong2num ((unsigned long) n->data); |
326 |
+// node = scm_ulong2num ((unsigned long) n->data); |
327 |
+ node = scm_from_ulong ((unsigned long) n->data); |
328 |
rc = scm_cons (node, rc); |
329 |
} |
330 |
} |
331 |
|
332 |
/* Prepend type label */ |
333 |
- node = scm_mem2string (type, strlen (type)); |
334 |
+// node = scm_mem2string (type, strlen (type)); |
335 |
+// node = scm_from_locale_stringn (type, strlen (type)); |
336 |
+ node = scm_from_locale_string (type); |
337 |
rc = scm_cons (rc, node); |
338 |
|
339 |
return rc; |
340 |
@@ -584,7 +596,8 @@ |
341 |
rc = scm_cons (node, rc); |
342 |
} |
343 |
#endif |
344 |
- node = scm_ulong2num ((unsigned long) prj); |
345 |
+// node = scm_ulong2num ((unsigned long) prj); |
346 |
+ node = scm_from_ulong ((unsigned long) prj); |
347 |
rc = scm_cons (node, rc); |
348 |
} |
349 |
return rc; |
350 |
@@ -670,9 +683,10 @@ |
351 |
for (n= task_list; n; n=n->prev) |
352 |
{ |
353 |
GttTask *tsk = n->data; |
354 |
- SCM node; |
355 |
+ SCM node; |
356 |
|
357 |
- node = scm_ulong2num ((unsigned long) tsk); |
358 |
+// node = scm_ulong2num ((unsigned long) tsk); |
359 |
+ node = scm_from_ulong ((unsigned long) tsk); |
360 |
rc = scm_cons (node, rc); |
361 |
} |
362 |
return rc; |
363 |
@@ -715,7 +729,8 @@ |
364 |
GttInterval *ivl = n->data; |
365 |
SCM node; |
366 |
|
367 |
- node = scm_ulong2num ((unsigned long) ivl); |
368 |
+// node = scm_ulong2num ((unsigned long) ivl); |
369 |
+ node = scm_from_ulong ((unsigned long) ivl); |
370 |
rc = scm_cons (node, rc); |
371 |
} |
372 |
return rc; |
373 |
@@ -778,18 +793,24 @@ |
374 |
/* XXX should use time_t, and srfi-19 to print, and have a type label */ |
375 |
/* Print time spent on project this day */ |
376 |
qof_print_hours_elapsed_buff (buff, 100, secs, TRUE); |
377 |
- node = scm_mem2string (buff, strlen (buff)); |
378 |
+// node = scm_mem2string (buff, strlen (buff)); |
379 |
+// node = scm_from_locale_stringn (buff, strlen (buff)); |
380 |
+ node = scm_from_locale_string (buff); |
381 |
rpt = scm_cons (node, rpt); |
382 |
|
383 |
/* XXX report date should be time_t in the middle of the interval */ |
384 |
/* Print date */ |
385 |
rptdate = mktime (&tday); |
386 |
qof_print_date_buff (buff, 100, rptdate); |
387 |
- node = scm_mem2string (buff, strlen (buff)); |
388 |
+// node = scm_mem2string (buff, strlen (buff)); |
389 |
+// node = scm_from_locale_stringn (buff, strlen (buff)); |
390 |
+ node = scm_from_locale_string (buff); |
391 |
rpt = scm_cons (node, rpt); |
392 |
|
393 |
/* Put a data type in the cdr slot */ |
394 |
- node = scm_mem2string ("gtt-daily", 9); |
395 |
+// node = scm_mem2string ("gtt-daily", 9); |
396 |
+// node = scm_from_locale_stringn ("gtt-daily", 9); |
397 |
+ node = scm_from_locale_string ("gtt-daily"); |
398 |
rpt = scm_cons (rpt, node); |
399 |
|
400 |
rc = scm_cons (rpt, rc); |
401 |
@@ -832,7 +853,7 @@ |
402 |
{ \ |
403 |
const char * str = GTT_GETTER (prj); \ |
404 |
if (NULL == str) return SCM_EOL; \ |
405 |
- return scm_mem2string (str, strlen (str)); \ |
406 |
+ return scm_from_locale_string (str); \ |
407 |
} \ |
408 |
RET_PROJECT_SIMPLE(RET_FUNC,GTT_GETTER##_scm) |
409 |
|
410 |
@@ -842,17 +863,17 @@ |
411 |
GTT_GETTER##_scm (GttGhtml *ghtml, GttProject *prj) \ |
412 |
{ \ |
413 |
long i = GTT_GETTER (prj); \ |
414 |
- return scm_long2num (i); \ |
415 |
+ return scm_from_long (i); \ |
416 |
} \ |
417 |
RET_PROJECT_SIMPLE(RET_FUNC,GTT_GETTER##_scm) |
418 |
|
419 |
- \ |
420 |
+ |
421 |
#define RET_PROJECT_ULONG(RET_FUNC,GTT_GETTER) \ |
422 |
static SCM \ |
423 |
GTT_GETTER##_scm (GttGhtml *ghtml, GttProject *prj) \ |
424 |
{ \ |
425 |
unsigned long i = GTT_GETTER (prj); \ |
426 |
- return scm_ulong2num (i); \ |
427 |
+ return scm_from_ulong (i); \ |
428 |
} \ |
429 |
RET_PROJECT_SIMPLE(RET_FUNC,GTT_GETTER##_scm) |
430 |
|
431 |
@@ -885,12 +906,15 @@ |
432 |
g_string_append_printf (str, "<a href=\"gtt:proj:0x%lx\">", (long) prj); |
433 |
g_string_append (str, gtt_project_get_title (prj)); |
434 |
g_string_append (str, "</a>"); |
435 |
- return scm_mem2string (str->str, str->len); |
436 |
+// return scm_mem2string (str->str, str->len); |
437 |
+ return scm_from_locale_stringn (str->str, str->len); |
438 |
} |
439 |
else |
440 |
{ |
441 |
const char * str = gtt_project_get_title (prj); |
442 |
- return scm_mem2string (str, strlen (str)); |
443 |
+// return scm_mem2string (str, strlen (str)); |
444 |
+// return scm_from_locale_stringn (str, strlen (str)); |
445 |
+ return scm_from_locale_string (str); |
446 |
} |
447 |
} |
448 |
|
449 |
@@ -969,7 +993,7 @@ |
450 |
GTT_GETTER##_scm (GttGhtml *ghtml, GttTask *tsk) \ |
451 |
{ \ |
452 |
const char * str = GTT_GETTER (tsk); \ |
453 |
- return scm_mem2string (str, strlen (str)); \ |
454 |
+ return scm_from_locale_stringn (str, strlen (str)); \ |
455 |
} \ |
456 |
\ |
457 |
static SCM \ |
458 |
@@ -997,12 +1021,15 @@ |
459 |
g_string_append_printf (str, "<a href=\"gtt:task:0x%lx\">", (long)tsk); |
460 |
g_string_append (str, gtt_task_get_memo (tsk)); |
461 |
g_string_append (str, "</a>"); |
462 |
- return scm_mem2string (str->str, str->len); |
463 |
+// return scm_mem2string (str->str, str->len); |
464 |
+ return scm_from_locale_stringn (str->str, str->len); |
465 |
} |
466 |
else |
467 |
{ |
468 |
const char * str = gtt_task_get_memo (tsk); |
469 |
- return scm_mem2string (str, strlen (str)); |
470 |
+// return scm_mem2string (str, strlen (str)); |
471 |
+// return scm_from_locale_stringn (str, strlen (str)); |
472 |
+ return scm_from_locale_string (str); |
473 |
} |
474 |
} |
475 |
|
476 |
@@ -1081,7 +1108,9 @@ |
477 |
|
478 |
task_secs = gtt_task_get_secs_ever(tsk); |
479 |
qof_print_hours_elapsed_buff (buff, 100, task_secs, TRUE); |
480 |
- return scm_mem2string (buff, strlen (buff)); |
481 |
+// return scm_mem2string (buff, strlen (buff)); |
482 |
+// return scm_from_locale_stringn (buff, strlen (buff)); |
483 |
+ return scm_from_locale_string (buff); |
484 |
} |
485 |
|
486 |
static SCM |
487 |
@@ -1091,7 +1120,8 @@ |
488 |
|
489 |
time_t task_date = gtt_task_get_secs_earliest(tsk); |
490 |
size_t len = qof_print_date_time_buff (buff, 100, task_date); |
491 |
- return scm_mem2string (buff, len); |
492 |
+// return scm_mem2string (buff, len); |
493 |
+ return scm_from_locale_stringn (buff, len); |
494 |
} |
495 |
|
496 |
static SCM |
497 |
@@ -1101,7 +1131,8 @@ |
498 |
|
499 |
time_t task_date = gtt_task_get_secs_latest(tsk); |
500 |
size_t len = qof_print_date_time_buff (buff, 100, task_date); |
501 |
- return scm_mem2string (buff, len); |
502 |
+// return scm_mem2string (buff, len); |
503 |
+ return scm_from_locale_stringn (buff, len); |
504 |
} |
505 |
|
506 |
static SCM |
507 |
@@ -1127,7 +1158,9 @@ |
508 |
/* hack alert should use i18n currency/monetary printing */ |
509 |
snprintf (buff, 100, "$%.2f", value+0.0049); |
510 |
|
511 |
- return scm_mem2string (buff, strlen (buff)); |
512 |
+// return scm_mem2string (buff, strlen (buff)); |
513 |
+// return scm_from_locale_stringn (buff, strlen (buff)); |
514 |
+ return scm_from_locale_string (buff); |
515 |
} |
516 |
|
517 |
RET_TASK_STR (ret_task_billstatus, task_get_billstatus) |
518 |
@@ -1154,7 +1187,7 @@ |
519 |
GTT_GETTER##_scm (GttGhtml *ghtml, GttInterval *ivl) \ |
520 |
{ \ |
521 |
const char * str = GTT_GETTER (ivl); \ |
522 |
- return scm_mem2string (str, strlen (str)); \ |
523 |
+ return scm_from_locale_stringn (str, strlen (str)); \ |
524 |
} \ |
525 |
RET_IVL_SIMPLE(RET_FUNC,GTT_GETTER) |
526 |
|
527 |
@@ -1164,7 +1197,7 @@ |
528 |
GTT_GETTER##_scm (GttGhtml *ghtml, GttInterval *ivl) \ |
529 |
{ \ |
530 |
unsigned long i = GTT_GETTER (ivl); \ |
531 |
- return scm_ulong2num (i); \ |
532 |
+ return scm_from_ulong (i); \ |
533 |
} \ |
534 |
RET_IVL_SIMPLE(RET_FUNC,GTT_GETTER) |
535 |
|
536 |
@@ -1181,7 +1214,9 @@ |
537 |
elapsed = gtt_interval_get_stop (ivl); |
538 |
elapsed -= gtt_interval_get_start (ivl); |
539 |
qof_print_hours_elapsed_buff (buff, 100, elapsed, TRUE); |
540 |
- return scm_mem2string (buff, strlen (buff)); |
541 |
+// return scm_mem2string (buff, strlen (buff)); |
542 |
+// return scm_from_locale_stringn (buff, strlen (buff)); |
543 |
+ return scm_from_locale_string (buff); |
544 |
} |
545 |
|
546 |
RET_IVL_SIMPLE (ret_ivl_elapsed_str, get_ivl_elapsed_str); |
547 |
@@ -1213,7 +1248,8 @@ |
548 |
g_string_append (str, "</a>"); |
549 |
} |
550 |
|
551 |
- return scm_mem2string (str->str, str->len); |
552 |
+// return scm_mem2string (str->str, str->len); |
553 |
+ return scm_from_locale_stringn (str->str, str->len); |
554 |
} |
555 |
|
556 |
static SCM |
557 |
@@ -1233,7 +1269,7 @@ |
558 |
{ |
559 |
prt_date = qof_is_same_day(start, prev_stop); |
560 |
} |
561 |
- return SCM_BOOL (prt_date); |
562 |
+ return scm_from_bool (prt_date); |
563 |
} |
564 |
RET_IVL_SIMPLE (ret_ivl_same_day_start, get_ivl_same_day_start); |
565 |
|
566 |
@@ -1253,7 +1289,7 @@ |
567 |
{ |
568 |
prt_date = qof_is_same_day(prev_start, stop); |
569 |
} |
570 |
- return SCM_BOOL (prt_date); |
571 |
+ return scm_from_bool (prt_date); |
572 |
} |
573 |
RET_IVL_SIMPLE (ret_ivl_same_day_stop, get_ivl_same_day_stop); |
574 |
|
575 |
@@ -1295,7 +1331,9 @@ |
576 |
char buff[100]; |
577 |
|
578 |
qof_print_hours_elapsed_buff (buff, 100, gtt_interval_get_fuzz (ivl), TRUE); |
579 |
- return scm_mem2string (buff, strlen (buff)); |
580 |
+// return scm_mem2string (buff, strlen (buff)); |
581 |
+// return scm_from_locale_stringn (buff, strlen (buff)); |
582 |
+ return scm_from_locale_string (buff); |
583 |
} |
584 |
RET_IVL_SIMPLE (ret_ivl_fuzz_str, get_ivl_fuzz_str); |
585 |
|
586 |
@@ -1305,16 +1343,17 @@ |
587 |
my_catch_handler (void *data, SCM tag, SCM throw_args) |
588 |
{ |
589 |
printf ("Error: GnoTime caught error during scheme parse\n"); |
590 |
- if (SCM_SYMBOLP(tag)) |
591 |
+ if (scm_is_symbol(tag)) |
592 |
{ |
593 |
- char * str = SCM_SYMBOL_CHARS (tag); |
594 |
+ char * str = scm_to_locale_string (tag); |
595 |
printf ("\tScheme error was: %s\n", str); |
596 |
} |
597 |
scm_backtrace(); |
598 |
|
599 |
- SCM fmt = scm_makfrom0str ("~S"); |
600 |
- SCM s_str = scm_simple_format (SCM_BOOL_F, fmt, SCM_LIST1(throw_args)); |
601 |
- printf ("\tthrow_args=%s\n", SCM_STRING_CHARS (s_str)); |
602 |
+// SCM fmt = scm_makfrom0str ("~S"); |
603 |
+ SCM fmt = scm_from_locale_string ("~S"); |
604 |
+ SCM s_str = scm_simple_format (SCM_BOOL_F, fmt, scm_list_1(throw_args)); |
605 |
+ printf ("\tthrow_args=%s\n", scm_to_locale_string (s_str)); |
606 |
|
607 |
return SCM_EOL; |
608 |
} |
609 |
@@ -1486,7 +1525,10 @@ |
610 |
/* dispatch and handle */ |
611 |
scmstart +=5; |
612 |
// scm_c_eval_string (scmstart); |
613 |
- gh_eval_str_with_catch (scmstart, my_catch_handler); |
614 |
+ //gh_eval_str_with_catch (scmstart, my_catch_handler); |
615 |
+ scm_internal_stack_catch (SCM_BOOL_T, (scm_t_catch_body) scm_c_eval_string, |
616 |
+ scmstart, (scm_t_catch_handler) my_catch_handler, scmstart); |
617 |
+ |
618 |
start = end; |
619 |
continue; |
620 |
} |
621 |
diff -Nru gnotime-2.2.2.orig/src/ghtml-deprecated.c gnotime-2.2.2/src/ghtml-deprecated.c |
622 |
--- gnotime-2.2.2.orig/src/ghtml-deprecated.c 2004-08-27 02:57:00.000000000 +0300 |
623 |
+++ gnotime-2.2.2/src/ghtml-deprecated.c 2007-02-12 20:51:06.000000000 +0200 |
624 |
@@ -719,24 +719,25 @@ |
625 |
decode_scm_col_list (GttGhtml *ghtml, SCM col_list) |
626 |
{ |
627 |
SCM col_name; |
628 |
- int len; |
629 |
+// int len; |
630 |
char * tok = NULL; |
631 |
|
632 |
/* reset the parser */ |
633 |
ghtml->ninvl_cols = 0; |
634 |
ghtml->ntask_cols = 0; |
635 |
|
636 |
- while (FALSE == SCM_NULLP(col_list)) |
637 |
+ while (!scm_is_null (col_list)) |
638 |
{ |
639 |
col_name = SCM_CAR (col_list); |
640 |
|
641 |
/* either a 'symbol or a "quoted string" */ |
642 |
- if (!SCM_SYMBOLP(col_name) && !SCM_STRINGP (col_name)) |
643 |
+ if (!scm_is_symbol(col_name) && !scm_is_string (col_name)) |
644 |
{ |
645 |
col_list = SCM_CDR (col_list); |
646 |
continue; |
647 |
} |
648 |
- tok = gh_scm2newstr (col_name, &len); |
649 |
+// tok = gh_scm2newstr (col_name, &len); |
650 |
+ tok = scm_to_locale_string (col_name); |
651 |
decode_column (ghtml, tok); |
652 |
|
653 |
free (tok); |
654 |
@@ -759,7 +760,7 @@ |
655 |
{ |
656 |
GttGhtml *ghtml = ghtml_guile_global_hack; |
657 |
SCM rc; |
658 |
- SCM_ASSERT ( SCM_CONSP (col_list), col_list, SCM_ARG1, "gtt-show-table"); |
659 |
+ SCM_ASSERT ( scm_is_pair (col_list), col_list, SCM_ARG1, "gtt-show-table"); |
660 |
rc = decode_scm_col_list (ghtml, col_list); |
661 |
do_show_table (ghtml, ghtml->prj, FALSE); |
662 |
return rc; |
663 |
@@ -770,7 +771,7 @@ |
664 |
{ |
665 |
GttGhtml *ghtml = ghtml_guile_global_hack; |
666 |
SCM rc; |
667 |
- SCM_ASSERT ( SCM_CONSP (col_list), col_list, SCM_ARG1, "gtt-show-invoice"); |
668 |
+ SCM_ASSERT ( scm_is_pair (col_list), col_list, SCM_ARG1, "gtt-show-invoice"); |
669 |
rc = decode_scm_col_list (ghtml, col_list); |
670 |
do_show_table (ghtml, ghtml->prj, TRUE); |
671 |
return rc; |
672 |
@@ -782,7 +783,7 @@ |
673 |
GttGhtml *ghtml = ghtml_guile_global_hack; |
674 |
|
675 |
SCM rc; |
676 |
- SCM_ASSERT ( SCM_CONSP (col_list), col_list, SCM_ARG1, "gtt-show-export"); |
677 |
+ SCM_ASSERT ( scm_is_pair (col_list), col_list, SCM_ARG1, "gtt-show-export"); |
678 |
rc = decode_scm_col_list (ghtml, col_list); |
679 |
|
680 |
ghtml->show_html = FALSE; |
681 |
diff -Nru gnotime-2.2.2.orig/src/lib/libqofsql/Makefile.am gnotime-2.2.2/src/lib/libqofsql/Makefile.am |
682 |
--- gnotime-2.2.2.orig/lib/libqofsql/Makefile.am 2005-09-12 20:04:00.000000000 +0300 |
683 |
+++ gnotime-2.2.2/lib/libqofsql/Makefile.am 2007-02-12 20:51:06.000000000 +0200 |
684 |
@@ -59,7 +59,7 @@ |
685 |
|
686 |
sql_parse_test_SOURCES=sql_parse_test.c |
687 |
# sql_parse_test_LDFLAGS = $(LIBGDA_LIBS) |
688 |
-sql_parse_test_DEPENDENCIES = |
689 |
+sql_parse_test_DEPENDENCIES = ./libqofsql.la |
690 |
sql_parse_test_LDADD = ./libqofsql.la @GLIB_LIBS@ |
691 |
|
692 |
tests: sql_parse_test |
693 |
|
694 |
|
695 |
|
696 |
1.1 app-office/gnotime/files/digest-gnotime-2.2.2-r1 |
697 |
|
698 |
file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/app-office/gnotime/files/digest-gnotime-2.2.2-r1?rev=1.1&view=markup |
699 |
plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/app-office/gnotime/files/digest-gnotime-2.2.2-r1?rev=1.1&content-type=text/plain |
700 |
|
701 |
Index: digest-gnotime-2.2.2-r1 |
702 |
=================================================================== |
703 |
MD5 8c05509f57a278de03a97fae110de3f5 gnotime-2.2.2.tar.gz 1365243 |
704 |
RMD160 8b2053e876dda782063b6db7507ac3147bace720 gnotime-2.2.2.tar.gz 1365243 |
705 |
SHA256 c89681d50f13abd626ae2b1ddefcea3ecba0f564ca355f7005de712143fed1aa gnotime-2.2.2.tar.gz 1365243 |
706 |
|
707 |
|
708 |
|
709 |
-- |
710 |
gentoo-commits@g.o mailing list |