2013-06-06 01:53:30 +02:00
|
|
|
################################################################################
|
2003-01-18 22:27:22 +01:00
|
|
|
#
|
|
|
|
# ntp
|
|
|
|
#
|
2013-06-06 01:53:30 +02:00
|
|
|
################################################################################
|
2003-01-18 22:27:22 +01:00
|
|
|
|
2013-12-18 19:20:02 +01:00
|
|
|
NTP_VERSION_MAJOR = 4.2
|
2016-01-20 14:18:48 +01:00
|
|
|
NTP_VERSION = $(NTP_VERSION_MAJOR).8p6
|
2013-12-18 19:20:02 +01:00
|
|
|
NTP_SITE = http://www.eecis.udel.edu/~ntp/ntp_spool/ntp4/ntp-$(NTP_VERSION_MAJOR)
|
2015-05-19 11:13:17 +02:00
|
|
|
NTP_DEPENDENCIES = host-pkgconf libevent $(if $(BR2_PACKAGE_BUSYBOX),busybox)
|
2012-09-12 00:11:30 +02:00
|
|
|
NTP_LICENSE = ntp license
|
|
|
|
NTP_LICENSE_FILES = COPYRIGHT
|
2010-09-20 23:54:23 +02:00
|
|
|
NTP_CONF_ENV = ac_cv_lib_md5_MD5Init=no
|
2014-12-24 08:54:24 +01:00
|
|
|
NTP_CONF_OPTS = \
|
|
|
|
--with-shared \
|
|
|
|
--program-transform-name=s,,, \
|
|
|
|
--disable-tickadj \
|
|
|
|
--with-yielding-select=yes \
|
|
|
|
--disable-local-libevent
|
2015-10-15 01:45:33 +02:00
|
|
|
# 0002-ntp-syscalls-fallback.patch
|
|
|
|
NTP_AUTORECONF = YES
|
2003-01-18 22:27:22 +01:00
|
|
|
|
2011-02-03 21:45:57 +01:00
|
|
|
ifeq ($(BR2_PACKAGE_OPENSSL),y)
|
2015-03-31 09:21:57 +02:00
|
|
|
NTP_CONF_OPTS += --with-crypto
|
|
|
|
NTP_DEPENDENCIES += openssl
|
2011-10-16 05:04:30 +02:00
|
|
|
else
|
2015-03-31 09:21:57 +02:00
|
|
|
NTP_CONF_OPTS += --without-crypto --disable-openssl-random
|
2011-10-16 05:04:30 +02:00
|
|
|
endif
|
|
|
|
|
|
|
|
ifeq ($(BR2_PACKAGE_NTP_NTPSNMPD),y)
|
2015-03-31 09:21:57 +02:00
|
|
|
NTP_CONF_OPTS += \
|
|
|
|
--with-net-snmp-config=$(STAGING_DIR)/usr/bin/net-snmp-config
|
|
|
|
NTP_DEPENDENCIES += netsnmp
|
2011-02-03 21:45:57 +01:00
|
|
|
else
|
2015-03-31 09:21:57 +02:00
|
|
|
NTP_CONF_OPTS += --without-ntpsnmpd
|
2011-02-03 21:45:57 +01:00
|
|
|
endif
|
|
|
|
|
2014-10-16 19:30:54 +02:00
|
|
|
ifeq ($(BR2_PACKAGE_NTP_NTPD_ATOM_PPS),y)
|
2015-03-31 09:21:57 +02:00
|
|
|
NTP_CONF_OPTS += --enable-ATOM
|
|
|
|
NTP_DEPENDENCIES += pps-tools
|
2014-10-16 19:30:54 +02:00
|
|
|
else
|
2015-03-31 09:21:57 +02:00
|
|
|
NTP_CONF_OPTS += --disable-ATOM
|
2014-10-16 19:30:54 +02:00
|
|
|
endif
|
|
|
|
|
2010-09-20 23:54:23 +02:00
|
|
|
NTP_INSTALL_FILES_$(BR2_PACKAGE_NTP_NTP_KEYGEN) += util/ntp-keygen
|
2014-12-25 22:24:52 +01:00
|
|
|
NTP_INSTALL_FILES_$(BR2_PACKAGE_NTP_NTP_WAIT) += scripts/ntp-wait/ntp-wait
|
2011-02-03 21:45:57 +01:00
|
|
|
NTP_INSTALL_FILES_$(BR2_PACKAGE_NTP_NTPDATE) += ntpdate/ntpdate
|
2010-09-20 23:54:23 +02:00
|
|
|
NTP_INSTALL_FILES_$(BR2_PACKAGE_NTP_NTPDC) += ntpdc/ntpdc
|
|
|
|
NTP_INSTALL_FILES_$(BR2_PACKAGE_NTP_NTPQ) += ntpq/ntpq
|
2011-10-16 05:04:30 +02:00
|
|
|
NTP_INSTALL_FILES_$(BR2_PACKAGE_NTP_NTPSNMPD) += ntpsnmpd/ntpsnmpd
|
2015-10-15 01:45:33 +02:00
|
|
|
NTP_INSTALL_FILES_$(BR2_PACKAGE_NTP_NTPTIME) += util/ntptime
|
2014-12-25 22:24:52 +01:00
|
|
|
NTP_INSTALL_FILES_$(BR2_PACKAGE_NTP_NTPTRACE) += scripts/ntptrace/ntptrace
|
2011-02-03 21:45:57 +01:00
|
|
|
NTP_INSTALL_FILES_$(BR2_PACKAGE_NTP_SNTP) += sntp/sntp
|
2010-09-20 23:54:23 +02:00
|
|
|
NTP_INSTALL_FILES_$(BR2_PACKAGE_NTP_TICKADJ) += util/tickadj
|
|
|
|
|
|
|
|
define NTP_INSTALL_TARGET_CMDS
|
2011-02-03 21:45:57 +01:00
|
|
|
$(if $(BR2_PACKAGE_NTP_NTPD), install -m 755 $(@D)/ntpd/ntpd $(TARGET_DIR)/usr/sbin/ntpd)
|
2010-09-20 23:54:23 +02:00
|
|
|
test -z "$(NTP_INSTALL_FILES_y)" || install -m 755 $(addprefix $(@D)/,$(NTP_INSTALL_FILES_y)) $(TARGET_DIR)/usr/bin/
|
2014-06-10 14:58:40 +02:00
|
|
|
$(INSTALL) -m 644 package/ntp/ntpd.etc.conf $(TARGET_DIR)/etc/ntp.conf
|
2010-09-20 23:54:23 +02:00
|
|
|
endef
|
2003-01-18 22:27:22 +01:00
|
|
|
|
2014-01-28 03:00:05 +01:00
|
|
|
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
|
2015-03-20 20:13:53 +01:00
|
|
|
$(INSTALL) -D -m 644 package/ntp/ntpd.service $(TARGET_DIR)/usr/lib/systemd/system/ntpd.service
|
2014-01-28 03:00:05 +01:00
|
|
|
mkdir -p $(TARGET_DIR)/etc/systemd/system/multi-user.target.wants
|
2015-03-20 20:13:53 +01:00
|
|
|
ln -fs ../../../../usr/lib/systemd/system/ntpd.service \
|
|
|
|
$(TARGET_DIR)/etc/systemd/system/multi-user.target.wants/ntpd.service
|
2014-01-28 03:00:05 +01:00
|
|
|
endef
|
|
|
|
endif
|
|
|
|
|
2012-07-03 00:07:32 +02:00
|
|
|
$(eval $(autotools-package))
|