ebf6f64b76
This version of ntp fixes several vulnerabilities. CVE-2016-9311 CVE-2016-9310 CVE-2016-7427 CVE-2016-7428 CVE-2016-9312 CVE-2016-7431 CVE-2016-7434 CVE-2016-7429 CVE-2016-7426 CVE-2016-7433 http://www.kb.cert.org/vuls/id/633847 In addition, libssl_compat.h is now included in many files, which references openssl/evp.h, openssl/dsa.h, and openssl/rsa.h. Even if a you pass --disable-ssl as a configuration option, these files are now required. As such, I have also added openssl as a dependency, and it is now automatically selected when you select ntp. Signed-off-by: Adam Duskett <aduskett@codeblue.com> Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
92 lines
2.9 KiB
Makefile
92 lines
2.9 KiB
Makefile
################################################################################
|
|
#
|
|
# ntp
|
|
#
|
|
################################################################################
|
|
|
|
NTP_VERSION_MAJOR = 4.2
|
|
NTP_VERSION = $(NTP_VERSION_MAJOR).8p9
|
|
NTP_SITE = http://www.eecis.udel.edu/~ntp/ntp_spool/ntp4/ntp-$(NTP_VERSION_MAJOR)
|
|
NTP_DEPENDENCIES = host-pkgconf libevent openssl $(if $(BR2_PACKAGE_BUSYBOX),busybox)
|
|
NTP_LICENSE = ntp license
|
|
NTP_LICENSE_FILES = COPYRIGHT
|
|
NTP_CONF_ENV = ac_cv_lib_md5_MD5Init=no
|
|
NTP_CONF_OPTS = \
|
|
--with-shared \
|
|
--program-transform-name=s,,, \
|
|
--disable-tickadj \
|
|
--disable-debugging \
|
|
--with-yielding-select=yes \
|
|
--disable-local-libevent \
|
|
--with-crypto
|
|
|
|
# 0002-ntp-syscalls-fallback.patch
|
|
NTP_AUTORECONF = YES
|
|
|
|
ifeq ($(BR2_PACKAGE_LIBCAP),y)
|
|
NTP_CONF_OPTS += --enable-linuxcaps
|
|
NTP_DEPENDENCIES += libcap
|
|
else
|
|
NTP_CONF_OPTS += --disable-linuxcaps
|
|
endif
|
|
|
|
ifeq ($(BR2_PACKAGE_LIBEDIT),y)
|
|
NTP_CONF_OPTS += --with-lineeditlibs=edit
|
|
NTP_DEPENDENCIES += libedit
|
|
else
|
|
NTP_CONF_OPTS += --without-lineeditlibs
|
|
endif
|
|
|
|
ifeq ($(BR2_PACKAGE_NTP_NTPSNMPD),y)
|
|
NTP_CONF_OPTS += \
|
|
--with-net-snmp-config=$(STAGING_DIR)/usr/bin/net-snmp-config
|
|
NTP_DEPENDENCIES += netsnmp
|
|
else
|
|
NTP_CONF_OPTS += --without-ntpsnmpd
|
|
endif
|
|
|
|
ifeq ($(BR2_PACKAGE_NTP_NTPD_ATOM_PPS),y)
|
|
NTP_CONF_OPTS += --enable-ATOM
|
|
NTP_DEPENDENCIES += pps-tools
|
|
else
|
|
NTP_CONF_OPTS += --disable-ATOM
|
|
endif
|
|
|
|
ifeq ($(BR2_PACKAGE_NTP_NTP_SHM_CLK),y)
|
|
NTP_CONF_OPTS += --enable-SHM
|
|
else
|
|
NTP_CONF_OPTS += --disable-SHM
|
|
endif
|
|
|
|
NTP_INSTALL_FILES_$(BR2_PACKAGE_NTP_NTP_KEYGEN) += util/ntp-keygen
|
|
NTP_INSTALL_FILES_$(BR2_PACKAGE_NTP_NTP_WAIT) += scripts/ntp-wait/ntp-wait
|
|
NTP_INSTALL_FILES_$(BR2_PACKAGE_NTP_NTPDATE) += ntpdate/ntpdate
|
|
NTP_INSTALL_FILES_$(BR2_PACKAGE_NTP_NTPDC) += ntpdc/ntpdc
|
|
NTP_INSTALL_FILES_$(BR2_PACKAGE_NTP_NTPQ) += ntpq/ntpq
|
|
NTP_INSTALL_FILES_$(BR2_PACKAGE_NTP_NTPSNMPD) += ntpsnmpd/ntpsnmpd
|
|
NTP_INSTALL_FILES_$(BR2_PACKAGE_NTP_NTPTIME) += util/ntptime
|
|
NTP_INSTALL_FILES_$(BR2_PACKAGE_NTP_NTPTRACE) += scripts/ntptrace/ntptrace
|
|
NTP_INSTALL_FILES_$(BR2_PACKAGE_NTP_SNTP) += sntp/sntp
|
|
NTP_INSTALL_FILES_$(BR2_PACKAGE_NTP_TICKADJ) += util/tickadj
|
|
|
|
define NTP_INSTALL_TARGET_CMDS
|
|
$(if $(BR2_PACKAGE_NTP_NTPD), install -m 755 $(@D)/ntpd/ntpd $(TARGET_DIR)/usr/sbin/ntpd)
|
|
test -z "$(NTP_INSTALL_FILES_y)" || install -m 755 $(addprefix $(@D)/,$(NTP_INSTALL_FILES_y)) $(TARGET_DIR)/usr/bin/
|
|
$(INSTALL) -m 644 package/ntp/ntpd.etc.conf $(TARGET_DIR)/etc/ntp.conf
|
|
endef
|
|
|
|
ifeq ($(BR2_PACKAGE_NTP_NTPD),y)
|
|
define NTP_INSTALL_INIT_SYSV
|
|
$(INSTALL) -D -m 755 package/ntp/S49ntp $(TARGET_DIR)/etc/init.d/S49ntp
|
|
endef
|
|
|
|
define NTP_INSTALL_INIT_SYSTEMD
|
|
$(INSTALL) -D -m 644 package/ntp/ntpd.service $(TARGET_DIR)/usr/lib/systemd/system/ntpd.service
|
|
mkdir -p $(TARGET_DIR)/etc/systemd/system/multi-user.target.wants
|
|
ln -fs ../../../../usr/lib/systemd/system/ntpd.service \
|
|
$(TARGET_DIR)/etc/systemd/system/multi-user.target.wants/ntpd.service
|
|
endef
|
|
endif
|
|
|
|
$(eval $(autotools-package))
|