Skip to content

Conversation

@titaiwangms
Copy link
Contributor

@titaiwangms titaiwangms commented Nov 14, 2025

Description

NOTE: Need #26597

Motivation and Context

@titaiwangms titaiwangms added the dependencies Pull requests that update a dependency file label Nov 14, 2025
@titaiwangms titaiwangms linked an issue Nov 18, 2025 that may be closed by this pull request
@snnn
Copy link
Member

snnn commented Nov 18, 2025

There appears to be a gap in the vcpkg configuration for native Linux builds regarding the protobuf library version.

The generated triplet file (e.g., x64-linux.cmake) does not currently receive a setting for ONNX_USE_LITE_PROTO.

This is because the logic in tools/python/util/vcpkg_helpers.py that adds -DONNX_USE_LITE_PROTO=ON is specific to WebAssembly builds, as shown in the add_port_configs function:

    if is_emscripten:
        # Uses ONNX_USE_LITE_PROTO=ON for WebAssembly build.
        f.write(
            r"""
    list(APPEND VCPKG_CMAKE_CONFIGURE_OPTIONS
        "-DONNX_USE_LITE_PROTO=ON"
    )"""
        )

For native Linux builds, is_emscripten is False, so this block is skipped. As a result, the onnx dependency falls back to its default (ONNX_USE_LITE_PROTO=OFF), causing a mismatch with the ONNX Runtime default build which expects the lite version. This should be addressed to ensure native builds are configured correctly.

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

Labels

dependencies Pull requests that update a dependency file

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Integrate with ONNX 1.20.0 release branch

3 participants