Package: saods9 / 8.0.1+repack-2

tksao-Initialize-tkblt-stubs.patch Patch series | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
From: Ole Streicher <olebole@debian.org>
Date: Fri, 14 Apr 2017 13:30:17 +0200
Subject: [tksao] Initialize tkblt stubs

This resolves a crash when using vertical/horizontal graphs.
Closes: #859777
---
 tksao/configure.ac | 4 ++--
 tksao/saotk.C      | 4 ++++
 2 files changed, 6 insertions(+), 2 deletions(-)

diff --git a/tksao/configure.ac b/tksao/configure.ac
index cde9ae8..d6d76d1 100644
--- a/tksao/configure.ac
+++ b/tksao/configure.ac
@@ -269,8 +269,8 @@ widget/widget.C
 
 TEA_ADD_HEADERS([])
 TEA_ADD_INCLUDES([-I. -I./colorbar -I./fitsy++ -I./frame -I./list -I./magnifier -I./panner -I./util -I./vector -I./widget -I${prefix}/include])
-TEA_ADD_LIBS([-lstdc++])
-TEA_ADD_CFLAGS([])
+TEA_ADD_LIBS([-lstarlink_ast -lstarlink_ast_err -lfuntools -ltkbltstub -lxml2 -lstdc++])
+TEA_ADD_CFLAGS([-DUSE_TKBLT_STUBS])
 TEA_ADD_STUB_SOURCES([])
 TEA_ADD_TCL_SOURCES([])
 
diff --git a/tksao/saotk.C b/tksao/saotk.C
index 18eb111..0f5e451 100644
--- a/tksao/saotk.C
+++ b/tksao/saotk.C
@@ -4,6 +4,8 @@
 
 #include <tk.h>
 
+extern const char* Tkblt_InitStubs(Tcl_Interp*, const char*, int);
+
 extern int FrameTrueColor8_Init(Tcl_Interp*);
 extern int FrameTrueColor16_Init(Tcl_Interp*);
 extern int FrameTrueColor24_Init(Tcl_Interp*);
@@ -40,6 +42,8 @@ int Tksao_Init(Tcl_Interp* interp) {
     return TCL_ERROR;
   if (Tk_InitStubs(interp, TK_PATCH_LEVEL, 0) == NULL)
     return TCL_ERROR;
+  if (Tkblt_InitStubs(interp, "3.2", 0) == NULL)
+    return TCL_ERROR;
 
   if (FrameTrueColor8_Init(interp) == TCL_ERROR)
     return TCL_ERROR;