Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
dev-tcltk/tix bug
View unanswered posts
View posts from last 24 hours
View posts from last 7 days

 
Reply to topic    Gentoo Forums Forum Index Deutsches Forum (German)
View previous topic :: View next topic  
Author Message
flammenflitzer
Advocate
Advocate


Joined: 25 Nov 2003
Posts: 3541
Location: Berlin

PostPosted: Fri Aug 26, 2005 7:28 am    Post subject: dev-tcltk/tix bug Reply with quote

Ich wollte mit dem Installer Call to Power installieren
Code:

./ctp-install
Traceback (most recent call last):
  File "./ctp-install", line 16, in ?
    root = Tk()
  File "/usr/lib/python2.4/lib-tk/Tix.py", line 210, in __init__
    self.tk.eval('package require Tix')
_tkinter.TclError: couldn't load file "/usr/lib64/libtix8.2.so": /usr/lib64/libtix8.2.so: undefined symbol: XLowerWindow

Kann mir jemand weiterhelfen?

/usr/lib64/libtix8.2.so existiert.

Code:

ls -la /usr/lib64/libtix8.2.so
-r-xr-xr-x  1 root root 312112 26. Aug 09:07 /usr/lib64/libtix8.2.so

Ich habe den Bug gefunden, werde aber nicht so recht schlau, was ich machen muß.
Code:
http://bugs.gentoo.org/show_bug.cgi?id=88513

Code:
After adding dev-tcltk/tix I should be able to use the Tix widgets from python, but instead I get an error when trying to import:

_tkinter.TclError: couldn't load file "/usr/lib/libtix8.2.so": /usr/lib/libtix8.2.so: undefined symbol: XLowerWindow

Reproducible: Always
Steps to Reproduce:
1. build dev-lang/python
2. build dev-tcltk/tix
3. Try to use Tix from python

python
import Tix
r = Tix.Tk()
Actual Results: 
_tkinter.TclError: couldn't load file
"/usr/lib/libtix8.2.so": /usr/lib/libtix8.2.so: undefined symbol: XLowerWindow
 

Expected Results: 
No error.

I got this to work by manually relinking _tkinter.so. 
 
_tkinter.so needs to link in libtix. 
 
I did... 
 
emerge unpack 
emerge compile 
 
then switched in to the work directory and did ... 
i686-pc-linux-gnu-gcc -pthread -shared build/temp.linux-i686-2.3/_tkinter.o 
build/temp.linux-i686-2.3/tkappinit.o -L/usr/X11R6/lib -L/usr/local/lib -ltk8.4 
-ltcl8.4 -lX11 -ltix8.2 -o build/lib.linux-i686-2.3/_tkinter.so 
 
(adding -ltix8.2 which was not there in the original compile) 
 
Now tix works from python...


------- Additional Comment #1 From T. Koehler 2005-07-12 07:33 PDT -------

Although the solution presented by the parent may work, it is only a workaround,
because it would mean that any extension to Tk would need a recompile of python
to work. The real problem lies within /usr/lib/tkConfig.sh, which contains two
types of errors:

1) The paths to the headers and libraries ("TK_SRC_DIR", several others) contain
the tmp-directory used by portage for compilation. This needs to be changed to
"/usr/lib/tk8.4/include"

2) The variables for the stub-libraries do not contain -lX11.

Error 1) causes Tix to fail to compile on my machine (amd64). After fixing this,
the error described by the parent occurs.

Error 2) causes the "undefined symbol"-error from within python. Fixing it makes
Tix work from python without having to recompile python.


Last edited by flammenflitzer on Sun Aug 28, 2005 3:57 pm; edited 1 time in total
Back to top
View user's profile Send private message
Raistlin
l33t
l33t


Joined: 17 May 2004
Posts: 691
Location: Boston, MA

PostPosted: Fri Aug 26, 2005 6:22 pm    Post subject: Reply with quote

Code:
------- Additional Comment #1 From T. Koehler 2005-07-12 07:33 PDT -------

Although the solution presented by the parent may work, it is only a workaround,
because it would mean that any extension to Tk would need a recompile of python
to work. The real problem lies within /usr/lib/tkConfig.sh, which contains two
types of errors:

1) The paths to the headers and libraries ("TK_SRC_DIR", several others) contain
the tmp-directory used by portage for compilation. This needs to be changed to
"/usr/lib/tk8.4/include"

2) The variables for the stub-libraries do not contain -lX11.

Error 1) causes Tix to fail to compile on my machine (amd64). After fixing this,
the error described by the parent occurs.

Error 2) causes the "undefined symbol"-error from within python. Fixing it makes
Tix work from python without having to recompile python.

scheint zu reichen. Bei mir "müsste" bloss das zweite gemacht werden, das 1) ist schon korrekt...
--> in
Code:
/usr/lib/tkConfig.sh
die Variablen anpassen.
IMO
Code:
TK_STUB_LIB_{IRGENDWAS}
(ausprobieren ? )

Gruss, R.

Gruss, R.
_________________
Zwei Was Eins Initially

"Debugging is twice as hard as writing the code in the first place. Therefore, if you write the code as cleverly as possible, you are, by definition, not smart enough to debug it."
Back to top
View user's profile Send private message
flammenflitzer
Advocate
Advocate


Joined: 25 Nov 2003
Posts: 3541
Location: Berlin

PostPosted: Sat Aug 27, 2005 5:12 pm    Post subject: Reply with quote

Code:

 cat /usr/lib/tkConfig.sh | grep -v \#

TK_VERSION='8.4'
TK_MAJOR_VERSION='8'
TK_MINOR_VERSION='4'
TK_PATCH_LEVEL='.11'

TK_DEFS=' -DHAVE_UNISTD_H=1 -DHAVE_LIMITS_H=1 -DPEEK_XCLOSEIM=1 -D_LARGEFILE64_SOURCE=1 -DTCL_WIDE_INT_IS_LONG=1 -DSTDC_HEADERS=1 -DHAVE_SYS_TIME_H=1 -DTIME_WITH_SYS_TIME=1 -DHAVE_PW_GECOS=1 '

TK_SHARED_BUILD=1

TK_DBGX=

TK_LIB_FILE='libtk8.4${TK_DBGX}.so'

TK_LIBS='-L/usr/lib64 -lX11 -ldl  -lieee -lm'

TK_PREFIX='/usr'

TK_EXEC_PREFIX='/usr'

TK_XINCLUDES=''

TK_XLIBSW='-L/usr/lib64 -lX11'

TK_LIB_FLAG='-ltk8.4'

TK_BUILD_LIB_SPEC='-L/usr/lib64 -ltk8.4'

TK_LIB_SPEC='-L/usr/lib64 -ltk8.4'

TK_SRC_DIR='/usr/lib64/tk8.4/include'

TK_CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}:/usr/lib64:/usr/lib64:/usr/lib64'
TK_LD_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}:/usr/lib64:/usr/lib64:/usr/lib64'

TK_STUB_LIB_FILE='libtkstub8.4.a'

TK_STUB_LIB_FLAG='-ltkstub8.4'

TK_BUILD_STUB_LIB_SPEC='-L/usr/lib64 -ltkstub8.4'

TK_STUB_LIB_SPEC='-L/usr/lib64 -ltkstub8.4'

TK_BUILD_STUB_LIB_PATH='/usr/lib64/libtkstub8.4.a'

TK_STUB_LIB_PATH='/usr/lib64/libtkstub8.4.a'


Code:

ls -la /usr/lib64/libtkstub8.4.a
-rw-r--r--  1 root root 5086  3. Jul 13:34 /usr/lib64/libtkstub8.4.a


???
Back to top
View user's profile Send private message
flammenflitzer
Advocate
Advocate


Joined: 25 Nov 2003
Posts: 3541
Location: Berlin

PostPosted: Sat Aug 27, 2005 7:34 pm    Post subject: Reply with quote

Auch das Ändern von
TK_SRC_DIR='/usr/lib64/tk8.4/include'
in
TK_SRC_DIR='/usr/lib/tk8.4/include'
hat nichts gebracht.
Back to top
View user's profile Send private message
Raistlin
l33t
l33t


Joined: 17 May 2004
Posts: 691
Location: Boston, MA

PostPosted: Sun Aug 28, 2005 6:26 am    Post subject: Reply with quote

Hi,

ich meinte eigentlich, dass mit
Quote:
2) The variables for the stub-libraries do not contain -lX11.

gemeint ist, z.B. die Variablen
Code:
TK_STUB_LIB_FILE='libtkstub8.4.a'

TK_STUB_LIB_FLAG='-ltkstub8.4'

TK_BUILD_STUB_LIB_SPEC='-L/usr/lib64 -ltkstub8.4'

TK_STUB_LIB_SPEC='-L/usr/lib64 -ltkstub8.4'


um die Anweisung
Code:
-lX11
zu erweitern...
Also z.B.
Code:
TK_STUB_LIB_FLAG='-ltkstub8.4 -lX11'


Gruss, R.
_________________
Zwei Was Eins Initially

"Debugging is twice as hard as writing the code in the first place. Therefore, if you write the code as cleverly as possible, you are, by definition, not smart enough to debug it."
Back to top
View user's profile Send private message
flammenflitzer
Advocate
Advocate


Joined: 25 Nov 2003
Posts: 3541
Location: Berlin

PostPosted: Sun Aug 28, 2005 3:58 pm    Post subject: Reply with quote

Hat nichts gebracht.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Deutsches Forum (German) All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum