Пример #1
0
def getResultBasepath():
    if Options.isStandaloneMode():
        return os.path.join(
            getStandaloneDirectoryPath(),
            os.path.basename(getTreeFilenameWithSuffix(_main_module, "")),
        )
    else:
        return Options.getOutputPath(
            path=os.path.basename(getTreeFilenameWithSuffix(_main_module, "")))
Пример #2
0
def getSourceDirectoryPath():
    """Return path inside the build directory."""

    result = Options.getOutputPath(path=os.path.basename(
        getTreeFilenameWithSuffix(_main_module, ".build")))

    makePath(result)

    return result
Пример #3
0
def getResultBasepath(onefile=False):
    if Options.isOnefileMode() and onefile:
        file_path = os.path.basename(
            getTreeFilenameWithSuffix(_main_module, ""))

        if Options.shallCreateAppBundle():
            file_path = os.path.join(file_path + ".app", "Contents", "MacOS",
                                     file_path)

        return Options.getOutputPath(path=file_path)
    elif Options.isStandaloneMode() and not onefile:
        return os.path.join(
            getStandaloneDirectoryPath(),
            os.path.basename(getTreeFilenameWithSuffix(_main_module, "")),
        )
    else:
        return Options.getOutputPath(
            path=os.path.basename(getTreeFilenameWithSuffix(_main_module, "")))
Пример #4
0
def getStandaloneDirectoryPath(bundle=True):
    assert Options.isStandaloneMode()

    result = Options.getOutputPath(path=os.path.basename(
        getTreeFilenameWithSuffix(_main_module, _getStandaloneDistSuffix(
            bundle))))

    if bundle and Options.shallCreateAppBundle(
    ) and not Options.isOnefileMode():
        result = os.path.join(result, "Contents", "MacOS")

    return result
Пример #5
0
def getSourceDirectoryPath(onefile=False):
    """Return path inside the build directory."""

    # Distinct build folders for oneline mode.
    if onefile:
        suffix = ".onefile-build"
    else:
        suffix = ".build"

    result = Options.getOutputPath(
        path=os.path.basename(getTreeFilenameWithSuffix(_main_module, suffix)))

    makePath(result)

    return result
Пример #6
0
def getStandaloneDirectoryPath():
    return Options.getOutputPath(path=os.path.basename(
        getTreeFilenameWithSuffix(_main_module, ".dist")))