Skip to content

Example of packaging app using cx_Freeze #338

Open

Activity

  1. changed the title [-]Example of packaging using cx_Freeze[/-] [+]Example of packaging app using cx_Freeze[/+] on Mar 25, 2017
  2. josephmartin09 commented on Jun 19, 2018

    @josephmartin09

    I got somewhere with this one Windows. Happy to formalize this into a detailed example if needed.

    Zip Installer is obtained by

    python setup.py bdist
    

    MSI Installer is obtained by

    python setup.py bdist_msi
    
    #setup.py
    from distutils.sysconfig import get_python_lib
    from os.path import join
    from glob import glob
    from cx_Freeze import setup, Executable
    
    # Basically just copy all of the CEF distribution into the installer
    # I have only tested this on windows
    cefPath = join(get_python_lib(), "cefpython3")
    CEF_INCLUDES = glob(join(cefPath, "*"))
    CEF_INCLUDES.remove(join(cefPath, "examples"))
    
    setup(
        name = "MyAppName",
        version = "1.0.0",
        options = {
            "build_exe": {
            'packages': ["os","sys","ctypes","win32con", "json"],
            'include_files': CEF_INCLUDES + ['otherResourceFolder'],
            'include_msvcr': True,
        }},
        executables = [Executable("app.py", base="Win32GUI")]
    )
  3. 846948768 commented on Jun 7, 2019

    @846948768

    @josephmartin09 In order to thank you, I specially registered this account, you are so powerful! thank you again~

  4. Berserker66 commented on May 11, 2021

    @Berserker66

    This appears to no longer work:
    [0511/153708.613:ERROR:icu_util.cc(172)] Invalid file descriptor to ICU data received.
    Completely deleting icudtl.dat gives the same error. Likely the path to the file is build in an incompatible way.

  5. FeralFox commented on Feb 17, 2022

    @FeralFox

    This appears to no longer work:
    [0511/153708.613:ERROR:icu_util.cc(172)] Invalid file descriptor to ICU data received.

    I got the same error using PyInstaller.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions