I have set up a C++ project using Conan and Cmake. I have executed the following commands:
conan install . --install-folder cmake-build-release --build=missing
cmake . -DCMAKE_TOOLCHAIN_FILE=cmake-build-release/conan_toolchain.cmake
cmake --build .
When building my main.cpp I get the following error:
/mnt/f/Projekte/rmldemo/src/main.cpp:1:24: fatal error: RmlUi/Core.h: No such file or directory
^
compilation terminated.
CMakeFiles/rmlui_project.dir/build.make:75: recipe for target 'CMakeFiles/rmlui_project.dir/src/main.cpp.o' failed
make[2]: *** [CMakeFiles/rmlui_project.dir/src/main.cpp.o] Error 1
CMakeFiles/Makefile2:82: recipe for target 'CMakeFiles/rmlui_project.dir/all' failed
make[1]: *** [CMakeFiles/rmlui_project.dir/all] Error 2
Makefile:90: recipe for target 'all' failed
make: *** [all] Error 2
My CmakeLists.txt:
cmake_minimum_required(VERSION 3.15)
project(rmlui_project CXX)
find_package(rmlui)
add_executable(${PROJECT_NAME} src/main.cpp)
# Use the global target
target_link_libraries(${PROJECT_NAME} rmlui::rmlui)
My conanfile.txt:
[requires]
rmlui/4.3
[generators]
CMakeDeps
CMakeToolchain
My main.cpp:
#include <RmlUi/Core.h>
#include <RmlUi/Core/StreamMemory.h>
#include <RmlUi/Core/TransformPrimitive.h>
#include <RmlUi/Debugger.h>
#include "Backends/RmlUi_Backend.h"
#include "Shell/Shell.h"