473,624 Members | 2,612 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Re: What happened to _tkinter.so?

Hello,

I spent time today to investigate this.
If you install Python with Tkinter from source, _tkinter is built into
the Python executable and _tkinter.so is not generated *unless*
"shared" option is specified.

I found this by running python with '-v' option:
% python -v
....
>>from Tkinter import *
....
import _tkinter # builtin <<<---

In the Module/Setup file:
# Uncommenting the following line tells makesetup that all following
# modules are to be built as shared libraries (see above for more
# detail; also note that *static* reverses this effect):

#*shared*

I tried to uncomment the line and I got successfully _tkinter.so under
python2.5/lib-dynload directory.

This may be an issue for PyInstaller as it relys on _tkinter.so to
find the path to TCL/TK.
However, many Linux distribution includes _tkinter.so as many people
complained about missing _tkinter.so.
So, this is not really an issue unless you install Python by yourself.

Aki-

On Jun 26, 6:00 pm, akineko <akin...@gmail. comwrote:
Hello Python developers,

I have noticed something curious while I was investigating a problem
with the PyInstaller.

In my environment, the PyInstaller couldn't find TCL/TK installation
path even I have it.
I found the PyInstaller uses output from ldd <dynamic link libaryto
find the a path to TCL/TK libraries.
But no dynamic libraries under my Python 5 lib-dynload directoty
contain a path to TCL/TK libraries.

When I posted this problem to the PyInstaller newsgroup, a guy
responded that he didn't have such problem.
After several exchanges, what we found was his lib-dynload directory
contains_tkinte r.so (even he has the same Python2.5.2) while my lib-
dynload directory doesn't have it.

He installed the Python using package tool (no fresh compile) while I
installed my Python from src (clean compile).

I recompiled Python 2.4 and confirmed that Python 2.4 creates_tkinter .so.
After browsing the Makefile under Python 2.5, I had an impression that
Python 2.5 no longer uses_tkinter.so .

Am I correct?
If that is the case, I need to warn the PyInstaller developers that
the scheme to find TCL/TK path is no longer valid.

Any comments will be highly appreciated.

Thank you for your attention.
Aki Niimura
Jun 29 '08 #1
0 1203

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
2443
by: gaool | last post by:
Hello, I try to launch a Python script on SunOS system but I have this error: """Traceback (most recent call last): File "ihm1_1.py", line 3, in ? from Tkinter import * File "/opt/sfw/lib/python2.3/lib-tk/Tkinter.py", line 38, in ? import _tkinter # If this fails your Python may not be configured for Tk
0
1695
by: mg | last post by:
Hello, First, I installed Python on a traditionnal default linux-x86 platform (tk.h is located in /usr/include) and I did not meet any problem. I can write the following instruction without error in my python interpreter: ../configure --prefix=/usr/local/python make make install /usr/local/python/bin/python
1
3454
by: Sorin Schwimmer | last post by:
Hi All, After a disaster in which I lost my whole harddrive, I decided to install the newest everything that I use. I put the latest Gentoo Linux, with gcc 4.1.1, installed tcl/tk 8.4.14 and tried Python 2.5. I tried with and without the suggested -fwrapv compiler option, and make gave me the same:
5
2202
by: jgelfand | last post by:
I'm installing Python 2.4.4 on a CentOS release 4.6 (Final) 64-bit machine. Running "./configure --prefix="/ usr/local/yosi/ciao-4.0/ots" --enable-shared" appears to be fine, but I get the following error message when I run "make": building '_tkinter' extension gcc -pthread -fPIC -fno-strict-aliasing -DNDEBUG -g -fwrapv -O3 -Wall - Wstrict-prototypes -DWITH_APPINIT=1 -I/usr/X11R6/include -I. -I/usr/ local/yosi/Python-2.5.2/./Include...
0
8251
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8182
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8688
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8635
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
5570
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4085
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
1
2614
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
1
1800
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
2
1496
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.