2011-11-09 16 views
10

मैं पाइथन और cx_Freeze के लिए नया हूं। कृपया इसे काम करने में मेरी मदद करें।cx_Freeze अनुपलब्ध मॉड्यूल त्रुटि

और कमांड चलाएँ:

अजगर का निर्माण setup.py

यह मुझे निम्न त्रुटि दे रहा है।

लापता मॉड्यूल:

? सिस्टम serial.serialcli

से आयातित सिस्टम? Serial.serialposix

से आयातित TERMIOS? serial.serialcli

से आयातित clr? Wxversion

से आयातित wx मैं निम्नलिखित setup.py फ़ाइल का उपयोग कर रहा हूं।

# Let's start with some default (for me) imports... 

from cx_Freeze import setup, Executable 

# Process the includes, excludes and packages first 

includes = [] 
excludes = ['_gtkagg', '_tkagg', 'bsddb', 'curses', 'email', 'pywin.debugger', 
     'pywin.debugger.dbgcon', 'pywin.dialogs', 'tcl', 
     'Tkconstants', 'Tkinter'] 
packages = [] 
path = [] 

GUI2Exe_Target_1 = Executable(
    # what to build 
    script = "..\esp\main.py", 
    initScript = None, 
    base = 'Win32GUI', 
    targetDir = r"dist", 
    targetName = "acup_new.exe", 
    compress = True, 
    copyDependentFiles = True, 
    appendScriptToExe = False, 
    appendScriptToLibrary = False, 
    icon = None 
    ) 

setup(

    version = "0.1", 
    description = "No Description", 
    author = "No Author", 
    name = "cx_Freeze Sample File", 

    options = {"build_exe": {"includes": includes, 
       "excludes": excludes, 
       "packages": packages, 
       "path": path 
       } 
      }, 

    executables = [GUI2Exe_Target_1] 
    ) 

उत्तर

1

पर this question आधार पर, यह आप की तरह अपने setup.py फ़ाइल में includes[] सूची में इन मॉड्यूल जोड़ने की आवश्यकता हो सकती है।

मुझे cx_Freeze का उपयोग करते समय ऐसा करने की याद नहीं है, लेकिन एक बार मुझे अधिक जानकारी मिल सकती है, लेकिन मैं इस जवाब को संपादित कर दूंगा।

संबंधित मुद्दे