Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

pyqt和pyside都有了,建议搞个tkinter的包 #84

Open
urna opened this issue Jul 20, 2024 · 2 comments
Open

pyqt和pyside都有了,建议搞个tkinter的包 #84

urna opened this issue Jul 20, 2024 · 2 comments

Comments

@urna
Copy link

urna commented Jul 20, 2024

pyqt和pyside都有了,建议搞个tkinter的包,这个需求也是有的

@urna urna changed the title pyqt和pyside都有了,建议搞的tkinter的包 pyqt和pyside都有了,建议搞个tkinter的包 Jul 20, 2024
@tdRPA
Copy link

tdRPA commented Jul 21, 2024

我搞了一个,在这里 https://gitee.com/tdRPA/pystand-py38-x64__tkinter

@mengdeer589
Copy link

我给个解法。官方提供的嵌入式解释器并不包含pip工具,以及tkinter模块,下面的步骤是怎么补上这个tkinter模块。

注:本方法目的在于后续可以复用,所以并不按照官方的目录结构来。

①复制tkinter模块。从已经安装了tkinter模块的相同python解释器环境中复制,该模块通常位于解释器的Lib文件夹下,将tkinter文件夹复制到pystand/runtime/lib文件夹下,注意,这里需要新建一个lib文件夹。

②复制tcl资源文件。复制tcl文件夹里面所有的文件,到pystand/runtime/lib文件夹下,tcl文件夹通常位于解释器的同级目录。

③复制二进制模块。复制_tkinter.pyd,tcl86t.dll,tk86t.dll三个文件到pystand/runtime/lib文件夹下,这三个文件通常位于解释器的DLLs文件夹下。

④修改路径。修改runtime文件夹里面的python310._pth文件,增加一行./lib。注意,这里有个点,代表同级目录的lib文件夹。

现在可以运行程序了。如果后续还需要打包tkinter模块。直接复制这里弄好的lib文件夹跟._pth文件到runtime文件夹下即可实现复用。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants