Open
Conversation
Move OpenVINO and GenAI version resolution from macros in version.hpp to runtime functions in version.cpp. GenAI version is conditionally compiled using MEDIAPIPE_DISABLE define. Split libovms_version into header-only target (zero deps) and libovms_version_impl (openvino + conditional genai, alwayslink=1) to avoid blocking parallel builds and fix linker error when building with --config mp_off_py_off.
Contributor
There was a problem hiding this comment.
Pull request overview
Moves OpenVINO/GenAI version resolution from header macros to runtime functions to fix build/link issues in mp_off_py_off and improve parallel builds.
Changes:
- Replaced
OPENVINO_NAME/GENAI_NAMEmacros withovms::getOpenvinoVersion()/ovms::getGenaiVersion()functions. - Added
src/version.cppwith conditional GenAI compilation behindMEDIAPIPE_DISABLE. - Split Bazel target into
libovms_version(header-only) andlibovms_version_impl(OpenVINO/GenAI impl, alwayslink).
Reviewed changes
Copilot reviewed 6 out of 6 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| src/version.hpp | Removes OpenVINO/GenAI includes + version macros; exposes runtime version function declarations |
| src/version.cpp | Implements runtime version resolution with conditional GenAI support |
| src/server.cpp | Switches logging to runtime OpenVINO version function |
| src/cli_parser.cpp | Switches --version output to runtime OpenVINO/GenAI version functions |
| src/capi_frontend/capi.cpp | Switches metadata ov_version to runtime OpenVINO version function |
| src/BUILD | Splits version library into header-only + impl target and links impl into main library |
You can also share your feedback on Copilot code review. Take the survey.
Contributor
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 8 out of 8 changed files in this pull request and generated 1 comment.
You can also share your feedback on Copilot code review. Take the survey.
rasapala
approved these changes
Mar 11, 2026
dkalinowski
reviewed
Mar 11, 2026
| ss << "OpenVINO backend " << OPENVINO_NAME << std::endl; | ||
| ss << "OpenVINO GenAI backend " << GENAI_NAME << std::endl; | ||
| ss << "OpenVINO backend " << ovms::getOpenVINOVersion() << std::endl; | ||
| const char* genaiVersion = ovms::getGenAIVersion(); |
Collaborator
There was a problem hiding this comment.
Why couldnt getGenAIVersion return std::string? This way you dont need to rely on zero-terminated string, but simply call genaiVersion.empty()
dkalinowski
approved these changes
Mar 11, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Move OpenVINO and GenAI version resolution from macros in version.hpp to runtime functions in version.cpp. GenAI version is conditionally compiled using MEDIAPIPE_DISABLE define.
Split libovms_version into header-only target (zero deps) and libovms_version_impl (openvino + conditional genai, alwayslink=1) to avoid blocking parallel omponents builds and fix linker error when building with --config mp_off_py_off.