Python Forum
Failed tkinter Compile In Custom 3.7.2 Build Using Custom Tcl/Tk Build
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Failed tkinter Compile In Custom 3.7.2 Build Using Custom Tcl/Tk Build
#1
All,

I spent a few hours working on a custom Python 3.7.2 build using a custom (and successful) Tcl/Tk 8.6.9 build/install that continually failed to correctly compile the tkinter module. Here are the relevant details:

Red Hat Enterprise Linux Workstation release 7.6 (Maipo)
Python 3.7.2 source
Tcl/Tk 8.6.9 source
OS-provided Tcl/Tk packages not installed

I added the destinations of both the Python and Tcl/Tk builds to /etc/ld.so.conf.d/custom-python.conf and executed /sbin/ldconfig.

The autoconf command I used is:

./configure --prefix=<python-prefix> --with-tcltk-includes=-I<tcl-prefix>/include --with-tcltk-libs="-L<tcl-prefix>/lib -ltcl8.6 -ltk8.6"

The Python build succeeded but the tkinter module failed to build. The config.log output indicated that it could not find tcl.h, but it (and the other header files) exists in <tcl-prefix>/include. Out of curiosity, I progressively created symlinks in /usr/include to tcl.h, tk.h, tclDecls.h, and tclPlatDecls.h until the errors stopped appearing in config.log and the tkinter module successfully compiled and indicated that it was using the expected version of Tcl/Tk.

It appears to me that the autoconf execution is not honoring the --with-tcltk-includes value. I attempted the same steps using Python 3.6.8 with similar results.

--
G.
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  Python coming to DroidScript (build native Android Apps) d_a_v_e 5 1,602 Feb-20-2024, 05:48 PM
Last Post: d_a_v_e
  python-3.10.0-amd64 build corrupt? lohphat 4 2,344 Nov-21-2021, 09:28 AM
Last Post: Axel_Erfurt
  Build website tdwinfre 11 4,282 Nov-04-2020, 06:18 PM
Last Post: tdwinfre
  PIP Installation problem with VS Build tools Hanneth 1 1,901 Mar-26-2020, 08:22 PM
Last Post: Larz60+
  What To Build ? MrGoat 1 1,559 Jan-22-2020, 01:25 PM
Last Post: buran
  Python to build desktop and mobile apps tneilson08 3 2,620 Jan-15-2020, 08:07 AM
Last Post: perfringo
  best way to build as string from pieces Skaperen 1 1,614 Aug-29-2019, 05:31 AM
Last Post: stranac
  configuring python at build time Skaperen 2 1,871 Jul-03-2019, 11:33 PM
Last Post: Skaperen
  Distributing custom version of Python touc82 1 2,067 Mar-23-2019, 03:23 PM
Last Post: Larz60+
  has anyone here created their own custom codec? Skaperen 0 1,915 Jan-30-2018, 06:48 AM
Last Post: Skaperen

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020