2 # Copyright (C) 2006-2016 OpenWrt.org
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
8 include $(TOPDIR
)/rules.mk
14 PKG_SOURCE
:=$(PKG_NAME
)-$(PKG_VERSION
).
tar.gz
15 PKG_SOURCE_URL
:=http
://www.eecis.udel.edu
/~ntp
/ntp_spool
/ntp4
/ntp-4.2
/
16 PKG_HASH
:=709b222b5013d77d26bfff532b5ea470a8039497ef29d09363931c036cb30454
19 PKG_LICENSE_FILES
:=COPYRIGHT html
/copyright.html
22 PKG_LIBTOOL_PATHS
:=. sntp
23 PKG_CHECK_FORMAT_SECURITY
:=0
26 include $(INCLUDE_DIR
)/package.mk
28 define Package
/ntpd
/Default
29 SUBMENU
:=Time Synchronization
33 MAINTAINER
:=Peter Wagner
<tripolar@gmx.at
>
34 URL
:=http
://www.ntp.org
/
35 DEPENDS
:=+libopenssl
+libpthread
+libcap
38 define Package
/ntpd
/Default
/description
39 The ISC ntp suite is a collection of tools used to synchronize the
40 system clock with remote NTP time servers and run
/monitor local NTP
45 $(call Package
/ntpd
/Default
)
48 USERID
:=ntp
=123:ntp
=123
51 define Package
/ntpd
/description
52 $(call Package
/ntpd
/Default
/description
)
54 This package contains the ntpd server.
57 define Package
/ntpdate
58 $(call Package
/ntpd
/Default
)
62 define Package
/ntpdate
/description
63 $(call Package
/ntpd
/Default
/description
)
65 This package contains ntpdate.
68 define Package
/ntp-utils
69 $(call Package
/ntpd
/Default
)
73 define Package
/ntp-utils
/description
74 $(call Package
/ntpd
/Default
/description
)
76 This package contains ntpdc
, ntpq and ntptime.
79 define Package
/ntp-keygen
80 $(call Package
/ntpd
/Default
)
82 DEPENDS
+= +libevent2-core
85 define Package
/ntp-keygen
/description
86 $(call Package
/ntpd
/Default
/description
)
88 This package contains the ntp-keygen.
92 ac_cv_header_md5_h
=no \
93 ac_cv_lib_rt_sched_setscheduler
=no \
94 ac_cv_header_dns_sd_h
=no \
95 hw_cv_func_snprintf_c99
=yes \
96 hw_cv_func_vsnprintf_c99
=yes \
99 --disable-all-clocks \
100 --disable-parse-clocks \
102 --without-lineeditlibs \
104 --enable-LOCAL-CLOCK \
108 --with-yielding-select
=yes \
110 --with-openssl-incdir
="$(STAGING_DIR)/usr/include" \
111 --with-openssl-libdir
="$(STAGING_DIR)/usr/lib"
113 define Package
/ntpd
/install
114 $(INSTALL_DIR
) $(1)/sbin
115 $(INSTALL_BIN
) $(PKG_BUILD_DIR
)/ntpd
/ntpd
$(1)/sbin
/
116 $(INSTALL_DIR
) $(1)/usr
/sbin
117 $(INSTALL_BIN
) .
/files
/ntpd.hotplug-helper
$(1)/usr
/sbin
/
118 $(INSTALL_DIR
) $(1)/etc
/init.d
119 $(INSTALL_BIN
) .
/files
/ntpd.init
$(1)/etc
/init.d
/ntpd
120 $(INSTALL_DIR
) $(1)/etc
/hotplug.d
/iface
121 $(INSTALL_BIN
) .
/files
/ntpd.hotplug
$(1)/etc
/hotplug.d
/iface
/20-ntpd
124 define Package
/ntpd
/postinst
126 [ -L
"$${IPKG_INSTROOT}/usr/sbin/ntpd" ] && rm -f
"$${IPKG_INSTROOT}/usr/sbin/ntpd"
130 define Package
/ntpd
/postrm
132 /bin
/busybox ntpd
-h
2>&1 | grep
-q BusyBox
&& ln
-sf ..
/..
/bin
/busybox
/usr
/sbin
/ntpd
136 define Package
/ntpdate
/install
137 $(INSTALL_DIR
) $(1)/usr
/sbin
138 $(INSTALL_BIN
) $(PKG_BUILD_DIR
)/ntpdate
/ntpdate
$(1)/usr
/sbin
/
139 $(INSTALL_DIR
) $(1)/etc
/init.d
140 $(INSTALL_BIN
) .
/files
/ntpdate.init
$(1)/etc
/init.d
/ntpdate
143 define Package
/ntp-utils
/install
144 $(INSTALL_DIR
) $(1)/usr
/sbin
145 $(INSTALL_BIN
) $(PKG_BUILD_DIR
)/ntpdc
/ntpdc
$(1)/usr
/sbin
/
146 $(INSTALL_BIN
) $(PKG_BUILD_DIR
)/ntpq
/ntpq
$(1)/usr
/sbin
/
147 $(INSTALL_BIN
) $(PKG_BUILD_DIR
)/util
/ntptime
$(1)/usr
/sbin
/
150 define Package
/ntp-keygen
/install
151 $(INSTALL_DIR
) $(1)/usr
/sbin
152 $(INSTALL_BIN
) $(PKG_BUILD_DIR
)/util
/ntp-keygen
$(1)/usr
/sbin
/
155 $(eval
$(call BuildPackage
,ntpd
))
156 $(eval
$(call BuildPackage
,ntpdate
))
157 $(eval
$(call BuildPackage
,ntp-utils
))
158 $(eval
$(call BuildPackage
,ntp-keygen
))