Commit f03dc19e authored by Michael Friedrich's avatar Michael Friedrich
Browse files

Merge branch 'master' into 2.11

parents 8c50012c 126c403b
...@@ -8,7 +8,6 @@ variables: ...@@ -8,7 +8,6 @@ variables:
DOCKER_IMAGE_BASE: registry.icinga.com/build-docker DOCKER_IMAGE_BASE: registry.icinga.com/build-docker
#ICINGA_BUILD_RELEASE_TYPE: testing #ICINGA_BUILD_RELEASE_TYPE: testing
ICINGA_BUILD_TYPE: release ICINGA_BUILD_TYPE: release
#ICINGA_BUILD_UPSTREAM_BRANCH:
.source: &source .source: &source
stage: source stage: source
......
Source: icinga2 Source: icinga2
Section: admin Section: admin
Priority: extra Priority: optional
Maintainer: Icinga Development Team <info@icinga.com> Maintainer: Icinga Development Team <info@icinga.com>
Build-Depends: Build-Depends:
bash-completion, bash-completion,
...@@ -11,7 +11,7 @@ Build-Depends: ...@@ -11,7 +11,7 @@ Build-Depends:
dh-systemd (>= 1.5), dh-systemd (>= 1.5),
libsystemd-dev, libsystemd-dev,
flex, flex,
g++ (>= 1.96), g++ (>= 4:8.0) | g++-8 | g++ (<< 4:7),
libboost-dev (>= 1.66) | libboost1.67-dev | libboost1.67-icinga-dev, libboost-dev (>= 1.66) | libboost1.67-dev | libboost1.67-icinga-dev,
libboost-context-dev (>= 1.66) | libboost-context1.67-dev | libboost-context1.67-icinga-dev, libboost-context-dev (>= 1.66) | libboost-context1.67-dev | libboost-context1.67-icinga-dev,
libboost-coroutine-dev (>= 1.66) | libboost-coroutine1.67-dev | libboost-coroutine1.67-icinga-dev, libboost-coroutine-dev (>= 1.66) | libboost-coroutine1.67-dev | libboost-coroutine1.67-icinga-dev,
...@@ -29,16 +29,19 @@ Build-Depends: ...@@ -29,16 +29,19 @@ Build-Depends:
make (>= 3.81), make (>= 3.81),
po-debconf po-debconf
Standards-Version: 3.9.8 Standards-Version: 3.9.8
Homepage: http://www.icinga.org Homepage: https://www.icinga.com
Vcs-Browser: https://anonscm.debian.org/cgit/pkg-nagios/pkg-icinga2.git Vcs-Browser: https://git.icinga.com/packaging/deb-icinga2
Vcs-Git: https://anonscm.debian.org/git/pkg-nagios/pkg-icinga2.git Vcs-Git: https://git.icinga.com/packaging/deb-icinga2.git
Package: icinga2 Package: icinga2
Architecture: any Architecture: any
Depends: icinga2-bin (= ${binary:Version}), Depends: icinga2-bin (= ${binary:Version}),
icinga2-common (= ${source:Version}), icinga2-common (= ${source:Version}),
${misc:Depends} ${misc:Depends}
Recommends: icinga2-doc (= ${binary:Version}), monitoring-plugins-basic | nagios-plugins-basic, libreadline6 Recommends:
icinga2-doc (= ${binary:Version}),
monitoring-plugins-basic | nagios-plugins-basic,
libreadline8 | libreadline7 | libreadline6
Suggests: vim-icinga2 Suggests: vim-icinga2
Description: host and network monitoring system Description: host and network monitoring system
Icinga 2 is a general-purpose monitoring application to fit the needs of Icinga 2 is a general-purpose monitoring application to fit the needs of
......
# this is actually a defined word in the livestatus protocol... # this is actually a defined word in the livestatus protocol...
spelling-error-in-binary usr/lib/*/icinga2/sbin/icinga2 childs children spelling-error-in-binary usr/lib/*/icinga2/sbin/icinga2 childs children
# vendor: We link to a backported version of boost - this is intended
binary-or-shlib-defines-rpath usr/lib/*/icinga2/* /usr/lib/*/icinga-boost
# vendor: We link to a backported version of boost - this is intended
binary-or-shlib-defines-rpath usr/lib/*/icinga2/* /usr/lib/*/icinga-boost
# vendor: We link to a backported version of boost - this is intended
binary-or-shlib-defines-rpath usr/lib/*/icinga2/* /usr/lib/*/icinga-boost
...@@ -2,12 +2,17 @@ ...@@ -2,12 +2,17 @@
#export DH_VERBOSE=1 #export DH_VERBOSE=1
LTO_BUILD = -DICINGA2_LTO_BUILD=On CXX_INSTALLED_VERSION := $(shell dpkg-query --showformat='$${Version}' --show g++)
CXX_PREFERED_VERSION = 4:8.0
CXX_PREFERED_COMPILER = g++-8
C_PREFERED_COMPILER = gcc-8
CMAKE_FLAGS = -DICINGA2_LTO_BUILD=On
DEB_HOST_ARCH = $(shell dpkg-architecture -qDEB_HOST_ARCH) DEB_HOST_ARCH = $(shell dpkg-architecture -qDEB_HOST_ARCH)
ifneq (,$(wildcard /usr/include/icinga-boost)) ifneq (,$(wildcard /usr/include/icinga-boost))
BOOST_FLAGS = \ CMAKE_FLAGS += \
-DBoost_NO_BOOST_CMAKE=TRUE \ -DBoost_NO_BOOST_CMAKE=TRUE \
-DBoost_NO_SYSTEM_PATHS=TRUE \ -DBoost_NO_SYSTEM_PATHS=TRUE \
-DBOOST_LIBRARYDIR=/usr/lib/$(DEB_HOST_MULTIARCH)/icinga-boost \ -DBOOST_LIBRARYDIR=/usr/lib/$(DEB_HOST_MULTIARCH)/icinga-boost \
...@@ -17,18 +22,24 @@ endif ...@@ -17,18 +22,24 @@ endif
# disable unity/lto builds for arches with low memory # disable unity/lto builds for arches with low memory
ifneq ($(findstring $(DEB_HOST_ARCH), armhf),) ifneq ($(findstring $(DEB_HOST_ARCH), armhf),)
UNITY_BUILD = -DICINGA2_UNITY_BUILD=Off CMAKE_FLAGS += -DICINGA2_UNITY_BUILD=Off
LTO_BUILD = -DICINGA2_LTO_BUILD=Off CMAKE_FLAGS += -DICINGA2_LTO_BUILD=Off
endif endif
ifneq ($(findstring $(DEB_HOST_ARCH), mips),) ifneq ($(findstring $(DEB_HOST_ARCH), mips),)
UNITY_BUILD = -DICINGA2_UNITY_BUILD=Off CMAKE_FLAGS += -DICINGA2_UNITY_BUILD=Off
LTO_BUILD = -DICINGA2_LTO_BUILD=Off CMAKE_FLAGS += -DICINGA2_LTO_BUILD=Off
endif endif
ifneq ($(findstring $(DEB_HOST_ARCH), mipsel),) # check if the installed default g++ is already newer as preferred
UNITY_BUILD = -DICINGA2_UNITY_BUILD=Off ifneq ($(shell dpkg --compare-versions "$(CXX_INSTALLED_VERSION)" ge "$(CXX_PREFERED_VERSION)" && echo 1 || echo 0),1)
LTO_BUILD = -DICINGA2_LTO_BUILD=Off # if not choose the prefered compiler directly
ifneq (,$(shell command -v $(CXX_PREFERED_COMPILER) 2>/dev/null))
# if it is installed
$(warning Installed GCC $(CXX_INSTALLED_VERSION) is older than $(CXX_PREFERED_VERSION) - using alternative binary $(CXX_PREFERED_COMPILER))
CMAKE_FLAGS += -DCMAKE_CXX_COMPILER=$(CXX_PREFERED_COMPILER)
CMAKE_FLAGS += -DCMAKE_C_COMPILER=$(C_PREFERED_COMPILER)
endif
endif endif
%: %:
...@@ -59,9 +70,7 @@ override_dh_auto_configure: ...@@ -59,9 +70,7 @@ override_dh_auto_configure:
-DICINGA2_GIT_VERSION_INFO=false \ -DICINGA2_GIT_VERSION_INFO=false \
-DICINGA2_PLUGINDIR=/usr/lib/nagios/plugins \ -DICINGA2_PLUGINDIR=/usr/lib/nagios/plugins \
-DUSE_SYSTEMD=ON \ -DUSE_SYSTEMD=ON \
$(BOOST_FLAGS) \ $(CMAKE_FLAGS)
$(UNITY_BUILD) \
$(LTO_BUILD)
override_dh_auto_install: override_dh_auto_install:
dh_auto_install dh_auto_install
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment