import type { Environment } from "../../env";
import { type FnCallExpr } from "../../expr";
import type { EvaluatorContext } from "../context";
export interface BuildArtifact {
    kind: "executable" | "static_library" | "shared_library";
    name: string;
    root: string;
    target: string;
    optimize: string;
    allocator: string;
    sanitize: string;
    linkLibraries: string[];
    includePaths: string[];
    libraryPaths: string[];
    cSources: string[];
    cFlags: string[];
    defines: string[];
    strip: boolean;
    staticLink: boolean;
    runtimeFiles?: string[];
    linkedArtifacts: string[];
    linkedSystemLibraries: string[];
    importedModules: ImportedModule[];
}
export interface BuildTestSuite {
    name: string;
    root: string;
    target: string;
    verbose: boolean;
    bail: boolean;
    parallel: number;
}
export interface BuildRunStep {
    name: string;
    artifactName: string;
    args: string[];
}
export interface BuildStep {
    name: string;
    description: string;
    dependencyNames: string[];
}
export interface BuildGitDependency {
    name: string;
    url: string;
    ref: string;
    path: string;
}
export interface BuildPathDependency {
    name: string;
    path: string;
}
export interface BuildSystemLibrary {
    name: string;
    fallbackInclude: string;
    fallbackLib: string;
    fallbackLink: string;
    defines?: string[];
}
export interface DependencyArtifactRef {
    dependencyName: string;
    artifactName: string;
}
export interface BuildModuleEntry {
    name: string;
    root: string;
    linkedSystemLibraries: string[];
}
export interface ImportedModule {
    importName: string;
    moduleName: string;
    dependencyName: string;
    resolvedRoot?: string;
    propagatedSystemLibraries?: string[];
}
export interface BuildDocConfig {
    name: string;
    root: string;
    outputDir: string;
    format: string;
    includePrivate: boolean;
    includeDeps: boolean;
    title: string;
    logo: string;
    favicon: string;
    version: string;
}
export declare class BuildRegistry {
    artifacts: BuildArtifact[];
    testSuites: BuildTestSuite[];
    runSteps: BuildRunStep[];
    steps: BuildStep[];
    dependencies: BuildGitDependency[];
    pathDependencies: BuildPathDependency[];
    systemLibraries: BuildSystemLibrary[];
    dependencyArtifacts: DependencyArtifactRef[];
    modules: BuildModuleEntry[];
    docConfigs: BuildDocConfig[];
    cliOptions: Map<string, string>;
    declaredOptions: Map<string, {
        description: string;
        defaultValue: string;
    }>;
    setCliOptions(options: Map<string, string>): void;
    registerExecutable(config: Omit<BuildArtifact, "kind">): void;
    registerStaticLibrary(config: Omit<BuildArtifact, "kind">): void;
    registerSharedLibrary(config: Omit<BuildArtifact, "kind">): void;
    registerTest(config: BuildTestSuite): void;
    registerRun(artifactName: string, args: string[]): void;
    registerStep(name: string, description: string, dependencyNames?: string[]): void;
    addStepDependency(stepName: string, depName: string): void;
    registerDependency(dep: BuildGitDependency): void;
    registerPathDependency(dep: BuildPathDependency): void;
    registerSystemLibrary(lib: BuildSystemLibrary): void;
    registerDependencyArtifact(ref: DependencyArtifactRef): void;
    registerModule(entry: BuildModuleEntry): void;
    registerModuleLink(moduleName: string, systemLibraryName: string): void;
    registerImportedModule(artifactName: string, imported: ImportedModule): void;
    findModule(name: string): BuildModuleEntry | undefined;
    registerLink(artifactName: string, libraryName: string): void;
    findArtifact(name: string): BuildArtifact | undefined;
    findTest(name: string): BuildTestSuite | undefined;
    findRunStep(name: string): BuildRunStep | undefined;
    findStep(name: string): BuildStep | undefined;
    findDocumentation(name: string): BuildDocConfig | undefined;
    registerDocumentation(config: BuildDocConfig): void;
    private checkDuplicateArtifactName;
    findDependency(name: string): BuildGitDependency | undefined;
    findPathDependency(name: string): BuildPathDependency | undefined;
    findSystemLibrary(name: string): BuildSystemLibrary | undefined;
    getStepNames(): string[];
    resolveDependency(name: string): {
        kind: "artifact";
        value: BuildArtifact;
    } | {
        kind: "test";
        value: BuildTestSuite;
    } | {
        kind: "run";
        value: BuildRunStep;
    } | {
        kind: "doc";
        value: BuildDocConfig;
    } | {
        kind: "step";
        value: BuildStep;
    } | undefined;
    resolveDependencies(step: BuildStep): {
        artifacts: BuildArtifact[];
        tests: BuildTestSuite[];
        runs: BuildRunStep[];
    };
    clear(): void;
}
export declare function getRootBuildProjectDir(): string | undefined;
export declare function setRootBuildProjectDir(dir: string | undefined): void;
export declare function clearModuleImportRoots(): void;
export declare function getModuleImportRoot(importName: string): string | undefined;
export declare function setModuleImportRoot(importName: string, resolvedRoot: string): void;
export declare function getBuildRegistry(): BuildRegistry;
export declare function clearBuildRegistry(): void;
export declare function swapBuildRegistry(newRegistry: BuildRegistry | undefined): BuildRegistry | undefined;
export declare function evaluateYoBuildFunctions({ expr, env, }: {
    expr: FnCallExpr;
    env: Environment;
    context: EvaluatorContext;
}): FnCallExpr;
