"""
Auto-generated Python stub file from lib.core.BuildPipeline.py
Module: lib.core.BuildPipeline
"""


import t, c
from stdint import *
import stdio
import string
import stdlib
import memhub
import w32.fileio as fileio
import w32.win32file
import w32.win32base
import subprocess
import viperlib
import ast
import lib.core.Handles.HandlesTranslator as HandlesTranslator
import lib.core.Handles.HandlesStruct as HandlesStruct
import lib.core.Handles.HandlesType as HandlesType
import lib.core.Handles.HandlesImports as HandlesImports

_mbuddy: t.CExtern | memhub.MemManager | t.CPtr
SRC_BUF_SIZE: t.CDefine = 1048576

def TranslateFileGetTrans(mb: memhub.MemBuddy | t.CPtr, file_path: str, sha1_val: str, current_package: str) -> HandlesTranslator.Translator | t.CPtr: pass


class BuildResult:
    Success: t.CInt
    OutputPath: str
    ErrorMsg: str
    def __new__(self: BuildResult) -> t.CPtr: pass
    def __init__(self: BuildResult) -> t.CInt: pass

def ensure_dir(path: str) -> int: pass

def write_ir_to_file(ir_buf: bytes, ir_len: t.CSizeT, output_dir: str, module_name: str) -> int: pass

def compile_ll_to_obj(ir_path: str, output_dir: str, module_name: str, cc_cmd: str, cc_flags: str) -> int: pass

def collect_obj_files(includes_binary_dir: str, out_buf: bytes, out_size: t.CSizeT) -> t.CSizeT: pass

def link_obj_to_exe(output_dir: str, module_name: str, linker_cmd: str, linker_flags: str, linker_output: str, includes_binary_dir: str) -> int: pass

def compile_module_to_obj(ir_buf: bytes, ir_len: t.CSizeT, temp_dir: str, output_dir: str, module_name: str, cc_cmd: str, cc_flags: str) -> int: pass

def link_objs_to_exe(obj_paths: str, obj_paths_len: t.CSizeT, linker_cmd: str, linker_flags: str, linker_output: str, includes_binary_dir: str) -> int: pass

def run_pipeline(ir_buf: bytes, ir_len: t.CSizeT, temp_dir: str, output_dir: str, module_name: str, cc_cmd: str, cc_flags: str, linker_cmd: str, linker_flags: str, linker_output: str, includes_binary_dir: str) -> BuildResult | t.CPtr: pass
