microsoft / microsoft/onnxruntime

[Build] CMake configurations files for bin release 1.22.0 are broken for Linux

Open
#25,279 12 comments 2 reactions 0 assignees View on GitHub
build
Dominant language
C++
Stars
21.9k
Forks
4.2k
Avg merge
4d 11h
Merged PRs (30d)
184

Description

### Describe the issue

Linux binaries provide CMake files to configure the project. However, the path to the lib files is wrong.
The SO is expected to be in the lib64 folder while the actual name is lib. As a workaround I renamed the folder but the CMake file could also be updated.

### Urgency

_No response_

### Target platform

Linux

### Build script

find_package to onnxruntime

### Error / output

CMake Error at /home/someone/Documents/onnx/onnxruntime-linux-x64-1.22.0/lib/cmake/onnxruntime/onnxruntimeTargets.cmake:83 (message):
The imported target "onnxruntime::onnxruntime" references the file "/home/someone/Documents/onnx/onnxruntime-linux-x64-1.22.0/lib64/libonnxruntime.so.1.22.0" but this file does not exist.

### Visual Studio Version

_No response_

### GCC / Compiler Version

_No response_

Contributor guide

Open the contributing guide

Research direction

Start with the installed lib/cmake/onnxruntime/onnxruntimeTargets.cmake referenced in the error and trace how the Linux release CMake package is generated. Verify the find_package(onxxruntime) configuration against the release layout, then confirm the imported target points to the existing lib directory and works with the 1.22.0 Linux binary.

Written by the indexing model from the issue text.

Assessment

Tech stack
cmake, cpp
Domain
build-system
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
64/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.