mirror of
https://github.com/osm-search/Nominatim.git
synced 2026-03-16 16:04:07 +00:00
add cmake mode for building documentation only
This commit is contained in:
@@ -35,7 +35,9 @@ add_definitions(-DNOMINATIM_VERSION="${NOMINATIM_VERSION}")
|
||||
|
||||
set(BUILD_TESTS off CACHE BOOL "Build test suite" FORCE)
|
||||
set(WITH_LUA off CACHE BOOL "Build with lua support" FORCE)
|
||||
set(ONLY_DOCS off CACHE BOOL "Build documentation only")
|
||||
|
||||
if (NOT ONLY_DOCS)
|
||||
if (NOT EXISTS "${CMAKE_SOURCE_DIR}/osm2pgsql/CMakeLists.txt")
|
||||
message(FATAL_ERROR "The osm2pgsql directory is empty.\
|
||||
Did you forget to check out Nominatim recursively?\
|
||||
@@ -86,6 +88,7 @@ if (NOT EXISTS ${PHP_BIN})
|
||||
message(FATAL_ERROR "PHP binary not found. Install php or provide location with -DPHP_BIN=/path/php ")
|
||||
endif()
|
||||
message (STATUS "Using PHP binary " ${PHP_BIN})
|
||||
endif()
|
||||
|
||||
#-----------------------------------------------------------------------------
|
||||
#
|
||||
@@ -143,6 +146,7 @@ endforeach()
|
||||
#
|
||||
#-----------------------------------------------------------------------------
|
||||
|
||||
if (NOT ONLY_DOCS)
|
||||
include(CTest)
|
||||
|
||||
set(TEST_BDD db osm2pgsql api)
|
||||
@@ -158,11 +162,14 @@ endforeach()
|
||||
add_test(NAME php
|
||||
COMMAND phpunit ./
|
||||
WORKING_DIRECTORY ${PROJECT_SOURCE_DIR}/tests-php)
|
||||
endif()
|
||||
|
||||
#-----------------------------------------------------------------------------
|
||||
|
||||
if (NOT ONLY_DOCS)
|
||||
add_subdirectory(module)
|
||||
add_subdirectory(nominatim)
|
||||
endif()
|
||||
add_subdirectory(docs)
|
||||
|
||||
#-----------------------------------------------------------------------------
|
||||
|
||||
Reference in New Issue
Block a user