From e4ca83dbc9005f170a037e51176164c0b0a2b2b6 Mon Sep 17 00:00:00 2001 From: Valentin Date: Thu, 5 Dec 2024 10:27:32 +0100 Subject: [PATCH] WIP - trying to make python work in CI --- lib/app/cmake/library.cmake | 26 +++++++++++++------------- lib/app/conanfile.py | 10 +++++----- lib/python_binding/cmake/library.cmake | 2 +- lib/renderer/conanfile.py | 2 +- 4 files changed, 20 insertions(+), 20 deletions(-) diff --git a/lib/app/cmake/library.cmake b/lib/app/cmake/library.cmake index 1bcf421a6..b9f3611c9 100644 --- a/lib/app/cmake/library.cmake +++ b/lib/app/cmake/library.cmake @@ -8,10 +8,10 @@ target_sources(vtx_app PRIVATE ${SOURCES} PUBLIC FILE_SET public_headers TYPE HEADERS BASE_DIRS "${CMAKE_CURRENT_LIST_DIR}/../include" FILES ${HEADERS}) -add_library(vtx_app_no_opengl) -configure_target(vtx_app_no_opengl) +add_library(poneyponey) +configure_target(poneyponey) -target_sources(vtx_app_no_opengl +target_sources(poneyponey PRIVATE ${SOURCES} PUBLIC FILE_SET public_headers TYPE HEADERS BASE_DIRS "${CMAKE_CURRENT_LIST_DIR}/../include" FILES ${HEADERS}) @@ -33,10 +33,10 @@ if (NOT DEFINED _VTX_APP_CONAN) target_link_libraries(vtx_app PRIVATE vtx_renderer) target_link_libraries(vtx_app PRIVATE vtx_core) target_link_libraries(vtx_app PRIVATE vtx_io) - target_link_libraries(vtx_app_no_opengl PRIVATE vtx_util) - target_link_libraries(vtx_app_no_opengl PRIVATE vtx_renderer_no_opengl) - target_link_libraries(vtx_app_no_opengl PRIVATE vtx_core) - target_link_libraries(vtx_app_no_opengl PRIVATE vtx_io) + target_link_libraries(poneyponey PRIVATE vtx_util) + target_link_libraries(poneyponey PRIVATE vtx_renderer_no_opengl) + target_link_libraries(poneyponey PRIVATE vtx_core) + target_link_libraries(poneyponey PRIVATE vtx_io) target_link_libraries(vtx_app_test PRIVATE vtx_util) target_link_libraries(vtx_app_test PRIVATE vtx_renderer_no_opengl) target_link_libraries(vtx_app_test PRIVATE vtx_core) @@ -46,10 +46,10 @@ else() target_link_libraries(vtx_app PUBLIC vtx_renderer::vtx_renderer) target_link_libraries(vtx_app PRIVATE vtx_core::vtx_core) target_link_libraries(vtx_app PRIVATE vtx_io::vtx_io) - target_link_libraries(vtx_app_no_opengl PRIVATE vtx_util::vtx_util) - target_link_libraries(vtx_app_no_opengl PUBLIC vtx_renderer::vtx_renderer_no_opengl) - target_link_libraries(vtx_app_no_opengl PRIVATE vtx_core::vtx_core) - target_link_libraries(vtx_app_no_opengl PRIVATE vtx_io::vtx_io) + target_link_libraries(poneyponey PRIVATE vtx_util::vtx_util) + target_link_libraries(poneyponey PUBLIC vtx_renderer::vtx_renderer_no_opengl) + target_link_libraries(poneyponey PRIVATE vtx_core::vtx_core) + target_link_libraries(poneyponey PRIVATE vtx_io::vtx_io) target_link_libraries(vtx_app_test PRIVATE vtx_util::vtx_util) target_link_libraries(vtx_app_test PUBLIC vtx_renderer::vtx_renderer_no_opengl) target_link_libraries(vtx_app_test PRIVATE vtx_core::vtx_core) @@ -57,8 +57,8 @@ else() endif() target_link_libraries(vtx_app PUBLIC EnTT::EnTT) -target_link_libraries(vtx_app_no_opengl PUBLIC EnTT::EnTT) -target_link_libraries(vtx_app_test PRIVATE vtx_app_no_opengl) +target_link_libraries(poneyponey PUBLIC EnTT::EnTT) +target_link_libraries(vtx_app_test PRIVATE poneyponey) target_link_libraries(vtx_app_test PRIVATE Catch2::Catch2WithMain) vtx_register_build_directory_copy("${CMAKE_CURRENT_LIST_DIR}/../data" "./data") diff --git a/lib/app/conanfile.py b/lib/app/conanfile.py index ac0f89bed..bc283fb59 100644 --- a/lib/app/conanfile.py +++ b/lib/app/conanfile.py @@ -30,7 +30,7 @@ def layout(self): cmake_layout(self) self.cpp.build.components["vtx_app"].libdirs = self.cpp.build.libdirs - self.cpp.build.components["vtx_app_no_opengl"].libdirs = self.cpp.build.libdirs + self.cpp.build.components["poneyponey"].libdirs = self.cpp.build.libdirs def generate(self): tc = CMakeToolchain(self) @@ -56,11 +56,11 @@ def package_info(self): self.cpp_info.components["vtx_app"].set_property("cmake_target_name", "vtx_app::vtx_app") self.cpp_info.components["vtx_app"].requires = ["vtx_util::vtx_util", "vtx_renderer::vtx_renderer", "vtx_io::vtx_io", "vtx_core::vtx_core", "entt::entt" ] - self.cpp_info.components["vtx_app_no_opengl"].libs = ["vtx_app_no_opengl"] - self.cpp_info.components["vtx_app_no_opengl"].set_property("cmake_target_name", "vtx_app::vtx_app_no_opengl") - self.cpp_info.components["vtx_app_no_opengl"].requires = ["vtx_util::vtx_util", "vtx_renderer::vtx_renderer_no_opengl", "vtx_io::vtx_io", "vtx_core::vtx_core", "entt::entt" ] + self.cpp_info.components["poneyponey"].libs = ["poneyponey"] + self.cpp_info.components["poneyponey"].set_property("cmake_target_name", "vtx_app::poneyponey") + self.cpp_info.components["poneyponey"].requires = ["vtx_util::vtx_util", "vtx_renderer::vtx_renderer_no_opengl", "vtx_io::vtx_io", "vtx_core::vtx_core", "entt::entt" ] # self.cpp_info.components["vtx_app_test"].libs = ["vtx_app_test"] # self.cpp_info.components["vtx_app_test"].set_property("cmake_target_name", "vtx_app::vtx_app_test") - self.cpp_info.components["vtx_app_test"].requires = [ "vtx_app_no_opengl", "catch2::catch2" ] + self.cpp_info.components["vtx_app_test"].requires = [ "poneyponey", "catch2::catch2" ] diff --git a/lib/python_binding/cmake/library.cmake b/lib/python_binding/cmake/library.cmake index 4aa2c4055..44cde3c91 100644 --- a/lib/python_binding/cmake/library.cmake +++ b/lib/python_binding/cmake/library.cmake @@ -49,7 +49,7 @@ else() target_link_libraries(vtx_python_binding_test PRIVATE vtx_util::vtx_util) target_link_libraries(vtx_python_binding_test PRIVATE vtx_core::vtx_core) target_link_libraries(vtx_python_binding_test PRIVATE vtx_io::vtx_io) - target_link_libraries(vtx_python_binding_test PRIVATE vtx_app::vtx_app_no_opengl) + target_link_libraries(vtx_python_binding_test PRIVATE vtx_app::poneyponey) endif() # TODO : are those lines usefull ? diff --git a/lib/renderer/conanfile.py b/lib/renderer/conanfile.py index f12791318..3ebf60f4a 100644 --- a/lib/renderer/conanfile.py +++ b/lib/renderer/conanfile.py @@ -56,7 +56,7 @@ def package_info(self): self.cpp_info.components["vtx_renderer_no_opengl"].libs = ["vtx_renderer_no_opengl"] self.cpp_info.components["vtx_renderer_no_opengl"].set_property("cmake_target_name", "vtx_renderer::vtx_renderer_no_opengl") - self.cpp_info.components["vtx_renderer_no_opengl"].requires = ["vtx_util::vtx_util"] + # self.cpp_info.components["vtx_renderer_no_opengl"].requires = ["vtx_util::vtx_util"] #self.cpp_info.components["vtx_renderer_no_opengl"].includedirs = ["include"] self.cpp_info.components["vtx_renderer_test"].requires = ["catch2::catch2"]