| Issue |
53134
|
| Summary |
Failed to pick up MLIR installation from `MLIRConfig.cmake`
|
| Labels |
new issue
|
| Assignees |
|
| Reporter |
jackalcooper
|
- I am trying to setup a VSCode devcontainer with MLIR pre-built.
- This is my dockerfile and CMakeLists.txt. Very basic stuff:
```
FROM elixir
RUN apt update && apt install -y lsb-release wget software-properties-common
RUN wget https://apt.llvm.org/llvm.sh && chmod +x llvm.sh && ./llvm.sh 14
RUN apt update && apt install -y cmake ccache ninja-build libmlir-14-dev mlir-14-tools
```
```
cmake_minimum_required(VERSION 3.13.4)
project(standalone-dialect LANGUAGES CXX C)
set(CMAKE_BUILD_WITH_INSTALL_NAME_DIR ON)
set(CMAKE_CXX_STANDARD 14 CACHE STRING "C++ standard to conform to")
find_package(MLIR REQUIRED CONFIG)
```
- After running cmake (`cmake .. -DMLIR_DIR=$(llvm-config-14 --libdir)/cmake/mlir`):
```
CMake Error at /usr/lib/llvm-14/lib/cmake/mlir/MLIRTargets.cmake:1563 (message):
The imported target "obj.MLIRCAPIDebug" references the file
"/usr/lib/llvm-14/lib/objects-Release/obj.MLIRCAPIDebug/Debug.cpp.o"
but this file does not exist. Possible reasons include:
* The file was deleted, renamed, or moved to another location.
* An install or uninstall procedure did not complete successfully.
* The installation package was faulty and contained
"/usr/lib/llvm-14/lib/cmake/mlir/MLIRTargets.cmake"
but not all the files it references.
Call Stack (most recent call first):
/usr/lib/llvm-14/lib/cmake/mlir/MLIRConfig.cmake:30 (include)
llvm-built/CMakeLists.txt:8 (find_package)
-- Configuring incomplete, errors occurred!
See also "/workspaces/mlir_ex/cmake-build-dev/CMakeFiles/CMakeOutput.log".
```
- Note: RelWithDebInfo/ Release/ Debug `CMAKE_BUILD_TYPE` all tested, no difference. Couldn't find `Debug.cpp.o` anywhere after running `find`.
_______________________________________________
llvm-bugs mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs