1 |
bicatali 08/11/05 22:20:07 |
2 |
|
3 |
Added: ds9-5.4-main.patch ds9-5.4-htmlwidget.patch |
4 |
ds9-5.4-saotk.patch make.gentoo ds9-5.4-src.patch |
5 |
ds9-5.4-gcc43.patch ds9-5.4-fitsy.patch |
6 |
ds9-5.4-makefile.patch |
7 |
Removed: ds9-5.1-tk-gif.patch ds9-5.1-Makefile.patch |
8 |
Log: |
9 |
Version bump. Added a bunch of patches to allow using system libs. |
10 |
(Portage version: 2.2_rc11/cvs/Linux 2.6.25-gentoo-r7 x86_64) |
11 |
|
12 |
Revision Changes Path |
13 |
1.1 sci-astronomy/ds9/files/ds9-5.4-main.patch |
14 |
|
15 |
file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/sci-astronomy/ds9/files/ds9-5.4-main.patch?rev=1.1&view=markup |
16 |
plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/sci-astronomy/ds9/files/ds9-5.4-main.patch?rev=1.1&content-type=text/plain |
17 |
|
18 |
Index: ds9-5.4-main.patch |
19 |
=================================================================== |
20 |
diff -Nur saods9.orig/ds9/ds9.C saods9/ds9/ds9.C |
21 |
--- saods9.orig/ds9/ds9.C 2008-10-08 20:36:37.000000000 +0100 |
22 |
+++ saods9/ds9/ds9.C 2008-11-05 11:03:36.000000000 +0000 |
23 |
@@ -11,8 +11,8 @@ |
24 |
|
25 |
void TclSetStartupScriptFileName(const char*); |
26 |
|
27 |
- int Zvfs_Init(Tcl_Interp*); |
28 |
- int Zvfs_Mount(Tcl_Interp*, char*, char *); |
29 |
+/* int Zvfs_Init(Tcl_Interp*); |
30 |
+ int Zvfs_Mount(Tcl_Interp*, char*, char *);*/ |
31 |
|
32 |
int Blt_Init(Tcl_Interp*); |
33 |
int Tktable_Init(Tcl_Interp*); |
34 |
@@ -64,15 +64,15 @@ |
35 |
appname = dupstr(argv[0]); |
36 |
|
37 |
// set default encoding dir |
38 |
- Tcl_SetDefaultEncodingDir("./zvfsmntpt/tcl8.4"); |
39 |
+ //Tcl_SetDefaultEncodingDir("./zvfsmntpt/tcl8.4"); |
40 |
|
41 |
// so that tcl and tk know where to find their libs |
42 |
// we do it here before InitLibraryPath is called |
43 |
- putenv((char*)"TCL_LIBRARY=./zvfsmntpt/tcl8.4"); |
44 |
- putenv((char*)"TK_LIBRARY=./zvfsmntpt/tk8.4"); |
45 |
+ //putenv((char*)"TCL_LIBRARY=./zvfsmntpt/tcl8.4"); |
46 |
+ //putenv((char*)"TK_LIBRARY=./zvfsmntpt/tk8.4"); |
47 |
|
48 |
// invoke startup script |
49 |
- TclSetStartupScriptFileName("./zvfsmntpt/src/ds9.tcl"); |
50 |
+ TclSetStartupScriptFileName("/usr/share/ds9/src/ds9.tcl"); |
51 |
} |
52 |
|
53 |
Tcl_Interp *global_interp; |
54 |
@@ -91,13 +91,13 @@ |
55 |
// We have to initialize the virtual filesystem before calling |
56 |
// Tcl_Init(). Otherwise, Tcl_Init() will not be able to find |
57 |
// its startup script files. |
58 |
- if (Zvfs_Init(interp) == TCL_ERROR) |
59 |
+/* if (Zvfs_Init(interp) == TCL_ERROR) |
60 |
return TCL_ERROR; |
61 |
Tcl_StaticPackage (interp, "zvfs", Zvfs_Init, |
62 |
(Tcl_PackageInitProc*)NULL); |
63 |
- |
64 |
+*/ |
65 |
// find current working directory, and set as mount point |
66 |
- { |
67 |
+/* { |
68 |
Tcl_DString pwd; |
69 |
Tcl_DStringInit(&pwd); |
70 |
Tcl_GetCwd(interp, &pwd); |
71 |
@@ -113,7 +113,7 @@ |
72 |
#endif |
73 |
Tcl_DStringFree(&pwd); |
74 |
} |
75 |
- |
76 |
+*/ |
77 |
// Initialize Tcl and Tk |
78 |
if (Tcl_Init(interp)) |
79 |
return TCL_ERROR; |
80 |
@@ -121,7 +121,7 @@ |
81 |
// Tk |
82 |
if (Tk_Init(interp)) |
83 |
return TCL_ERROR; |
84 |
- Tcl_StaticPackage(interp,"Tk", Tk_Init, Tk_SafeInit); |
85 |
+ //Tcl_StaticPackage(interp,"Tk", Tk_Init, Tk_SafeInit); |
86 |
|
87 |
{ |
88 |
Tcl_DString pwd; |
89 |
@@ -131,7 +131,7 @@ |
90 |
} |
91 |
|
92 |
// Blt |
93 |
- if (Blt_Init(interp) == TCL_ERROR) |
94 |
+ /*if (Blt_Init(interp) == TCL_ERROR) |
95 |
return TCL_ERROR; |
96 |
Tcl_StaticPackage (interp, "BLT", Blt_Init, |
97 |
(Tcl_PackageInitProc*)NULL); |
98 |
@@ -140,7 +140,7 @@ |
99 |
if (Tktable_Init(interp) == TCL_ERROR) |
100 |
return TCL_ERROR; |
101 |
Tcl_StaticPackage (interp, "Tktable", Tktable_Init, |
102 |
- (Tcl_PackageInitProc*)NULL); |
103 |
+ (Tcl_PackageInitProc*)NULL); */ |
104 |
|
105 |
// Checkdns |
106 |
if (Checkdns_Init(interp) == TCL_ERROR) |
107 |
@@ -161,10 +161,10 @@ |
108 |
(Tcl_PackageInitProc*)NULL); |
109 |
|
110 |
// Tclxpa |
111 |
- if (Tclxpa_Init(interp) == TCL_ERROR) |
112 |
+/* if (Tclxpa_Init(interp) == TCL_ERROR) |
113 |
return TCL_ERROR; |
114 |
Tcl_StaticPackage (interp, "Tclxpa", Tclxpa_Init, |
115 |
- (Tcl_PackageInitProc*)NULL); |
116 |
+ (Tcl_PackageInitProc*)NULL);*/ |
117 |
|
118 |
// IIS |
119 |
if (Iis_Init(interp) == TCL_ERROR) |
120 |
@@ -179,7 +179,7 @@ |
121 |
(Tcl_PackageInitProc*)NULL); |
122 |
|
123 |
// Tkimg |
124 |
- if (Tkimg_Init(interp) == TCL_ERROR) |
125 |
+/* if (Tkimg_Init(interp) == TCL_ERROR) |
126 |
return TCL_ERROR; |
127 |
Tcl_StaticPackage (interp, "img", |
128 |
Tkimg_Init,(Tcl_PackageInitProc*)NULL); |
129 |
@@ -254,7 +254,7 @@ |
130 |
if (Tkimgwindow_Init(interp) == TCL_ERROR) |
131 |
return TCL_ERROR; |
132 |
Tcl_StaticPackage (interp, "window", Tkimgwindow_Init, |
133 |
- (Tcl_PackageInitProc*)NULL); |
134 |
+ (Tcl_PackageInitProc*)NULL);*/ |
135 |
|
136 |
#ifdef _MACOSX |
137 |
if (Tkmacosx_Init(interp) == TCL_ERROR) |
138 |
@@ -271,11 +271,11 @@ |
139 |
#endif |
140 |
|
141 |
// Variables |
142 |
- Tcl_SetVar(interp, "auto_path", "./zvfsmntpt/tcl8.4 ./zvfsmntpt/tk8.4 ./zvfsmntpt/blt2.4 ./zvfsmntpt/tcllib1.6 ./zvfsmntpt/src", TCL_GLOBAL_ONLY); |
143 |
+/* Tcl_SetVar(interp, "auto_path", "./zvfsmntpt/tcl8.4 ./zvfsmntpt/tk8.4 ./zvfsmntpt/blt2.4 ./zvfsmntpt/tcllib1.6 ./zvfsmntpt/src", TCL_GLOBAL_ONLY); |
144 |
Tcl_SetVar(interp, "tcl_libPath", "./zvfsmntpt/tcl8.4", TCL_GLOBAL_ONLY); |
145 |
Tcl_SetVar(interp, "blt_library", "./zvfsmntpt/blt2.4", TCL_GLOBAL_ONLY); |
146 |
Tcl_SetVar(interp, "blt_libPath", "./zvfsmntpt/blt2.4", TCL_GLOBAL_ONLY); |
147 |
- Tcl_SetVar2(interp, "env", "TK_TABLE_LIBRARY", "", TCL_GLOBAL_ONLY); |
148 |
+ Tcl_SetVar2(interp, "env", "TK_TABLE_LIBRARY", "", TCL_GLOBAL_ONLY);*/ |
149 |
|
150 |
//Tcl_SetVar(interp, "tcl_rcFileName", "~/.wishrc", TCL_GLOBAL_ONLY); |
151 |
|
152 |
diff -Nur saods9.orig/ds9/Makefile saods9/ds9/Makefile |
153 |
--- saods9.orig/ds9/Makefile 2008-10-08 20:36:37.000000000 +0100 |
154 |
+++ saods9/ds9/Makefile 2008-11-05 11:13:15.000000000 +0000 |
155 |
@@ -4,12 +4,7 @@ |
156 |
#--------------------------defines |
157 |
|
158 |
ZDIR = zipdir/zvfsmntpt |
159 |
-FILES = $(ZDIR)/$(TCLVER) \ |
160 |
- $(ZDIR)/$(TKVER) \ |
161 |
- $(ZDIR)/$(BLTVER) \ |
162 |
- $(ZDIR)/$(TCLLIBVER) \ |
163 |
- $(ZDIR)/$(TKCONVER) \ |
164 |
- $(ZDIR)/src \ |
165 |
+FILES = $(ZDIR)/src \ |
166 |
$(ZDIR)/msgs \ |
167 |
$(ZDIR)/doc \ |
168 |
$(ZDIR)/template |
169 |
@@ -22,37 +17,13 @@ |
170 |
../lib/libsaotk.a \ |
171 |
../lib/libtkhtml.a \ |
172 |
../lib/libtkmpeg.a \ |
173 |
- ../lib/$(TKIMGVER)/libtkimgwindow1.3.a \ |
174 |
- ../lib/$(TKIMGVER)/libtkimgjpeg1.3.a \ |
175 |
- ../lib/$(TKIMGVER)/libjpegtcl1.0.a \ |
176 |
- ../lib/$(TKIMGVER)/libtkimgtiff1.3.a \ |
177 |
- ../lib/$(TKIMGVER)/libtifftcl3.6.1.a \ |
178 |
- ../lib/$(TKIMGVER)/libtkimgpng1.3.a \ |
179 |
- ../lib/$(TKIMGVER)/libpngtcl1.2.6.a \ |
180 |
- ../lib/$(TKIMGVER)/libtkimgppm1.3.a \ |
181 |
- ../lib/$(TKIMGVER)/libtkimggif1.3.a \ |
182 |
- ../lib/$(TKIMGVER)/libtkimgbmp1.3.a \ |
183 |
- ../lib/$(TKIMGVER)/libtkimgxbm1.3.a \ |
184 |
- ../lib/$(TKIMGVER)/libzlibtcl1.2.1.a \ |
185 |
- ../lib/$(TKIMGVER)/libtkimg1.3.a \ |
186 |
- ../lib/$(TKTABLEVER)/libTktable2.9.a \ |
187 |
- ../lib/libfuntools.a \ |
188 |
../lib/librice.a \ |
189 |
../lib/libhcomp.a \ |
190 |
../lib/libplio.a \ |
191 |
- ../lib/libast.a \ |
192 |
../lib/libsaotk.a \ |
193 |
- ../lib/libwcs.a \ |
194 |
../lib/libsla.a \ |
195 |
- ../lib/libzvfs.a \ |
196 |
- ../lib/libzip.a \ |
197 |
- ../lib/libz.a \ |
198 |
- ../lib/libxpa.a \ |
199 |
../lib/libiis.a \ |
200 |
- ../lib/libcheckdns.a \ |
201 |
- ../lib/libBLT24.a \ |
202 |
- ../lib/libtk8.4.a \ |
203 |
- ../lib/libtcl8.4.a |
204 |
+ ../lib/libcheckdns.a |
205 |
endif |
206 |
|
207 |
ifeq ($(OS),windows) |
208 |
@@ -167,14 +138,9 @@ |
209 |
ds9.zip : $(FILES) |
210 |
cd zipdir; zip -r9 ../ds9.zip * |
211 |
else |
212 |
-ds9 : null.zip ds9Base $(FILES) |
213 |
+ds9 : ds9Base $(FILES) |
214 |
$(RM) $@ |
215 |
- cp ds9Base ds9.zip |
216 |
- $(STRIP) ds9.zip |
217 |
- cat null.zip >> ds9.zip |
218 |
- cd zipdir; zip -rA9 ../ds9.zip * |
219 |
- mv ds9.zip ds9 |
220 |
- cp ds9 ../bin/. |
221 |
+ cp ds9Base ../bin/ds9 |
222 |
|
223 |
debug : null.zip ds9Base $(FILES) |
224 |
$(RM) $@ |
225 |
@@ -366,6 +332,20 @@ |
226 |
rm -f libstdc++.a |
227 |
endif |
228 |
|
229 |
+# For gentoo |
230 |
+ifeq ($(ARCH),gentoo) |
231 |
+ds9Base : $(OBJS) $(LIBS) |
232 |
+ $(RM) $@ |
233 |
+ $(CXX) ${OPTS} \ |
234 |
+ -o $@ $(OBJS) $(LIBS)\ |
235 |
+ -L$(X11LIB) -lX11 \ |
236 |
+ -ldl -lpthread \ |
237 |
+ -ltk -ltcl -lBLT24 \ |
238 |
+ -lfuntools `pkg-config --libs wcstools` -lz \ |
239 |
+ `ast_link` |
240 |
+endif |
241 |
+ |
242 |
+ |
243 |
#--------------------------linux |
244 |
|
245 |
ifneq (,$(findstring linux,$(ARCH))) |
246 |
|
247 |
|
248 |
|
249 |
1.1 sci-astronomy/ds9/files/ds9-5.4-htmlwidget.patch |
250 |
|
251 |
file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/sci-astronomy/ds9/files/ds9-5.4-htmlwidget.patch?rev=1.1&view=markup |
252 |
plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/sci-astronomy/ds9/files/ds9-5.4-htmlwidget.patch?rev=1.1&content-type=text/plain |
253 |
|
254 |
Index: ds9-5.4-htmlwidget.patch |
255 |
=================================================================== |
256 |
--- saods9.orig/htmlwidget/configure 2006-05-01 19:47:09.000000000 +0200 |
257 |
+++ saods9/htmlwidget/configure 2008-03-08 16:36:40.000000000 +0100 |
258 |
@@ -1052,11 +1052,11 @@ |
259 |
echo "$ac_t""$BUILD_TCLSH" 1>&6 |
260 |
else |
261 |
if test "$with_tcl" != ""; then |
262 |
- if test -x "$with_tcl/$tclsubdir/tclsh"; then |
263 |
- BUILD_TCLSH=$with_tcl/$tclsubdir/tclsh |
264 |
+ if test -x "$with_tcl/tclsh"; then |
265 |
+ BUILD_TCLSH=$with_tcl/tclsh |
266 |
else |
267 |
- if test -x "$with_tcl/$tclsubdir/tclsh8.0"; then |
268 |
- BUILD_TCLSH=$with_tcl/$tclsubdir/tclsh8.0 |
269 |
+ if test -x "$with_tcl/tclsh8.0"; then |
270 |
+ BUILD_TCLSH=$with_tcl/tclsh8.0 |
271 |
fi |
272 |
fi |
273 |
fi |
274 |
@@ -1137,7 +1137,7 @@ |
275 |
if test "$enable_shared" = "yes"; then |
276 |
ok=0 |
277 |
if test "$with_tcl" != ""; then |
278 |
- tclconf=$with_tcl/unix/tclConfig.sh |
279 |
+ tclconf=$with_tcl/tclConfig.sh |
280 |
|
281 |
ac_safe=`echo "$tclconf" | sed 'y%./+-%__p_%'` |
282 |
echo $ac_n "checking for $tclconf""... $ac_c" 1>&6 |
283 |
@@ -1494,7 +1494,7 @@ |
284 |
TARGET_TCL_LIBS="$config_TARGET_TCL_LIBS" |
285 |
else |
286 |
if test "$with_tcl" != ""; then |
287 |
- extra=`echo $with_tcl/$tclsubdir/libtcl8*.a` |
288 |
+ extra=`echo -ltcl` |
289 |
fi |
290 |
CC=$TARGET_CC |
291 |
echo $ac_n "checking for sin""... $ac_c" 1>&6 |
292 |
--- saods9.orig/htmlwidget/src/htmlcmd.c 2002-06-20 22:19:33.000000000 +0100 |
293 |
+++ saods9/htmlwidget/src/htmlcmd.c 2008-11-05 12:31:11.000000000 +0000 |
294 |
@@ -23,6 +23,7 @@ |
295 |
** drh@×××.org |
296 |
** http://www.hwaci.com/drh/ |
297 |
*/ |
298 |
+#include <string.h> |
299 |
#include <tk.h> |
300 |
#include <stdlib.h> |
301 |
#include "htmlcmd.h" |
302 |
|
303 |
|
304 |
|
305 |
1.1 sci-astronomy/ds9/files/ds9-5.4-saotk.patch |
306 |
|
307 |
file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/sci-astronomy/ds9/files/ds9-5.4-saotk.patch?rev=1.1&view=markup |
308 |
plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/sci-astronomy/ds9/files/ds9-5.4-saotk.patch?rev=1.1&content-type=text/plain |
309 |
|
310 |
Index: ds9-5.4-saotk.patch |
311 |
=================================================================== |
312 |
diff -Nur saods9.orig/saotk/fitsy++/Makefile saods9/saotk/fitsy++/Makefile |
313 |
--- saods9.orig/saotk/fitsy++/Makefile 2007-12-28 22:07:11.000000000 +0000 |
314 |
+++ saods9/saotk/fitsy++/Makefile 2008-11-03 23:06:28.000000000 +0000 |
315 |
@@ -3,8 +3,8 @@ |
316 |
|
317 |
CXXFLAGS = $(CXXOPT) -I. -I.. -I../vector -I../util \ |
318 |
-I../../include -I$(X11INCLUDE) \ |
319 |
- -I../../$(FUNTOOLSDIR)/filter -I../../$(FUNTOOLSDIR)/fitsy \ |
320 |
- -I../../$(FUNTOOLSDIR)/util |
321 |
+ -I/usr/include/funtools/filter -I/usr/include/funtools/fitsy \ |
322 |
+ -I/usr/include/funtools/util -I/usr/include/wcs |
323 |
|
324 |
SS = \ |
325 |
alloc.C \ |
326 |
diff -Nur saods9.orig/saotk/frame/Makefile saods9/saotk/frame/Makefile |
327 |
--- saods9.orig/saotk/frame/Makefile 2008-09-23 20:47:09.000000000 +0100 |
328 |
+++ saods9/saotk/frame/Makefile 2008-11-03 23:11:01.000000000 +0000 |
329 |
@@ -4,8 +4,7 @@ |
330 |
CXXFLAGS = $(CXXOPT) -w \ |
331 |
-I. -I.. -I../widget -I../vector -I../list -I../fitsy++ -I../util \ |
332 |
-I../../include -I$(X11INCLUDE) \ |
333 |
- -I../../$(FUNTOOLSDIR)/util \ |
334 |
- -I../../$(ASTDIR) |
335 |
+ -I/usr/include/funtools/util |
336 |
|
337 |
SS = \ |
338 |
annulus.C \ |
339 |
diff -Nur saods9.orig/saotk/util/tkpostscript.h saods9/saotk/util/tkpostscript.h |
340 |
--- saods9.orig/saotk/util/tkpostscript.h 2008-02-20 22:26:21.000000000 +0000 |
341 |
+++ saods9/saotk/util/tkpostscript.h 2008-11-04 09:58:00.000000000 +0000 |
342 |
@@ -4,7 +4,7 @@ |
343 |
|
344 |
// this is copied from tkCanvPs.c |
345 |
|
346 |
-#include "../../tk8.4.18/generic/tkCanvas.h" |
347 |
+#include </usr/lib/tk8.4/include/generic/tkCanvas.h> |
348 |
|
349 |
typedef struct TkPostscriptInfo { |
350 |
int x, y, width, height; /* Area to print, in canvas pixel |
351 |
diff -Nur saods9.orig/saotk/widget/ps.h saods9/saotk/widget/ps.h |
352 |
--- saods9.orig/saotk/widget/ps.h 2008-01-04 17:29:27.000000000 +0000 |
353 |
+++ saods9/saotk/widget/ps.h 2008-11-04 09:59:00.000000000 +0000 |
354 |
@@ -13,7 +13,7 @@ |
355 |
#include "zlib.h" |
356 |
extern int DebugGZ; |
357 |
|
358 |
-#if defined( __alpha) || defined(__mips64) || defined(__sparcv9) || defined(__M64) |
359 |
+#if defined( __alpha) || defined(__mips64) || defined(__sparcv9) || defined(__M64) || defined(__LP64__) |
360 |
#define BIT32 int |
361 |
#else |
362 |
#define BIT32 long |
363 |
diff -ur saods9.orig/saotk/frame/fitsimage.C saods9/saotk/frame/fitsimage.C |
364 |
--- saods9.orig/saotk/frame/fitsimage.C 2007-05-22 20:36:50.000000000 +0200 |
365 |
+++ saods9/saotk/frame/fitsimage.C 2008-11-04 16:36:40.000000000 +0100 |
366 |
@@ -31,7 +31,99 @@ |
367 |
// this is kluge to speed up doug minks wcssubs 'ksearch' routine |
368 |
extern "C" { |
369 |
FitsHead* wcshead = NULL; |
370 |
- char* ksearchh(char*, char*); |
371 |
+ char* ksearchh(char* hstring, char* keyword) |
372 |
+ { |
373 |
+/* Find entry for keyword keyword in FITS header string hstring. |
374 |
+ (the keyword may have a maximum of eight letters) |
375 |
+ NULL is returned if the keyword is not found */ |
376 |
+ |
377 |
+/* char *hstring; character string containing fits-style header |
378 |
+ information in the format <keyword>= <value> {/ <comment>} |
379 |
+ the default is that each entry is 80 characters long; |
380 |
+ however, lines may be of arbitrary length terminated by |
381 |
+ nulls, carriage returns or linefeeds, if packed is true. */ |
382 |
+/*char *keyword; character string containing the name of the variable |
383 |
+ to be returned. ksearch searches for a line beginning |
384 |
+ with this string. The string may be a character |
385 |
+ literal or a character variable terminated by a null |
386 |
+ or '$'. it is truncated to 8 characters. */ |
387 |
+{ |
388 |
+ char *loc, *headnext, *headlast, *pval, *lc, *line; |
389 |
+ int icol, nextchar, lkey, nleft, lhead, lmax; |
390 |
+ |
391 |
+#ifdef USE_SAOLIB |
392 |
+ int iel=1, ip=1, nel, np, ier; |
393 |
+ char *get_fits_head_str(); |
394 |
+ |
395 |
+ if( !use_saolib ){ |
396 |
+#endif |
397 |
+ |
398 |
+ pval = 0; |
399 |
+static int lhead0 = 0; |
400 |
+/* Find current length of header string */ |
401 |
+ if (lhead0) |
402 |
+ lmax = lhead0; |
403 |
+ else |
404 |
+ lmax = 256000; |
405 |
+ for (lhead = 0; lhead < lmax; lhead++) { |
406 |
+ if (hstring[lhead] == (char) 0) |
407 |
+ break; |
408 |
+ } |
409 |
+ |
410 |
+/* Search header string for variable name */ |
411 |
+ headlast = hstring + lhead; |
412 |
+ headnext = hstring; |
413 |
+ pval = NULL; |
414 |
+ while (headnext < headlast) { |
415 |
+ nleft = headlast - headnext; |
416 |
+ loc = strncsrch (headnext, keyword, nleft); |
417 |
+ |
418 |
+ /* Exit if keyword is not found */ |
419 |
+ if (loc == NULL) { |
420 |
+ break; |
421 |
+ } |
422 |
+ |
423 |
+ icol = (loc - hstring) % 80; |
424 |
+ lkey = strlen (keyword); |
425 |
+ nextchar = (int) *(loc + lkey); |
426 |
+ |
427 |
+ /* If this is not in the first 8 characters of a line, keep searching */ |
428 |
+ if (icol > 7) |
429 |
+ headnext = loc + 1; |
430 |
+ |
431 |
+ /* If parameter name in header is longer, keep searching */ |
432 |
+ else if (nextchar != 61 && nextchar > 32 && nextchar < 127) |
433 |
+ headnext = loc + 1; |
434 |
+ |
435 |
+ /* If preceeding characters in line are not blanks, keep searching */ |
436 |
+ else { |
437 |
+ line = loc - icol; |
438 |
+ for (lc = line; lc < loc; lc++) { |
439 |
+ if (*lc != ' ') |
440 |
+ headnext = loc + 1; |
441 |
+ } |
442 |
+ |
443 |
+ /* Return pointer to start of line if match */ |
444 |
+ if (loc >= headnext) { |
445 |
+ pval = line; |
446 |
+ break; |
447 |
+ } |
448 |
+ } |
449 |
+ } |
450 |
+/* Return pointer to calling program */ |
451 |
+ return (pval); |
452 |
+ |
453 |
+#ifdef USE_SAOLIB |
454 |
+ } |
455 |
+ else { |
456 |
+ if (get_fits_head_str(keyword,iel,ip,&nel,&np,&ier,hstring) != NULL) |
457 |
+ return(hstring); |
458 |
+ else |
459 |
+ return(NULL); |
460 |
+ } |
461 |
+#endif |
462 |
+} |
463 |
+} |
464 |
|
465 |
char* findit(char* cards, char* key) |
466 |
{ |
467 |
|
468 |
|
469 |
|
470 |
1.1 sci-astronomy/ds9/files/make.gentoo |
471 |
|
472 |
file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/sci-astronomy/ds9/files/make.gentoo?rev=1.1&view=markup |
473 |
plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/sci-astronomy/ds9/files/make.gentoo?rev=1.1&content-type=text/plain |
474 |
|
475 |
Index: make.gentoo |
476 |
=================================================================== |
477 |
OS = unix |
478 |
ARCH = gentoo |
479 |
|
480 |
X11INCLUDE=/usr/include |
481 |
X11LIB = $(LIBDIR) |
482 |
MYLIBDIR = $(LIBDIR) |
483 |
|
484 |
CXXOPT = ${OPTS} -fPIC -DHAVE_SYS_UN_H -DHAVE_SYS_SHM_H ${EXTRA_CPPFLAGS} |
485 |
CCOPT = ${OPTS} -fPIC -DHAVE_SYS_UN_H -DHAVE_SYS_SHM_H ${EXTRA_CPPFLAGS} |
486 |
|
487 |
|
488 |
|
489 |
1.1 sci-astronomy/ds9/files/ds9-5.4-src.patch |
490 |
|
491 |
file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/sci-astronomy/ds9/files/ds9-5.4-src.patch?rev=1.1&view=markup |
492 |
plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/sci-astronomy/ds9/files/ds9-5.4-src.patch?rev=1.1&content-type=text/plain |
493 |
|
494 |
Index: ds9-5.4-src.patch |
495 |
=================================================================== |
496 |
diff -Nur saods9.orig/src/ds9.tcl saods9/src/ds9.tcl |
497 |
--- saods9/src/ds9.tcl 2008-04-09 17:35:48.000000000 +0200 |
498 |
+++ saods9.new/src/ds9.tcl 2008-11-03 16:13:55.000000000 +0200 |
499 |
@@ -68,24 +68,34 @@ |
500 |
# initialize, depending on how we are running: choices are zvfs, or wish |
501 |
# for now, its not possible to change the current work directory since |
502 |
# all of the paths are relative |
503 |
-if {![catch {package present zvfs}]} { |
504 |
- set ds9(root) "zvfsmntpt" |
505 |
+if {![catch {package present checkdns}]} { |
506 |
+ set ds9(root) "/usr/share/ds9" |
507 |
|
508 |
- source $ds9(root)/tcl8.4/msgcat1.3/msgcat.tcl |
509 |
- source $ds9(root)/tcl8.4/http2.5/http.tcl |
510 |
+ package require msgcat |
511 |
+ package require http |
512 |
|
513 |
- source $ds9(root)/tk8.4/tearoff.tcl |
514 |
+ |
515 |
|
516 |
- source $ds9(root)/tcllib1.10/base64/base64.tcl |
517 |
- source $ds9(root)/tcllib1.10/log/log.tcl |
518 |
- source $ds9(root)/tcllib1.10/ftp/ftp.tcl |
519 |
- source $ds9(root)/tcllib1.10/textutil/repeat.tcl |
520 |
- source $ds9(root)/tcllib1.10/textutil/tabify.tcl |
521 |
+ package require base64 |
522 |
+ package require log |
523 |
+ package require ftp |
524 |
+ package require textutil::repeat |
525 |
+ package require textutil::tabify |
526 |
|
527 |
- source $ds9(root)/tkcon2.5/tkcon.tcl |
528 |
+ package require tkcon |
529 |
|
530 |
- source $ds9(root)/blt2.4/graph.tcl |
531 |
- source $ds9(root)/blt2.4/tabset.tcl |
532 |
+ package require BLT |
533 |
+ package require Tktable |
534 |
+ package require tclxpa |
535 |
+ package require img::base |
536 |
+ package require img::jpeg |
537 |
+ package require img::tiff |
538 |
+ package require img::png |
539 |
+ package require img::gif |
540 |
+ package require img::ppm |
541 |
+ package require img::bmp |
542 |
+ package require img::xbm |
543 |
+ package require img::window |
544 |
|
545 |
source $ds9(root)/src/source.tcl |
546 |
|
547 |
|
548 |
|
549 |
|
550 |
1.1 sci-astronomy/ds9/files/ds9-5.4-gcc43.patch |
551 |
|
552 |
file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/sci-astronomy/ds9/files/ds9-5.4-gcc43.patch?rev=1.1&view=markup |
553 |
plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/sci-astronomy/ds9/files/ds9-5.4-gcc43.patch?rev=1.1&content-type=text/plain |
554 |
|
555 |
Index: ds9-5.4-gcc43.patch |
556 |
=================================================================== |
557 |
diff -Nur saods9.orig/ds9/ds9.C saods9/ds9/ds9.C |
558 |
--- saods9.orig/ds9/ds9.C 2008-10-08 20:36:37.000000000 +0100 |
559 |
+++ saods9/ds9/ds9.C 2008-11-04 11:46:44.000000000 +0000 |
560 |
@@ -1,5 +1,7 @@ |
561 |
#include <iostream> |
562 |
#include <sstream> |
563 |
+#include <cstring> |
564 |
+#include <cstdlib> |
565 |
using namespace std; |
566 |
|
567 |
#include <tcl.h> |
568 |
diff -Nur saods9.orig/iis/iistcl.C saods9/iis/iistcl.C |
569 |
--- saods9.orig/iis/iistcl.C 2008-06-02 22:27:50.000000000 +0100 |
570 |
+++ saods9/iis/iistcl.C 2008-11-04 11:45:29.000000000 +0000 |
571 |
@@ -7,6 +7,7 @@ |
572 |
|
573 |
#include <iostream> |
574 |
#include <sstream> |
575 |
+#include <cstdlib> |
576 |
using namespace std; |
577 |
|
578 |
#include <tcl.h> |
579 |
diff -Nur saods9.orig/saotk/fitsy++/card.C saods9/saotk/fitsy++/card.C |
580 |
--- saods9.orig/saotk/fitsy++/card.C 2008-01-04 17:29:24.000000000 +0000 |
581 |
+++ saods9/saotk/fitsy++/card.C 2008-11-04 11:45:29.000000000 +0000 |
582 |
@@ -3,6 +3,7 @@ |
583 |
// For conditions of distribution and use, see copyright notice in "copyright" |
584 |
|
585 |
#include "card.h" |
586 |
+#include <string.h> |
587 |
|
588 |
FitsCard::FitsCard() |
589 |
{ |
590 |
diff -Nur saods9.orig/saotk/fitsy++/compress.C saods9/saotk/fitsy++/compress.C |
591 |
--- saods9.orig/saotk/fitsy++/compress.C 2008-06-05 21:37:51.000000000 +0100 |
592 |
+++ saods9/saotk/fitsy++/compress.C 2008-11-04 11:45:29.000000000 +0000 |
593 |
@@ -6,6 +6,7 @@ |
594 |
#include "head.h" |
595 |
#include "util.h" |
596 |
#include "NaN.h" |
597 |
+#include <string.h> |
598 |
|
599 |
FitsCompress::FitsCompress(FitsFile* fits) |
600 |
{ |
601 |
diff -Nur saods9.orig/saotk/fitsy++/file.C saods9/saotk/fitsy++/file.C |
602 |
--- saods9.orig/saotk/fitsy++/file.C 2008-06-03 15:46:25.000000000 +0100 |
603 |
+++ saods9/saotk/fitsy++/file.C 2008-11-04 11:45:29.000000000 +0000 |
604 |
@@ -6,6 +6,7 @@ |
605 |
#include <sstream> |
606 |
#include <iomanip> |
607 |
using namespace std; |
608 |
+#include <string.h> |
609 |
|
610 |
#include "file.h" |
611 |
#include "util.h" |
612 |
diff -Nur saods9.orig/saotk/fitsy++/iis.C saods9/saotk/fitsy++/iis.C |
613 |
--- saods9.orig/saotk/fitsy++/iis.C 2008-01-04 17:29:24.000000000 +0000 |
614 |
+++ saods9/saotk/fitsy++/iis.C 2008-11-04 11:45:29.000000000 +0000 |
615 |
@@ -3,6 +3,7 @@ |
616 |
// For conditions of distribution and use, see copyright notice in "copyright" |
617 |
|
618 |
#include "iis.h" |
619 |
+#include <string.h> |
620 |
|
621 |
FitsIIS::FitsIIS(int width, int height) |
622 |
{ |
623 |
diff -Nur saods9.orig/saotk/frame/frscale.C saods9/saotk/frame/frscale.C |
624 |
--- saods9.orig/saotk/frame/frscale.C 2008-01-04 17:29:26.000000000 +0000 |
625 |
+++ saods9/saotk/frame/frscale.C 2008-11-04 11:45:37.000000000 +0000 |
626 |
@@ -3,6 +3,7 @@ |
627 |
// For conditions of distribution and use, see copyright notice in "copyright" |
628 |
|
629 |
#include <string.h> |
630 |
+#include <stdlib.h> |
631 |
|
632 |
#include "frscale.h" |
633 |
|
634 |
diff -Nur saods9.orig/saotk/widget/ps.C saods9/saotk/widget/ps.C |
635 |
--- saods9.orig/saotk/widget/ps.C 2008-06-03 15:46:25.000000000 +0100 |
636 |
+++ saods9/saotk/widget/ps.C 2008-11-04 11:52:06.000000000 +0000 |
637 |
@@ -4,7 +4,8 @@ |
638 |
|
639 |
#include "ps.h" |
640 |
#include "util.h" |
641 |
-#include "string.h" |
642 |
+#include <cstring> |
643 |
+using std::memcpy; |
644 |
|
645 |
Filter::Filter() |
646 |
{ |
647 |
--- saods9.orig/saotk/colorbar/colorbarbase.C 2008-09-26 22:54:36.000000000 +0100 |
648 |
+++ saods9/saotk/colorbar/colorbarbase.C 2008-11-04 18:10:13.000000000 +0000 |
649 |
@@ -10,6 +10,7 @@ |
650 |
|
651 |
#include <X11/Xlib.h> |
652 |
#include <X11/Xutil.h> |
653 |
+#include <cstdlib> |
654 |
|
655 |
#include "parser.H" |
656 |
|
657 |
|
658 |
|
659 |
|
660 |
1.1 sci-astronomy/ds9/files/ds9-5.4-fitsy.patch |
661 |
|
662 |
file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/sci-astronomy/ds9/files/ds9-5.4-fitsy.patch?rev=1.1&view=markup |
663 |
plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/sci-astronomy/ds9/files/ds9-5.4-fitsy.patch?rev=1.1&content-type=text/plain |
664 |
|
665 |
Index: ds9-5.4-fitsy.patch |
666 |
=================================================================== |
667 |
--- saods9.orig/saotk/fitsy++/Makefile 2007-12-28 22:07:11.000000000 +0000 |
668 |
+++ saods9/saotk/fitsy++/Makefile 2008-11-03 23:06:28.000000000 +0000 |
669 |
@@ -3,8 +3,8 @@ |
670 |
|
671 |
CXXFLAGS = $(CXXOPT) -I. -I.. -I../vector -I../util \ |
672 |
-I../../include -I$(X11INCLUDE) \ |
673 |
- -I../../$(FUNTOOLSDIR)/filter -I../../$(FUNTOOLSDIR)/fitsy \ |
674 |
- -I../../$(FUNTOOLSDIR)/util |
675 |
+ -I/usr/include/funtools/filter -I/usr/include/funtools/fitsy \ |
676 |
+ -I/usr/include/funtools/util -I/usr/include/wcs |
677 |
|
678 |
SS = \ |
679 |
alloc.C \ |
680 |
|
681 |
|
682 |
|
683 |
1.1 sci-astronomy/ds9/files/ds9-5.4-makefile.patch |
684 |
|
685 |
file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/sci-astronomy/ds9/files/ds9-5.4-makefile.patch?rev=1.1&view=markup |
686 |
plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/sci-astronomy/ds9/files/ds9-5.4-makefile.patch?rev=1.1&content-type=text/plain |
687 |
|
688 |
Index: ds9-5.4-makefile.patch |
689 |
=================================================================== |
690 |
--- saods9.orig/Makefile 2008-10-08 20:53:46.000000000 +0100 |
691 |
+++ saods9/Makefile 2008-11-04 10:30:52.000000000 +0000 |
692 |
@@ -35,8 +35,7 @@ |
693 |
--with-tk=$(root)/$(TKDIRDIR) $(XFLAGS) |
694 |
XPAFLAGS = --prefix $(root) --with-tcl=$(root)/$(TCLDIRDIR) \ |
695 |
$(XFLAGS) |
696 |
- HTMLFLAGS = --prefix $(root) --with-tcl=$(root)/$(TCLDIR) \ |
697 |
- --with-tk=$(root)/$(TKDIR) $(XFLAGS) |
698 |
+ HTMLFLAGS = --prefix $(root) $(XFLAGS) |
699 |
FUNTOOLSFLAGS = --prefix $(root) --with-zlib=../../lib/libz.a \ |
700 |
--with-wcslib=../lib/libwcs.a --enable-mainlib |
701 |
endif |
702 |
@@ -199,11 +198,8 @@ |
703 |
all : build |
704 |
|
705 |
build : dirs \ |
706 |
- tcl tk \ |
707 |
- tktable tcllib tkcon blt \ |
708 |
- zlib \ |
709 |
- tkimg tkmpeg html xpa iis checkdns \ |
710 |
- funtools sla ast wcssubs rice hcompress plio $(OPTDIR) saotk zip zvfs ds9 |
711 |
+ tkmpeg html iis checkdns \ |
712 |
+ sla rice hcompress plio $(OPTDIR) saotk ds9 |
713 |
|
714 |
doc : FORCE |
715 |
@echo "Making Documentation..." |