CMake build system: It is now sufficient to set LWIP_DIR for build

This commit is contained in:
Dirk Ziegelmeier 2018-10-02 12:54:56 +02:00
parent 4b672a1f3c
commit 04ff7926e7
5 changed files with 10 additions and 16 deletions

View File

@ -1,3 +1,5 @@
set(LWIP_CONTRIB_DIR ${LWIP_DIR}/contrib)
# ARM mbedtls support https://tls.mbed.org/ # ARM mbedtls support https://tls.mbed.org/
set(MBEDTLSDIR ${LWIP_DIR}/../mbedtls) set(MBEDTLSDIR ${LWIP_DIR}/../mbedtls)
if(EXISTS ${MBEDTLSDIR}/CMakeLists.txt) if(EXISTS ${MBEDTLSDIR}/CMakeLists.txt)

View File

@ -6,11 +6,9 @@ if (NOT CMAKE_SYSTEM_NAME STREQUAL Linux AND NOT CMAKE_SYSTEM_NAME STREQUAL Darw
message(FATAL_ERROR "Unit test are currently only working on Linux or Darwin") message(FATAL_ERROR "Unit test are currently only working on Linux or Darwin")
endif() endif()
set(LWIP_CONTRIB_DIR ${CMAKE_CURRENT_SOURCE_DIR}/../../..) set(LWIP_DIR ${CMAKE_CURRENT_SOURCE_DIR}/../../../..)
set(LWIP_DIR ${LWIP_CONTRIB_DIR}/..)
set(LWIP_USE_SANITIZERS true) set(LWIP_USE_SANITIZERS true)
include(${LWIP_CONTRIB_DIR}/ports/CMakeCommon.cmake) include(${LWIP_DIR}/contrib/ports/CMakeCommon.cmake)
if(CMAKE_C_COMPILER_ID STREQUAL Clang) if(CMAKE_C_COMPILER_ID STREQUAL Clang)
# check.h causes 'error: token pasting of ',' and __VA_ARGS__ is a GNU extension' with clang 9.0.0 # check.h causes 'error: token pasting of ',' and __VA_ARGS__ is a GNU extension' with clang 9.0.0

View File

@ -4,10 +4,8 @@ project(example_app C)
set (CMAKE_EXPORT_COMPILE_COMMANDS ON) set (CMAKE_EXPORT_COMPILE_COMMANDS ON)
set(LWIP_CONTRIB_DIR ${CMAKE_CURRENT_SOURCE_DIR}/../../..) set(LWIP_DIR ${CMAKE_CURRENT_SOURCE_DIR}/../../../..)
set(LWIP_DIR ${LWIP_DIR}/..) include(${LWIP_DIR}/contrib/ports/CMakeCommon.cmake)
include(${LWIP_CONTRIB_DIR}/ports/CMakeCommon.cmake)
set (LWIP_DEFINITIONS -DLWIP_DEBUG) set (LWIP_DEFINITIONS -DLWIP_DEBUG)
set (LWIP_INCLUDE_DIRS set (LWIP_INCLUDE_DIRS

View File

@ -8,10 +8,8 @@ if (NOT CMAKE_SYSTEM_NAME STREQUAL Linux AND NOT CMAKE_SYSTEM_NAME STREQUAL GNU)
message(FATAL_ERROR "Lwip shared library is only working on Linux or the Hurd") message(FATAL_ERROR "Lwip shared library is only working on Linux or the Hurd")
endif() endif()
set(LWIP_CONTRIB_DIR ${CMAKE_CURRENT_SOURCE_DIR}/../../..) set(LWIP_DIR ${CMAKE_CURRENT_SOURCE_DIR}/../../../..)
set(LWIP_DIR ${LWIP_CONTRIB_DIR}/..) include(${LWIP_DIR}/contrib/ports/CMakeCommon.cmake)
include(${LWIP_CONTRIB_DIR}/ports/CMakeCommon.cmake)
set (LWIP_DEFINITIONS -DLWIP_DEBUG) set (LWIP_DEFINITIONS -DLWIP_DEBUG)
set (LWIP_INCLUDE_DIRS set (LWIP_INCLUDE_DIRS

View File

@ -4,10 +4,8 @@ project(example_app C)
set (CMAKE_EXPORT_COMPILE_COMMANDS ON) set (CMAKE_EXPORT_COMPILE_COMMANDS ON)
set(LWIP_CONTRIB_DIR ${CMAKE_CURRENT_SOURCE_DIR}/../../..) set(LWIP_DIR ${CMAKE_CURRENT_SOURCE_DIR}/../../../..)
set(LWIP_DIR ${LWIP_CONTRIB_DIR}/..) include(${LWIP_DIR}/contrib/ports/CMakeCommon.cmake)
include(${LWIP_CONTRIB_DIR}/ports/CMakeCommon.cmake)
set (LWIP_DEFINITIONS -DLWIP_DEBUG) set (LWIP_DEFINITIONS -DLWIP_DEBUG)
set (LWIP_INCLUDE_DIRS set (LWIP_INCLUDE_DIRS