liblwip: Fix lwIP search path The CMAKE_SOURCE_DIR is not always in the root of the entire project i.e. where '.repo' is located, so we instead use a relative path from the current CMakeLists.txt directory.
diff --git a/liblwip/CMakeLists.txt b/liblwip/CMakeLists.txt index 47ece6a..5f186a2 100644 --- a/liblwip/CMakeLists.txt +++ b/liblwip/CMakeLists.txt
@@ -19,7 +19,8 @@ mark_as_advanced(LibLwip) add_config_library(lwip "${configure_string}") if(LibLwip) - find_file(LWIP_PATH lwip PATHS ${CMAKE_SOURCE_DIR}/projects CMAKE_FIND_ROOT_PATH_BOTH) + set(projects_dir "${CMAKE_CURRENT_LIST_DIR}/../..") + find_file(LWIP_PATH lwip PATHS ${projects_dir} CMAKE_FIND_ROOT_PATH_BOTH) mark_as_advanced(FORCE LWIP_PATH) if("${LWIP_PATH}" STREQUAL "LWIP_PATH-NOTFOUND") message(FATAL_ERROR "Failed to find lwIP. Consider cmake -DLWIP_PATH=/path/to/lwip")