[Debian-astro-commits] [saods9] 01/02: Use tkblt instead of BLT
Ole Streicher
olebole at moszumanska.debian.org
Thu Jun 16 14:45:59 UTC 2016
This is an automated email from the git hooks/post-receive script.
olebole pushed a commit to branch experimental
in repository saods9.
commit 06f28541359636dc44402b0e5e7dd21e78c6282e
Author: Ole Streicher <olebole at debian.org>
Date: Thu Jun 16 16:23:44 2016 +0200
Use tkblt instead of BLT
---
debian/changelog | 6 ++
debian/control | 8 +-
debian/patches/ds9_support_blt.patch | 162 ----------------------------
debian/patches/ds9_use_system_libs.patch | 2 +-
debian/patches/ds9_use_tcltk_packages.patch | 2 +-
debian/patches/saotk_fix_blt_crash.patch | 84 ---------------
debian/patches/saotk_use_system_libs.patch | 10 +-
debian/patches/saotk_use_tkblt.patch | 57 ++++++++++
debian/patches/series | 3 +-
9 files changed, 79 insertions(+), 255 deletions(-)
diff --git a/debian/changelog b/debian/changelog
index 1c1c590..155cf14 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,9 @@
+saods9 (7.5~b1+repack1-2) UNRELEASED; urgency=medium
+
+ * Use tkblt instead of BLT
+
+ -- Ole Streicher <olebole at debian.org> Thu, 16 Jun 2016 16:37:34 +0200
+
saods9 (7.5~b1+repack1-1) experimental; urgency=low
* Don't close DS9 when closing the tkcon console
diff --git a/debian/control b/debian/control
index 1a0b6cd..2b1bc3c 100644
--- a/debian/control
+++ b/debian/control
@@ -4,7 +4,6 @@ Priority: optional
Maintainer: Debian Astronomy Maintainers <debian-astro-maintainers at lists.alioth.debian.org>
Uploaders: Ole Streicher <olebole at debian.org>
Build-Depends: autotools-dev,
- blt-dev (>= 2.5.3),
cpio,
debhelper (>= 9),
dh-autoreconf,
@@ -28,6 +27,7 @@ Build-Depends: autotools-dev,
tk-mpeg,
tk-table (>= 2.9),
tk8.6-dev,
+ tkblt-dev,
tkcon,
xauth,
xvfb,
@@ -39,8 +39,7 @@ Vcs-Browser: https://anonscm.debian.org/cgit/debian-astro/packages/saods9.git
Package: saods9
Architecture: all
-Depends: blt (>= 2.5.3),
- libtk-img,
+Depends: libtk-img,
saods9-tclpackages,
tcl-signal,
tcl-xmlrpc,
@@ -51,6 +50,7 @@ Depends: blt (>= 2.5.3),
tk-mpeg,
tk-table (>= 2.9),
tk8.6,
+ tkblt,
tkcon,
tksao,
${misc:Depends},
@@ -80,7 +80,7 @@ Description: Image display tool for astronomy
Package: tksao
Architecture: any
-Depends: blt (>= 2.5.3), ${misc:Depends}, ${shlibs:Depends}
+Depends: tkblt, ${misc:Depends}, ${shlibs:Depends}
Recommends: saods9-doc
Suggests: saods9
Multi-Arch: same
diff --git a/debian/patches/ds9_support_blt.patch b/debian/patches/ds9_support_blt.patch
deleted file mode 100644
index 013f746..0000000
--- a/debian/patches/ds9_support_blt.patch
+++ /dev/null
@@ -1,162 +0,0 @@
-Author: Ole Streicher <olebole at debian.org>
-Description: Allow the use of a standard BLT 2.X instead of tkblt
---- a/ds9/library/graph.tcl
-+++ b/ds9/library/graph.tcl
-@@ -58,10 +58,10 @@
- $ds9(graph,horz) legend configure -hide yes
- $ds9(graph,horz) crosshairs configure -color green
-
-- $ds9(graph,horz) xaxis configure -hide no -showticks no -bg $ds9(bg)
-+ $ds9(graph,horz) xaxis configure -hide no -showticks no -background $ds9(bg)
- $ds9(graph,horz) x2axis configure -hide yes
- $ds9(graph,horz) yaxis configure -hide yes
-- $ds9(graph,horz) y2axis configure -hide no -bg $ds9(bg) \
-+ $ds9(graph,horz) y2axis configure -hide no -background $ds9(bg) \
- -tickfont [font actual TkDefaultFont]
-
- $ds9(graph,horz) element create line1 -xdata graphHorzX -ydata graphHorzY \
-@@ -94,9 +94,9 @@
-
- $ds9(graph,vert) xaxis configure -hide yes -descending yes
- $ds9(graph,vert) x2axis configure -hide no -descending yes \
-- -showticks no -bg $ds9(bg)
-+ -showticks no -background $ds9(bg)
- $ds9(graph,vert) yaxis configure -hide no -descending yes \
-- -bg $ds9(bg) -tickfont [font actual TkDefaultFont]
-+ -background $ds9(bg) -tickfont [font actual TkDefaultFont]
- $ds9(graph,vert) y2axis configure -hide yes -descending yes
-
- $ds9(graph,vert) element create line1 -xdata graphVertX -ydata graphVertY \
-@@ -127,11 +127,9 @@
- global pgraph
- global ds9
-
-- $ds9(graph,horz) xaxis configure -grid $pgraph(horz,grid) -tickdefault 4
-- $ds9(graph,horz) y2axis configure -grid $pgraph(horz,grid)
-+ $ds9(graph,horz) grid configure -hide [expr ! $pgraph(horz,grid)]
-
-- $ds9(graph,vert) x2axis configure -grid $pgraph(vert,grid)
-- $ds9(graph,vert) yaxis configure -grid $pgraph(vert,grid) -tickdefault 4
-+ $ds9(graph,vert) grid configure -hide [expr ! $pgraph(vert,grid)]
- }
-
- proc UpdateGraphXAxis {which} {
-@@ -208,13 +206,13 @@
- set yMax [expr $yMin + 1]
- }
-
-- $what yaxis configure -min $yMin -max $yMax -logscale $log -tickdefault 4
-- $what y2axis configure -min $yMin -max $yMax -logscale $log -tickdefault 4
-+ $what yaxis configure -min $yMin -max $yMax -logscale $log
-+ $what y2axis configure -min $yMin -max $yMax -logscale $log
- } else {
- $what yaxis configure -min $igraph(y,min) -max $igraph(y,max) \
-- -logscale $log -tickdefault 4
-+ -logscale $log
- $what y2axis configure -min $igraph(y,min) -max $igraph(y,max) \
-- -logscale $log -tickdefault 4
-+ -logscale $log
- }
- }
-
---- a/ds9/library/scale.tcl
-+++ b/ds9/library/scale.tcl
-@@ -314,9 +314,9 @@
- ]
-
- $dscale(hist) legend configure -hide yes
-- $dscale(hist) xaxis configure -hide yes -grid no -ticklength 3 \
-+ $dscale(hist) xaxis configure -hide yes -ticklength 3 \
- -tickfont [font actual TkDefaultFont]
-- $dscale(hist) yaxis configure -hide yes -grid yes -ticklength 3 \
-+ $dscale(hist) yaxis configure -hide yes -ticklength 3 \
- -tickfont [font actual TkDefaultFont]
- set dscale(xdata) histX
- set dscale(ydata) histY
---- a/ds9/library/plotbar.tcl
-+++ b/ds9/library/plotbar.tcl
-@@ -149,8 +149,7 @@
- -highlightthickness 0 \
- ]
-
-- $var(graph) xaxis configure -grid no -stepsize 0
-- $var(graph) yaxis configure -grid yes
-+ $var(graph) xaxis configure -stepsize 0
-
- pack $var(graph) -expand yes -fill both
- PlotChangeMode $varname
---- a/ds9/library/plot.tcl
-+++ b/ds9/library/plot.tcl
-@@ -1196,20 +1196,19 @@
- -font "{$ds9($var(graph,title,family))} $var(graph,title,size) $var(graph,title,weight) $var(graph,title,slant)"
-
- $var(graph) xaxis configure \
-- -grid $var(axis,x,grid) -logscale $var(axis,x,log) \
-+ -logscale $var(axis,x,log) \
- -title $var(axis,x,title) \
- -tickfont "{$ds9($var(axis,font,family))} $var(axis,font,size) $var(axis,font,weight) $var(axis,font,slant)" \
- -titlefont "{$ds9($var(axis,title,family))} $var(axis,title,size) $var(axis,title,weight) $var(axis,title,slant)"
- $var(graph) yaxis configure \
-- -grid $var(axis,y,grid) -logscale $var(axis,y,log) \
-+ -logscale $var(axis,y,log) \
- -title $var(axis,y,title) \
- -tickfont "{$ds9($var(axis,font,family))} $var(axis,font,size) $var(axis,font,weight) $var(axis,font,slant)" \
- -titlefont "{$ds9($var(axis,title,family))} $var(axis,title,size) $var(axis,title,weight) $var(axis,title,slant)"
-
- $var(graph) legend configure -hide [expr !$var(legend)] \
-- -position $var(legend,position) -title $var(legend,title) \
-- -font "{$ds9($var(legend,font,family))} $var(legend,font,size) $var(legend,font,weight) $var(legend,font,slant)" \
-- -titlefont "{$ds9($var(legend,title,family))} $var(legend,title,size) $var(legend,title,weight) $var(legend,title,slant)"
-+ -position $var(legend,position) \
-+ -font "{$ds9($var(legend,font,family))} $var(legend,font,size) $var(legend,font,weight) $var(legend,font,slant)"
- }
-
- proc PlotCreateElement {varname} {
---- a/ds9/library/plotdialog.tcl
-+++ b/ds9/library/plotdialog.tcl
-@@ -200,14 +200,13 @@
-
- global ds9
-
-- blt::RemoveBindTag $var(graph) zoom-$var(graph)
- bind $var(graph) <1> {}
-
- switch $var(mode) {
- pointer {bind $var(graph) <1> [list PlotButton $varname %x %y]}
- zoom {
- switch $ds9(wm) {
-- x11 -
-+ x11 {Blt_ZoomStack $var(graph)}
- win32 {Blt_ZoomStack $var(graph) -mode release}
- aqua {Blt_ZoomStack $var(graph) -mode release -button "ButtonPress-2"}
- }
---- a/ds9/library/plotprint.tcl
-+++ b/ds9/library/plotprint.tcl
-@@ -35,18 +35,10 @@
- -titlefont "$var(axis,title,family) $var(axis,title,size) $var(axis,title,weight) $var(axis,title,slant)"
-
- $var(graph) legend configure \
-- -font "$var(legend,font,family) $var(legend,font,size) $var(legend,font,weight) $var(legend,font,slant)" \
-- -titlefont "$var(legend,title,family) $var(legend,title,size) $var(legend,title,weight) $var(legend,title,slant)"
-+ -font "$var(legend,font,family) $var(legend,font,size) $var(legend,font,weight) $var(legend,font,slant)"
-
- set options "-decorations false"
-
-- # Color
-- switch -- $ps(color) {
-- rgb -
-- cmyk {append options " -greyscale no"}
-- gray {append options " -greyscale yes"}
-- }
--
- # Size
- set ww [expr [winfo width $var(top)]*$ps(scale)/100./[tk scaling]]
- set hh [expr [winfo height $var(top)]*$ps(scale)/100./[tk scaling]]
-@@ -102,6 +94,5 @@
- -titlefont "{$ds9($var(axis,title,family))} $var(axis,title,size) $var(axis,title,weight) $var(axis,title,slant)"
-
- $var(graph) legend configure \
-- -font "{$ds9($var(legend,font,family))} $var(legend,font,size) $var(legend,font,weight) $var(legend,font,slant)" \
-- -titlefont "{$ds9($var(legend,title,family))} $var(legend,title,size) $var(legend,title,weight) $var(legend,title,slant)"
-+ -font "{$ds9($var(legend,font,family))} $var(legend,font,size) $var(legend,font,weight) $var(legend,font,slant)"
- }
diff --git a/debian/patches/ds9_use_system_libs.patch b/debian/patches/ds9_use_system_libs.patch
index 7915a7f..d8c9e3a 100644
--- a/debian/patches/ds9_use_system_libs.patch
+++ b/debian/patches/ds9_use_system_libs.patch
@@ -119,7 +119,7 @@ Description: Link against system libraries.
+
+ package require tkcon
+ package require xmlrpc
-+ package require BLT
++ package require tkblt
+ package require Tktable
+ package require tclxpa
+ package require Signal
diff --git a/debian/patches/ds9_use_tcltk_packages.patch b/debian/patches/ds9_use_tcltk_packages.patch
index 2f4c21e..2e22d1f 100644
--- a/debian/patches/ds9_use_tcltk_packages.patch
+++ b/debian/patches/ds9_use_tcltk_packages.patch
@@ -41,7 +41,7 @@ Description: Don't load TclTk extensions as shared libs, but as packages.
@@ -197,6 +197,11 @@
package require tkcon
package require xmlrpc
- package require BLT
+ package require tkblt
+ package require tksao
+ package require tkhtml1
+ package require tcliis
diff --git a/debian/patches/saotk_fix_blt_crash.patch b/debian/patches/saotk_fix_blt_crash.patch
deleted file mode 100644
index 2ae87d3..0000000
--- a/debian/patches/saotk_fix_blt_crash.patch
+++ /dev/null
@@ -1,84 +0,0 @@
-Author: Ole Streicher <olebole at debian.org>
-Description: BLT crashes when it reaches this code. This fix is
- pragmatic -- I will not guarantee that this is not a memore hole.
- I would very much appreciate if someone could review this and provide
- a better fix.
---- a/tksao/frame/frblt.C
-+++ b/tksao/frame/frblt.C
-@@ -950,7 +950,7 @@
- if (Blt_GetVector(interp, xname, &xv) != TCL_OK)
- goto error;
-
-- if (Blt_ResetVector(xv, xx, length, length*sizeof(double), TCL_DYNAMIC) !=
-+ if (Blt_ResetVector(xv, xx, length, length*sizeof(double), TCL_STATIC) !=
- TCL_OK)
- goto error;
-
-@@ -958,7 +958,7 @@
- if (Blt_GetVector(interp, yname, &yv) != TCL_OK)
- goto error;
-
-- if (Blt_ResetVector(yv, yy, length, length*sizeof(double), TCL_DYNAMIC) !=
-+ if (Blt_ResetVector(yv, yy, length, length*sizeof(double), TCL_STATIC) !=
- TCL_OK)
- goto error;
-
---- a/tksao/frame/marker.C
-+++ b/tksao/frame/marker.C
-@@ -1254,19 +1254,19 @@
- {
- Blt_Vector* xx;
- Blt_GetVector(parent->getInterp(), xname, &xx);
-- Blt_ResetVector(xx, x, num, num*sizeof(double), TCL_DYNAMIC);
-+ Blt_ResetVector(xx, x, num, num*sizeof(double), TCL_STATIC);
-
- Blt_Vector* yy;
- Blt_GetVector(parent->getInterp(), yname, &yy);
-- Blt_ResetVector(yy, y, num, num*sizeof(double), TCL_DYNAMIC);
-+ Blt_ResetVector(yy, y, num, num*sizeof(double), TCL_STATIC);
-
- Blt_Vector* xxc;
- Blt_GetVector(parent->getInterp(), xcname, &xxc);
-- Blt_ResetVector(xxc, xc, num, num*sizeof(double), TCL_DYNAMIC);
-+ Blt_ResetVector(xxc, xc, num, num*sizeof(double), TCL_STATIC);
-
- Blt_Vector* yyc;
- Blt_GetVector(parent->getInterp(), ycname, &yyc);
-- Blt_ResetVector(yyc, yc, num, num*sizeof(double), TCL_DYNAMIC);
-+ Blt_ResetVector(yyc, yc, num, num*sizeof(double), TCL_STATIC);
- }
-
- void Marker::analysisXYResult(char* xname, char* yname, double* x, double* y,
-@@ -1274,11 +1274,11 @@
- {
- Blt_Vector* xx;
- Blt_GetVector(parent->getInterp(), xname, &xx);
-- Blt_ResetVector(xx, x, num, num*sizeof(double), TCL_DYNAMIC);
-+ Blt_ResetVector(xx, x, num, num*sizeof(double), TCL_STATIC);
-
- Blt_Vector* yy;
- Blt_GetVector(parent->getInterp(), yname, &yy);
-- Blt_ResetVector(yy, y, num, num*sizeof(double), TCL_DYNAMIC);
-+ Blt_ResetVector(yy, y, num, num*sizeof(double), TCL_STATIC);
- }
-
- void Marker::analysisXYEResult(char* xname, char* yname, char* ename,
-@@ -1286,15 +1286,15 @@
- {
- Blt_Vector* xx;
- Blt_GetVector(parent->getInterp(), xname, &xx);
-- Blt_ResetVector(xx, x, num, num*sizeof(double), TCL_DYNAMIC);
-+ Blt_ResetVector(xx, x, num, num*sizeof(double), TCL_STATIC);
-
- Blt_Vector* yy;
- Blt_GetVector(parent->getInterp(), yname, &yy);
-- Blt_ResetVector(yy, y, num, num*sizeof(double), TCL_DYNAMIC);
-+ Blt_ResetVector(yy, y, num, num*sizeof(double), TCL_STATIC);
-
- Blt_Vector* ee;
- Blt_GetVector(parent->getInterp(), ename, &ee);
-- Blt_ResetVector(ee, e, num, num*sizeof(double), TCL_DYNAMIC);
-+ Blt_ResetVector(ee, e, num, num*sizeof(double), TCL_STATIC);
- }
-
- void Marker::analysisXYEResult(double* x, double* y, double* e, int num)
diff --git a/debian/patches/saotk_use_system_libs.patch b/debian/patches/saotk_use_system_libs.patch
index 557c08b..a266998 100644
--- a/debian/patches/saotk_use_system_libs.patch
+++ b/debian/patches/saotk_use_system_libs.patch
@@ -33,10 +33,18 @@ Description: Compile against system library wcstools and funtools
TEA_ADD_HEADERS([])
TEA_ADD_INCLUDES([-I. -I./colorbar -I./fitsy++ -I./frame -I./list -I./magnifier -I./panner -I./util -I./vector -I./wcssubs -I./widget -I${prefix}/include])
-TEA_ADD_LIBS([-lstdc++])
-+TEA_ADD_LIBS([-lstarlink_ast -lstarlink_ast_err -lfuntools -lwcstools -lBLT -lxml2 -lstdc++])
++TEA_ADD_LIBS([-lstarlink_ast -lstarlink_ast_err -lfuntools -lwcstools -ltkbltstub -lxml2 -lstdc++])
TEA_ADD_CFLAGS([])
TEA_ADD_STUB_SOURCES([])
TEA_ADD_TCL_SOURCES([])
+@@ -379,6 +360,7 @@
+ #--------------------------------------------------------------------
+
+ AC_DEFINE(USE_TCL_STUBS, 1, [Use Tcl stubs])
++AC_DEFINE(USE_TKBLT_STUBS, 1, [Use Tkblt stubs])
+ #AC_DEFINE(USE_TK_STUBS, 1, [Use Tk stubs])
+
+ #--------------------------------------------------------------------
--- a/tksao/frame/fitsimage.h
+++ b/tksao/frame/fitsimage.h
@@ -10,7 +10,7 @@
diff --git a/debian/patches/saotk_use_tkblt.patch b/debian/patches/saotk_use_tkblt.patch
new file mode 100644
index 0000000..22acffe
--- /dev/null
+++ b/debian/patches/saotk_use_tkblt.patch
@@ -0,0 +1,57 @@
+Author: Ole Streicher <olebole at debian.org>
+Description: Use tkblt instead of BLT.
+ This requires another header file.
+--- a/tksao/frame/context.C
++++ b/tksao/frame/context.C
+@@ -21,7 +21,7 @@
+ #include "head.h"
+
+ extern "C" {
+-#include "bltVector.h"
++#include "tkbltVector.h"
+ }
+
+ typedef struct {
+--- a/tksao/frame/frblt.C
++++ b/tksao/frame/frblt.C
+@@ -8,7 +8,7 @@
+
+ #include "projection.h"
+ extern "C" {
+-#include "bltVector.h"
++#include "tkbltVector.h"
+ }
+
+ #include "sigbus.h"
+--- a/tksao/frame/marker.C
++++ b/tksao/frame/marker.C
+@@ -8,7 +8,7 @@
+ #include "fitsimage.h"
+
+ extern "C" {
+-#include "bltVector.h"
++#include "tkbltVector.h"
+ }
+
+ static int markerSeqID = 1;
+--- a/tksao/saotk.C
++++ b/tksao/saotk.C
+@@ -4,6 +4,9 @@
+
+ #include <tk.h>
+
++extern CONST char *
++Tkblt_InitStubs(Tcl_Interp *interp, CONST char *version, int exact);
++
+ extern int FrameTrueColor8_Init(Tcl_Interp*);
+ extern int FrameTrueColor16_Init(Tcl_Interp*);
+ extern int FrameTrueColor24_Init(Tcl_Interp*);
+@@ -40,6 +43,8 @@
+ return TCL_ERROR;
+ if (Tk_InitStubs(interp, TK_PATCH_LEVEL, 0) == NULL)
+ return TCL_ERROR;
++ if (Tkblt_InitStubs(interp, NULL, 0) == NULL)
++ return TCL_ERROR;
+
+ if (FrameTrueColor8_Init(interp) == TCL_ERROR)
+ return TCL_ERROR;
diff --git a/debian/patches/series b/debian/patches/series
index 0deeb4a..d03664e 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1,13 +1,12 @@
ds9_use_system_libs.patch
ds9_use_tcltk_packages.patch
-ds9_support_blt.patch
ds9_fix_docdir.patch
ds9_optional_doc_package.patch
ds9_add_about_debian.patch
ds9_dont_exit_on_tkcon.patch
-saotk_fix_blt_crash.patch
saotk_add_ksearch.patch
saotk_add_psscale.patch
+saotk_use_tkblt.patch
saotk_avoid_compile_warnings.patch
saotk_use_system_libs.patch
saotk_spellfix.patch
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-astro/packages/saods9.git
More information about the Debian-astro-commits
mailing list