mirror of https://github.com/Icinga/icinga2.git
CMakeLists.txt: provide sane defaults for which subsystems to build
not to have to explicitly disable particular ones in multiple locations.
This commit is contained in:
parent
d9767cff3f
commit
260eb5c475
|
@ -16,21 +16,21 @@ if(NOT CMAKE_BUILD_TYPE)
|
||||||
FORCE)
|
FORCE)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
option(ICINGA2_WITH_MYSQL "Build the MySQL IDO module" ON)
|
if(WIN32)
|
||||||
option(ICINGA2_WITH_PGSQL "Build the PostgreSQL IDO module" ON)
|
set(ICINGA2_MASTER OFF)
|
||||||
|
else()
|
||||||
|
set(ICINGA2_MASTER ON)
|
||||||
|
endif()
|
||||||
|
|
||||||
|
option(ICINGA2_WITH_MYSQL "Build the MySQL IDO module" ${ICINGA2_MASTER})
|
||||||
|
option(ICINGA2_WITH_PGSQL "Build the PostgreSQL IDO module" ${ICINGA2_MASTER})
|
||||||
option(ICINGA2_WITH_CHECKER "Build the checker module" ON)
|
option(ICINGA2_WITH_CHECKER "Build the checker module" ON)
|
||||||
option(ICINGA2_WITH_COMPAT "Build the compat module" ON)
|
option(ICINGA2_WITH_COMPAT "Build the compat module" ${ICINGA2_MASTER})
|
||||||
option(ICINGA2_WITH_LIVESTATUS "Build the Livestatus module" ON)
|
option(ICINGA2_WITH_LIVESTATUS "Build the Livestatus module" ${ICINGA2_MASTER})
|
||||||
option(ICINGA2_WITH_NOTIFICATION "Build the notification module" ON)
|
option(ICINGA2_WITH_NOTIFICATION "Build the notification module" ON)
|
||||||
option(ICINGA2_WITH_PERFDATA "Build the perfdata module" ON)
|
option(ICINGA2_WITH_PERFDATA "Build the perfdata module" ON)
|
||||||
option(ICINGA2_WITH_TESTS "Run unit tests" ON)
|
option(ICINGA2_WITH_TESTS "Run unit tests" ON)
|
||||||
|
option(ICINGA2_WITH_ICINGADB "Build the IcingaDB module" ${ICINGA2_MASTER})
|
||||||
# IcingaDB only is supported on modern Linux/Unix master systems
|
|
||||||
if(NOT WIN32)
|
|
||||||
option(ICINGA2_WITH_ICINGADB "Build the IcingaDB module" ON)
|
|
||||||
else()
|
|
||||||
option(ICINGA2_WITH_ICINGADB "Build the IcingaDB module" OFF)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
option (USE_SYSTEMD
|
option (USE_SYSTEMD
|
||||||
"Configure icinga as native systemd service instead of a SysV initscript" OFF)
|
"Configure icinga as native systemd service instead of a SysV initscript" OFF)
|
||||||
|
|
|
@ -1763,10 +1763,9 @@ mkdir build
|
||||||
cd .\build\
|
cd .\build\
|
||||||
|
|
||||||
& "C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\Common7\IDE\CommonExtensions\Microsoft\CMake\CMake\bin\cmake.exe" `
|
& "C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\Common7\IDE\CommonExtensions\Microsoft\CMake\CMake\bin\cmake.exe" `
|
||||||
-DBoost_INCLUDE_DIR=C:\local\boost_1_81_0-Win64 `
|
-DICINGA2_UNITY_BUILD=OFF -DBoost_INCLUDE_DIR=C:\local\boost_1_81_0-Win64 `
|
||||||
-DBISON_EXECUTABLE=C:\ProgramData\chocolatey\lib\winflexbison3\tools\win_bison.exe `
|
-DBISON_EXECUTABLE=C:\ProgramData\chocolatey\lib\winflexbison3\tools\win_bison.exe `
|
||||||
-DFLEX_EXECUTABLE=C:\ProgramData\chocolatey\lib\winflexbison3\tools\win_flex.exe `
|
-DFLEX_EXECUTABLE=C:\ProgramData\chocolatey\lib\winflexbison3\tools\win_flex.exe ..
|
||||||
-DICINGA2_WITH_MYSQL=OFF -DICINGA2_WITH_PGSQL=OFF -DICINGA2_UNITY_BUILD=OFF ..
|
|
||||||
|
|
||||||
& "C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\MSBuild\Current\Bin\MSBuild.exe" .\icinga2.sln
|
& "C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\MSBuild\Current\Bin\MSBuild.exe" .\icinga2.sln
|
||||||
```
|
```
|
||||||
|
@ -2045,8 +2044,6 @@ Variable | Value
|
||||||
`BOOST_LIBRARYDIR` | Binary: `C:\local\boost_1_81_0\lib64-msvc-14.2`, Source: `C:\local\boost_1_81_0\stage` | Path to the static compiled Boost libraries, directory must contain `lib`.
|
`BOOST_LIBRARYDIR` | Binary: `C:\local\boost_1_81_0\lib64-msvc-14.2`, Source: `C:\local\boost_1_81_0\stage` | Path to the static compiled Boost libraries, directory must contain `lib`.
|
||||||
`BISON_EXECUTABLE` | `C:\ProgramData\chocolatey\lib\winflexbison\tools\win_bison.exe` | Path to the Bison executable.
|
`BISON_EXECUTABLE` | `C:\ProgramData\chocolatey\lib\winflexbison\tools\win_bison.exe` | Path to the Bison executable.
|
||||||
`FLEX_EXECUTABLE` | `C:\ProgramData\chocolatey\lib\winflexbison\tools\win_flex.exe` | Path to the Flex executable.
|
`FLEX_EXECUTABLE` | `C:\ProgramData\chocolatey\lib\winflexbison\tools\win_flex.exe` | Path to the Flex executable.
|
||||||
`ICINGA2_WITH_MYSQL` | OFF | Requires extra setup for MySQL if set to `ON`. Not supported for client setups.
|
|
||||||
`ICINGA2_WITH_PGSQL` | OFF | Requires extra setup for PgSQL if set to `ON`. Not supported for client setups.
|
|
||||||
`ICINGA2_UNITY_BUILD` | OFF | Disable unity builds for development environments.
|
`ICINGA2_UNITY_BUILD` | OFF | Disable unity builds for development environments.
|
||||||
|
|
||||||
Tip: If you have previously opened a terminal, run `refreshenv` to re-read updated PATH variables.
|
Tip: If you have previously opened a terminal, run `refreshenv` to re-read updated PATH variables.
|
||||||
|
|
|
@ -56,8 +56,6 @@ if (Test-Path CMakeCache.txt) {
|
||||||
-DCMAKE_BUILD_TYPE="$env:CMAKE_BUILD_TYPE" `
|
-DCMAKE_BUILD_TYPE="$env:CMAKE_BUILD_TYPE" `
|
||||||
-G "$env:CMAKE_GENERATOR" -A "$env:CMAKE_GENERATOR_PLATFORM" -DCPACK_GENERATOR=WIX `
|
-G "$env:CMAKE_GENERATOR" -A "$env:CMAKE_GENERATOR_PLATFORM" -DCPACK_GENERATOR=WIX `
|
||||||
-DCMAKE_INSTALL_PREFIX="$env:ICINGA2_INSTALLPATH" `
|
-DCMAKE_INSTALL_PREFIX="$env:ICINGA2_INSTALLPATH" `
|
||||||
-DICINGA2_WITH_MYSQL=OFF -DICINGA2_WITH_PGSQL=OFF `
|
|
||||||
-DICINGA2_WITH_LIVESTATUS=OFF -DICINGA2_WITH_COMPAT=OFF `
|
|
||||||
-DOPENSSL_ROOT_DIR="$env:OPENSSL_ROOT_DIR" `
|
-DOPENSSL_ROOT_DIR="$env:OPENSSL_ROOT_DIR" `
|
||||||
-DBOOST_LIBRARYDIR="$env:BOOST_LIBRARYDIR" `
|
-DBOOST_LIBRARYDIR="$env:BOOST_LIBRARYDIR" `
|
||||||
-DBOOST_INCLUDEDIR="$env:BOOST_ROOT" `
|
-DBOOST_INCLUDEDIR="$env:BOOST_ROOT" `
|
||||||
|
|
|
@ -59,8 +59,6 @@ if (Test-Path CMakeCache.txt) {
|
||||||
& cmake.exe "$sourcePath" `
|
& cmake.exe "$sourcePath" `
|
||||||
-DCMAKE_BUILD_TYPE="$env:CMAKE_BUILD_TYPE" `
|
-DCMAKE_BUILD_TYPE="$env:CMAKE_BUILD_TYPE" `
|
||||||
-G "$env:CMAKE_GENERATOR" -A "$env:CMAKE_GENERATOR_PLATFORM" -DCPACK_GENERATOR=WIX `
|
-G "$env:CMAKE_GENERATOR" -A "$env:CMAKE_GENERATOR_PLATFORM" -DCPACK_GENERATOR=WIX `
|
||||||
-DICINGA2_WITH_MYSQL=OFF -DICINGA2_WITH_PGSQL=OFF `
|
|
||||||
-DICINGA2_WITH_LIVESTATUS=OFF -DICINGA2_WITH_COMPAT=OFF `
|
|
||||||
-DOPENSSL_ROOT_DIR="$env:OPENSSL_ROOT_DIR" `
|
-DOPENSSL_ROOT_DIR="$env:OPENSSL_ROOT_DIR" `
|
||||||
-DBOOST_LIBRARYDIR="$env:BOOST_LIBRARYDIR" `
|
-DBOOST_LIBRARYDIR="$env:BOOST_LIBRARYDIR" `
|
||||||
-DBOOST_INCLUDEDIR="$env:BOOST_ROOT" `
|
-DBOOST_INCLUDEDIR="$env:BOOST_ROOT" `
|
||||||
|
|
Loading…
Reference in New Issue