The CMake find_package statements fail on Fedora 41. By applying the following patch and symbolic link I am able to build.
The nlohmann_json module is a single header (json.hpp) so it would be great if that was simply added to the YSCE repository (in src/common?) rather than being an external dependency that developers need to track down.
The Curl header & library are in the standard system directories so I would expect that to just work.
Anyway, here's my hack to work around these issues:
ln -s ../json/include/nlohmann YSFLIGHT/src/common
diff --git a/src/gui/CMakeLists.txt b/src/gui/CMakeLists.txt
index f37dac4..a894fea 100644
--- a/src/gui/CMakeLists.txt
+++ b/src/gui/CMakeLists.txt
@@ -25,11 +25,11 @@ fsguimaincanvas.h
fsguisiminfodialog.h
)
-find_package(CURL CONFIG REQUIRED)
-find_package(nlohmann_json CONFIG REQUIRED)
+#find_package(CURL CONFIG REQUIRED)
+#find_package(nlohmann_json CONFIG REQUIRED)
add_library(${TARGET_NAME} ${SRCS} ${HEADERS})
target_link_libraries(${TARGET_NAME} ${LIB_DEPENDENCY})
-target_link_libraries(${TARGET_NAME} ${LIB_DEPENDENCY} CURL::libcurl)
-target_link_libraries(${TARGET_NAME} ${LIB_DEPENDENCY} nlohmann_json::nlohmann_json)
+target_link_libraries(${TARGET_NAME} ${LIB_DEPENDENCY} curl)
+#target_link_libraries(${TARGET_NAME} ${LIB_DEPENDENCY} nlohmann_json::nlohmann_json)
target_include_directories(${TARGET_NAME} PUBLIC ${CMAKE_CURRENT_SOURCE_DIR})
The CMake find_package statements fail on Fedora 41. By applying the following patch and symbolic link I am able to build.
The nlohmann_json module is a single header (json.hpp) so it would be great if that was simply added to the YSCE repository (in src/common?) rather than being an external dependency that developers need to track down.
The Curl header & library are in the standard system directories so I would expect that to just work.
Anyway, here's my hack to work around these issues: