0
내가 cx_Freeze
를 사용하여 내 파이썬 프로젝트에서 실행 파일을 만들려고하지만,이 오류에 계속 실행하고이 (_tkinter를 가져올 수 없습니다, DLL로드 실패) 평 :가
import cx_Freeze
import os, sys
os.environ['TCL_LIBRARY'] = "D:\\Code\\Python\\3.5.2\\tcl\\tcl8.6"
os.environ['TK_LIBRARY'] = "D:\\Code\\Python\\3.5.2\\tcl\\tk8.6"
base = None
if sys.platform == "win32":
base = "Win32GUI"
executables = [cx_Freeze.Executable("Main.pyw", base=base)]
includes = ["tkinter"]
include_files = [r"D:\Code\Python\3.5.2\tcl\DLLs\tcl86t.dll", \
r"D:\Code\Python\3.5.2\tcl\DLLs\tk86t.dll"]
cx_Freeze.setup(
name="Test",
version = "1.0",
options={"Test.exe": {"packages":["pygame", "numpy"], "includes": includes, "include_files": include_files}},
executables = executables)
본인은 "패키지"목록에 tkinter
퍼팅 시도했지만 여전히 같은 오류가 발생합니다. 또한 다른 StackOverflow 게시물을 확인하고 자신의 setup.py
코드 일부를 사용했지만 아무 것도 작동하지 않습니다. PyInstaller
은 pygame
을 지원하지 않으므로 py2exe
은 Python 3.5를 지원하지 않으므로 사용할 수 없습니다. 어떤 도움을 주시면 감사하겠습니다.