package(default_visibility = ["//visibility:public"])

platform(
    name = "x86_64-pc-windows-msvc",
    constraint_values = [
        "@platforms//cpu:x86_64",
        "@platforms//os:windows",
    ],
)

# ============================================================================
# CEL Static Library
# ============================================================================
# IMPORTANT: This rule is experimental and requires the
# --experimental_cc_static_library Bazel flag to be enabled during the build.
cc_static_library(
    name = "cel",  # This target will produce libcel.a
    deps = [
        # For absl::InitializeLog()
        "@com_google_absl//absl/log:initialize",

        # compiler
        "@cel-cpp//compiler:compiler",
        "@cel-cpp//compiler:compiler_factory",
        "@cel-cpp//compiler:optional",
        "@cel-cpp//compiler:standard_library",
        "@cel-cpp//compiler:compiler_library_subset_factory",

        # runtime
        "@cel-cpp//runtime:runtime",
        "@cel-cpp//runtime:runtime_builder_factory",
        "@cel-cpp//runtime:standard_functions",
        "@cel-cpp//runtime:optional_types",
        "@cel-cpp//runtime:regex_precompilation",
        "@cel-cpp//runtime:comprehension_vulnerability_check",
        "@cel-cpp//runtime:constant_folding",

        # extensions
        "@cel-cpp//extensions:encoders",
        "@cel-cpp//extensions:proto_ext",
        "@cel-cpp//extensions:math_ext",
        "@cel-cpp//extensions:math_ext_macros",
        "@cel-cpp//extensions:math_ext_decls",
        "@cel-cpp//extensions:regex_functions",
        "@cel-cpp//extensions:regex_ext",
        "@cel-cpp//extensions:bindings_ext",
        "@cel-cpp//extensions:select_optimization",
        "@cel-cpp//extensions:lists_functions",
        "@cel-cpp//extensions:sets_functions",
        "@cel-cpp//extensions:strings",
        "@cel-cpp//extensions:comprehensions_v2_functions",
        "@cel-cpp//extensions:comprehensions_v2_macros",
        "@cel-cpp//extensions:formatting",
    ],
)
