mirror of
https://github.com/lwip-tcpip/lwip.git
synced 2024-11-04 14:29:39 +00:00
Add CMakeLists.txt to generate source distribution file
This commit is contained in:
parent
fd0af07d2d
commit
88ef663334
1
.gitignore
vendored
1
.gitignore
vendored
@ -16,3 +16,4 @@
|
||||
/test/fuzz/output
|
||||
/test/fuzz/lwip_fuzz
|
||||
/test/fuzz/.depend
|
||||
/build
|
19
CMakeLists.txt
Normal file
19
CMakeLists.txt
Normal file
@ -0,0 +1,19 @@
|
||||
cmake_minimum_required(VERSION 3.7)
|
||||
|
||||
project(lwIP)
|
||||
|
||||
set(LWIP_DIR ${CMAKE_CURRENT_SOURCE_DIR})
|
||||
include(src/Filelists.cmake)
|
||||
|
||||
# Package generation
|
||||
set(CPACK_SOURCE_GENERATOR "ZIP")
|
||||
set(CPACK_SOURCE_PACKAGE_DESCRIPTION_SUMMARY "lwIP lightweight IP stack")
|
||||
set(CPACK_PACKAGE_VERSION_MAJOR "${LWIP_VERSION_MAJOR}")
|
||||
set(CPACK_PACKAGE_VERSION_MINOR "${LWIP_VERSION_MINOR}")
|
||||
set(CPACK_PACKAGE_VERSION_PATCH "${LWIP_VERSION_REVISION}")
|
||||
set(CPACK_SOURCE_IGNORE_FILES "/build/;${CPACK_SOURCE_IGNORE_FILES};.git")
|
||||
include(CPack)
|
||||
|
||||
# Target for package generation
|
||||
add_custom_target(dist COMMAND ${CMAKE_MAKE_PROGRAM} package_source)
|
||||
add_dependencies(dist lwipdocs)
|
@ -58,7 +58,7 @@ PROJECT_LOGO =
|
||||
# entered, it will be relative to the location where doxygen was started. If
|
||||
# left blank the current directory will be used.
|
||||
|
||||
OUTPUT_DIRECTORY = output
|
||||
OUTPUT_DIRECTORY = "${DOXYGEN_OUTPUT_DIR}"
|
||||
|
||||
# If the CREATE_SUBDIRS tag is set to YES then doxygen will create 4096 sub-
|
||||
# directories (in 2 levels) under the output directory of each output format and
|
||||
|
@ -236,6 +236,8 @@ set(lwipallapps_SRCS
|
||||
configure_file(${LWIP_DIR}/src/include/lwip/init.h.cmake.in ${LWIP_DIR}/src/include/lwip/init.h)
|
||||
|
||||
# Documentation
|
||||
set(DOXYGEN_DIR ${LWIP_DIR}/doc/doxygen)
|
||||
set(DOXYGEN_OUTPUT_DIR output)
|
||||
set(DOXYGEN_IN ${LWIP_DIR}/doc/doxygen/lwip.Doxyfile.cmake.in)
|
||||
set(DOXYGEN_OUT ${LWIP_DIR}/doc/doxygen/lwip.Doxyfile)
|
||||
configure_file(${DOXYGEN_IN} ${DOXYGEN_OUT})
|
||||
@ -246,7 +248,7 @@ if (DOXYGEN_FOUND)
|
||||
# note the option ALL which allows to build the docs together with the application
|
||||
add_custom_target(lwipdocs EXCLUDE_FROM_ALL
|
||||
COMMAND ${DOXYGEN_EXECUTABLE} ${DOXYGEN_OUT}
|
||||
WORKING_DIRECTORY ${LWIP_DIR}/doc/doxygen
|
||||
WORKING_DIRECTORY ${DOXYGEN_DIR}
|
||||
COMMENT "Generating API documentation with Doxygen"
|
||||
VERBATIM)
|
||||
else (DOXYGEN_FOUND)
|
||||
|
Loading…
Reference in New Issue
Block a user