Skip to contentSkip to conversation

Small fixes from master

PATCH Applied Martin Jansa 4 participants 10 messages Dec 4, 2012 – Dec 13, 2012

lore
Share & tools
lore
#0 lore raw

cover Small fixes from master

The following changes since commit f8ad0760abf8055bac27036853c56f56b40a36c7:

README: update to danny (2012-11-23 15:22:46 +0100)

are available in the git repository at:

git://git.openembedded.org/meta-openembedded-contrib jansa/for-danny
http://cgit.openembedded.org/cgit.cgi/meta-openembedded-contrib/log/?h=jansa/for-danny

Andrei Dinu (1):
gypsy: added to meta-oe/recipes-navigation

Martin Jansa (1):
samba: update waf-as-source.patch to apply

Paul Eggleton (3):
ntp: cleanup recipes and fix SSL support
ntp: make servers configurable and default to none configured
meta-systemd: ntp: update for server config improvements

 meta-networking/recipes-support/ntp/files/ntp      | 31 -------
 meta-networking/recipes-support/ntp/files/ntp.conf |  2 +-
 meta-networking/recipes-support/ntp/files/ntpdate  | 11 ++-
 .../recipes-support/ntp/files/ntpdate.default      |  7 ++
 .../recipes-support/ntp/files/openssl-check.patch  | 59 ++++++++++++++
 .../recipes-support/ntp/ntp-ssl_4.2.6p5.bb         | 11 ---
 meta-networking/recipes-support/ntp/ntp.inc        | 94 +++++++++++++++++-----
 meta-networking/recipes-support/ntp/ntp_4.2.6p5.bb | 44 +---------
 .../samba/samba-3.6.8/waf-as-source.patch          |  4 -
 meta-oe/recipes-connectivity/samba/samba_3.6.8.bb  |  2 +-
 .../recipes-navigation/gypsy/files/fixups.patch    | 21 +++++
 meta-oe/recipes-navigation/gypsy/gypsy.inc         | 15 ++++
 meta-oe/recipes-navigation/gypsy/gypsy_0.9.bb      | 24 ++++++
 meta-oe/recipes-navigation/gypsy/gypsy_git.bb      | 18 +++++
 .../recipes-support/ntp/ntp/ntpdate.service        |  2 +-
 15 files changed, 234 insertions(+), 111 deletions(-)
 delete mode 100755 meta-networking/recipes-support/ntp/files/ntp
 create mode 100644 meta-networking/recipes-support/ntp/files/ntpdate.default
 create mode 100644 meta-networking/recipes-support/ntp/files/openssl-check.patch
 delete mode 100644 meta-networking/recipes-support/ntp/ntp-ssl_4.2.6p5.bb
 create mode 100644 meta-oe/recipes-navigation/gypsy/files/fixups.patch
 create mode 100644 meta-oe/recipes-navigation/gypsy/gypsy.inc
 create mode 100644 meta-oe/recipes-navigation/gypsy/gypsy_0.9.bb
 create mode 100644 meta-oe/recipes-navigation/gypsy/gypsy_git.bb
Signature · 1 line
1.8.0
#1 lore raw

PATCH 1/5 gypsy: added to meta-oe/recipes-navigation

From: Andrei Dinu <[email protected]>

Added gypsy to meta-oe/recipes-navigation

---
 .../recipes-navigation/gypsy/files/fixups.patch    | 21 +++++++++++++++++++
 meta-oe/recipes-navigation/gypsy/gypsy.inc         | 15 ++++++++++++++
 meta-oe/recipes-navigation/gypsy/gypsy_0.9.bb      | 24 ++++++++++++++++++++++
 meta-oe/recipes-navigation/gypsy/gypsy_git.bb      | 18 ++++++++++++++++
 4 files changed, 78 insertions(+)
 create mode 100644 meta-oe/recipes-navigation/gypsy/files/fixups.patch
 create mode 100644 meta-oe/recipes-navigation/gypsy/gypsy.inc
 create mode 100644 meta-oe/recipes-navigation/gypsy/gypsy_0.9.bb
 create mode 100644 meta-oe/recipes-navigation/gypsy/gypsy_git.bb
meta-oe/recipes-navigation/gypsy/files/fixups.patch new file +21 -0
new file mode 100644
index 0000000..de4d92e
@@ -0,0 +1,21 @@
+Upstream-Status: Inappropriate [configuration]
+
+---
+ docs/reference/Makefile.am |    2 ++
+ 1 file changed, 2 insertions(+)
+
+--- gypsy.orig/docs/reference/Makefile.am
++++ gypsy/docs/reference/Makefile.am
+@@ -81,10 +81,12 @@ expand_content_files=
+ # e.g. GTKDOC_LIBS=$(top_builddir)/gtk/$(gtktargetlib)
+ 
+ INCLUDES=-I$(top_srcdir) $(GYPSY_CFLAGS)
+ GTKDOC_LIBS=$(top_builddir)/gypsy/libgypsy.la $(GYPSY_LIBS)
+ 
++EXTRA_DIST =
++CLEANFILES =
+ # This includes the standard gtk-doc make rules, copied by gtkdocize.
+ include $(top_srcdir)/gtk-doc.make
+ 
+ # Other files to distribute
+ # e.g. EXTRA_DIST += version.xml.in
meta-oe/recipes-navigation/gypsy/gypsy.inc new file +15 -0
new file mode 100644
index 0000000..0c1735e
@@ -0,0 +1,15 @@
+SUMMARY = "GPS Multiplexing Daemon"
+DESCRIPTION = "Gypsy is a GPS multiplexing daemon which allows \
+multiple clients to access GPS data from multiple GPS sources \
+concurrently.  Gypsy also hides the details of parsing NMEA from the \
+client applications, passing the data as simple values for the clients \
+to use."
+LICENSE = "GPLv2.0 & LGPLv2.1"
+SECTION = "x11"
+DEPENDS = "glib-2.0 dbus bluez4 dbus-glib"
+
+inherit autotools pkgconfig gtk-doc
+
+EXTRA_OECONF += "--with-distro=debian"
+
+FILES_${PN} += "/usr/share/dbus-1/services/"
meta-oe/recipes-navigation/gypsy/gypsy_0.9.bb new file +24 -0
new file mode 100644
index 0000000..51207c9
@@ -0,0 +1,24 @@
+SUMMARY = "GPS Multiplexing Daemon"
+DESCRIPTION = "Gypsy is a GPS multiplexing daemon which allows \
+multiple clients to access GPS data from multiple GPS sources \
+concurrently.  Gypsy also hides the details of parsing NMEA from the \
+client applications, passing the data as simple values for the clients \
+to use."
+LICENSE = "GPLv2+ & LGPLv2+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe \
+                    file://COPYING.lib;md5=7fbc338309ac38fefcd64b04bb903e34 \
+                    file://src/main.c;beginline=1;endline=25;md5=3fe64e27e61b289b77383a54a982cbdd \
+                    file://gypsy/gypsy-time.h;beginline=1;endline=24;md5=06432ea19a7b6607428d04d9dadc37fd"
+
+SECTION = "x11"
+DEPENDS = "glib-2.0 dbus bluez4 dbus-glib libxslt"
+
+SRC_URI = "http://gypsy.freedesktop.org/releases/gypsy-${PV}.tar.gz"
+PR = "r1"
+
+inherit autotools pkgconfig
+
+FILES_${PN} += "/usr/share/dbus-1/system-services/"
+
+SRC_URI[md5sum] = "e2d186df9c2cc3b70a027043e22acf1a"
+SRC_URI[sha256sum] = "14e1cbe17351f408538e033ca370b4bf51ccf9c88744e236ddfb271904f154d6"
meta-oe/recipes-navigation/gypsy/gypsy_git.bb new file +18 -0
new file mode 100644
index 0000000..e5c564f
@@ -0,0 +1,18 @@
+require gypsy.inc
+
+DEFAULT_PREFERENCE = "-1"
+
+SRCREV = "be8c9c382d2d1d37b51d29b0843045121ec90213"
+PV = "0.9+git${SRCPV}"
+PR = "r1"
+
+S = "${WORKDIR}/git"
+
+LICENSE = "GPLv2+ & LGPLv2+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe \
+                    file://COPYING.lib;md5=7fbc338309ac38fefcd64b04bb903e34 \
+                    file://src/main.c;beginline=1;endline=25;md5=3fe64e27e61b289b77383a54a982cbdd \
+                    file://gypsy/gypsy-time.h;beginline=1;endline=24;md5=06432ea19a7b6607428d04d9dadc37fd"
+
+SRC_URI = "git://anongit.freedesktop.org/gypsy;protocol=git \
+           file://fixups.patch"
Signature · 1 line
1.8.0
#2 lore raw

PATCH 2/5 samba: update waf-as-source.patch to apply

In reply to Martin Jansa

* and Applying patch waf-as-source.patch
...
File buildtools/bin/waf-svn is not empty after patch; not deleting
...
Patch waf-as-source.patch does not apply (enforce with -f) I've dropped this chunk and now it builds

* there is also WARNING about unpackaged but empty base_sbindir
WARNING: QA Issue: samba: Files/directories were installed but not shipped
/sbin
created by do_install in samba.inc but used only when cifs is built, maybe we should remove it from samba.inc now

---
 meta-oe/recipes-connectivity/samba/samba-3.6.8/waf-as-source.patch | 4 ----
 meta-oe/recipes-connectivity/samba/samba_3.6.8.bb                  | 2 +-
 2 files changed, 1 insertion(+), 5 deletions(-)
meta-oe/recipes-connectivity/samba/samba-3.6.8/waf-as-source.patch +0 -4
index 3ba7d23..985ed5a 100644
@@ -44,10 +44,6 @@ index 9ef8a1f..0000000
 -You can get a svn copy of the upstream source with:
 -
 -  svn checkout http://waf.googlecode.com/svn/trunk/ waf-read-only
-diff --git a/buildtools/bin/waf-svn b/buildtools/bin/waf-svn
-deleted file mode 100755
-index 6d54d5f..0000000
-Binary files a/buildtools/bin/waf-svn and /dev/null differ
 diff --git a/buildtools/update-waf.sh b/buildtools/update-waf.sh
 new file mode 100755
 index 0000000..bb3a4bf
meta-oe/recipes-connectivity/samba/samba_3.6.8.bb +1 -1
index cc09a48..7c54dae 100644
@@ -3,7 +3,7 @@ require samba-basic.inc
 LICENSE = "GPLv3"
 LIC_FILES_CHKSUM = "file://../COPYING;md5=d32239bcb673463ab874e80d47fae504"
 
-PR = "r1"
+PR = "r2"
 
 SRC_URI += "\
     file://config-h.patch \
Signature · 1 line
1.8.0
#3 lore raw

PATCH 3/5 ntp: cleanup recipes and fix SSL support

In reply to Martin Jansa

From: Paul Eggleton <[email protected]>

* Move common definitions to the inc file
* Drop override of do_configure which doesn't seem to be needed anymore
* Fold ntp-ssl into the ntp recipe as a PACKAGECONFIG option for those who want it (default to off) and fix configure-time checks to detect OpenSSL properly so that it gets enabled when selected
* Remove ntp-bin package and put its contents in currently empty ntp-utils package (with migration path)
* Fix hardcoded paths in ntpd initscript
* Specify ntpd.conf as a configuration file for packaging purposes
* Rearrange so that packaging definitions are towards the end in the expected order
* Delete unused "ntp" initscript file
* Add SUMMARY
* Update HOMEPAGE

This reapplies some of the changes from the original patch by Morgan Little <[email protected]>.

---
 meta-networking/recipes-support/ntp/files/ntp      | 31 --------
 .../recipes-support/ntp/files/openssl-check.patch  | 59 +++++++++++++++
 .../recipes-support/ntp/ntp-ssl_4.2.6p5.bb         | 11 ---
 meta-networking/recipes-support/ntp/ntp.inc        | 87 +++++++++++++++++-----
 meta-networking/recipes-support/ntp/ntp_4.2.6p5.bb | 44 +----------
 5 files changed, 131 insertions(+), 101 deletions(-)
 delete mode 100755 meta-networking/recipes-support/ntp/files/ntp
 create mode 100644 meta-networking/recipes-support/ntp/files/openssl-check.patch
 delete mode 100644 meta-networking/recipes-support/ntp/ntp-ssl_4.2.6p5.bb
meta-networking/recipes-support/ntp/files/ntp deleted +0 -31
deleted file mode 100755
index e91a528..0000000
@@ -1,31 +0,0 @@
-#! /bin/sh
-
-FLAGS="defaults 23"
-
-test -f /usr/bin/ntpd || exit 0
-
-case "$1" in
-	start)
-		echo -n "Starting NTP server: ntpd"
-  		start-stop-daemon --start --quiet --exec /usr/bin/ntpd
-		echo "."
-  		;;
-	stop)
-		echo -n "Stopping NTP server: ntpd"
-  		start-stop-daemon --stop --quiet --exec /usr/bin/ntpd
-		echo "."
-  		;;
-	restart|force-reload)
-		echo -n "Restarting NTP server: ntpd... "
-  		start-stop-daemon --stop --quiet --exec /usr/bin/ntpd
-  		sleep 2
-  		start-stop-daemon --start --quiet --exec /usr/bin/ntpd
-		echo "done."
-  		;;
-	*)
-  		echo "Usage: /etc/init.d/ntp {start|stop|restart|force-reload}"
-  		exit 1
-		;;
-esac
-
-exit 0
meta-networking/recipes-support/ntp/files/openssl-check.patch new file +59 -0

59 lines not on this page · raw message

meta-networking/recipes-support/ntp/ntp-ssl_4.2.6p5.bb deleted +0 -11
deleted file mode 100644
index a158990..0000000
@@ -1,11 +0,0 @@
-require ntp_${PV}.bb
-DEPENDS = "openssl"
-
-S = "${WORKDIR}/ntp-${PV}"
-
-EXTRA_OECONF = "--with-openssl-libdir=${STAGING_LIBDIR} \
-	        --with-openssl-incdir=${STAGING_INCDIR}/openssl"
-
-
-SRC_URI[md5sum] = "98e16c7aa4ecd4c004b51bff18962e95"
-SRC_URI[sha256sum] = "9f4a5271a285d390c9225e3ea28f70049ea377d30fc6de4659007cfff278671a"
meta-networking/recipes-support/ntp/ntp.inc +69 -18

104 lines not on this page · raw message

meta-networking/recipes-support/ntp/ntp_4.2.6p5.bb +3 -41

48 lines not on this page · raw message

Signature · 1 line
1.8.0
#4 lore raw

Re: [PATCH 3/5] ntp: cleanup recipes and fix SSL support

Quoted 304 lines · Martin Jansa

From: Paul Eggleton <[email protected]>

* Move common definitions to the inc file
* Drop override of do_configure which doesn't seem to be needed anymore
* Fold ntp-ssl into the ntp recipe as a PACKAGECONFIG option for those who want it (default to off) and fix configure-time checks to detect OpenSSL properly so that it gets enabled when selected
* Remove ntp-bin package and put its contents in currently empty ntp-utils package (with migration path)
* Fix hardcoded paths in ntpd initscript
* Specify ntpd.conf as a configuration file for packaging purposes
* Rearrange so that packaging definitions are towards the end in the expected order
* Delete unused "ntp" initscript file
* Add SUMMARY
* Update HOMEPAGE

This reapplies some of the changes from the original patch by Morgan Little <[email protected]>.

---
  meta-networking/recipes-support/ntp/files/ntp      | 31 --------
  .../recipes-support/ntp/files/openssl-check.patch  | 59 +++++++++++++++
  .../recipes-support/ntp/ntp-ssl_4.2.6p5.bb         | 11 ---
  meta-networking/recipes-support/ntp/ntp.inc        | 87 +++++++++++++++++-----
  meta-networking/recipes-support/ntp/ntp_4.2.6p5.bb | 44 +----------
  5 files changed, 131 insertions(+), 101 deletions(-)

delete mode 100755 meta-networking/recipes-support/ntp/files/ntp create mode 100644 meta-networking/recipes-support/ntp/files/openssl-check.patch delete mode 100644 meta-networking/recipes-support/ntp/ntp-ssl_4.2.6p5.bb

meta-networking/recipes-support/ntp/files/ntp deleted +0 -31
deleted file mode 100755
index e91a528..0000000
@@ -1,31 +0,0 @@
-#! /bin/sh
-
-FLAGS="defaults 23"
-
-test -f /usr/bin/ntpd || exit 0
-
-case "$1" in
-	start)
-		echo -n "Starting NTP server: ntpd"
-  		start-stop-daemon --start --quiet --exec /usr/bin/ntpd
-		echo "."
-  		;;
-	stop)
-		echo -n "Stopping NTP server: ntpd"
-  		start-stop-daemon --stop --quiet --exec /usr/bin/ntpd
-		echo "."
-  		;;
-	restart|force-reload)
-		echo -n "Restarting NTP server: ntpd... "
-  		start-stop-daemon --stop --quiet --exec /usr/bin/ntpd
-  		sleep 2
-  		start-stop-daemon --start --quiet --exec /usr/bin/ntpd
-		echo "done."
-  		;;
-	*)
-  		echo "Usage: /etc/init.d/ntp {start|stop|restart|force-reload}"
-  		exit 1
-		;;
-esac
-
-exit 0
meta-networking/recipes-support/ntp/files/openssl-check.patch new file +59 -0
new file mode 100644
index 0000000..8b4a673
@@ -0,0 +1,59 @@
+Hack OpenSSL check to work when libssl and libcrypto aren't in same dir
+
+Upstream-Status: Inappropriate [config]
+
+Signed-off-by: Paul Eggleton <[email protected]>
+---
+ configure         |    4 ++--
+ m4/ntp_openssl.m4 |    4 ++--
+ sntp/configure    |    4 ++--
+ 3 files changed, 6 insertions(+), 6 deletions(-)
+
+diff --git a/configure b/configure
+index aae2c01..6a3c15e 100755
+--- a/configure
++++ b/configure
+@@ -22868,8 +22868,8 @@ case "$ans" in
+ 	    test -f $i/libcrypto.dylib -a -f $i/libssl.dylib && break
+ 	    ;;
+ 	 *)
+-	    test -f $i/libcrypto.so -a -f $i/libssl.so && break
+-	    test -f $i/libcrypto.a -a -f $i/libssl.a && break
++	    test -f $i/libssl.so && break
++	    test -f $i/libssl.a && break
+ 	    ;;
+ 	esac
+     done
+diff --git a/m4/ntp_openssl.m4 b/m4/ntp_openssl.m4
+index 7d9f477..67bdd55 100644
+--- a/m4/ntp_openssl.m4
++++ b/m4/ntp_openssl.m4
+@@ -41,8 +41,8 @@ case "$ans" in
+ 	    test -f $i/libcrypto.dylib -a -f $i/libssl.dylib && break
+ 	    ;;
+ 	 *)
+-	    test -f $i/libcrypto.so -a -f $i/libssl.so && break
+-	    test -f $i/libcrypto.a -a -f $i/libssl.a && break
++	    test -f $i/libssl.so && break
++	    test -f $i/libssl.a && break
+ 	    ;;
+ 	esac
+     done
+diff --git a/sntp/configure b/sntp/configure
+index 7782c29..55e82d9 100755
+--- a/sntp/configure
++++ b/sntp/configure
+@@ -14810,8 +14810,8 @@ case "$ans" in
+ 	    test -f $i/libcrypto.dylib -a -f $i/libssl.dylib && break
+ 	    ;;
+ 	 *)
+-	    test -f $i/libcrypto.so -a -f $i/libssl.so && break
+-	    test -f $i/libcrypto.a -a -f $i/libssl.a && break
++	    test -f $i/libssl.so && break
++	    test -f $i/libssl.a && break
+ 	    ;;
+ 	esac
+     done
+--
+1.7.1
+
meta-networking/recipes-support/ntp/ntp-ssl_4.2.6p5.bb deleted +0 -11
deleted file mode 100644
index a158990..0000000
@@ -1,11 +0,0 @@
-require ntp_${PV}.bb
-DEPENDS = "openssl"
-
-S = "${WORKDIR}/ntp-${PV}"
-
-EXTRA_OECONF = "--with-openssl-libdir=${STAGING_LIBDIR} \
-	        --with-openssl-incdir=${STAGING_INCDIR}/openssl"
-
-
-SRC_URI[md5sum] = "98e16c7aa4ecd4c004b51bff18962e95"
-SRC_URI[sha256sum] = "9f4a5271a285d390c9225e3ea28f70049ea377d30fc6de4659007cfff278671a"
meta-networking/recipes-support/ntp/ntp.inc +69 -18
index 1d740f0..a614e3f 100644
@@ -1,35 +1,86 @@
+SUMMARY = "Network Time Protocol daemon and utilities"
  DESCRIPTION = "The Network Time Protocol (NTP) is used to \
  synchronize the time of a computer client or server to \
  another server or reference time source, such as a radio \
  or satellite receiver or modem."
-HOMEPAGE = "http://ntp.isc.org/bin/view/Main/WebHome"
+HOMEPAGE = "http://support.ntp.org"
  SECTION = "console/network"
  LICENSE = "ntp"
  LIC_FILES_CHKSUM = "file://COPYRIGHT;md5=fea4b50c33b18c2194b4b1c9ca512670"
-RSUGGESTS_${PN} = "iana-etc"
 
-SRC_URI = "http://www.eecis.udel.edu/~ntp/ntp_spool/ntp4/ntp-4.2/${P}.tar.gz \
-	file://ipv6only-workaround.patch \
-	file://ntpd \
-	file://ntp.conf \
-	file://ntpdate \
-	file://ntpd.service \
-"
+INC_PR = "r2"
 
-inherit autotools update-rc.d
+SRC_URI = "http://www.eecis.udel.edu/~ntp/ntp_spool/ntp4/ntp-4.2/ntp-${PV}.tar.gz \
+           file://tickadj.c.patch \
+           file://ntp-4.2.4_p6-nano.patch \
+           file://openssl-check.patch \
+           file://ntpd \
+           file://ntp.conf \
+           file://ntpdate \
+           "
 
-INITSCRIPT_NAME = "ntpd"
-# No dependencies, so just go in at the standard level (20)
-INITSCRIPT_PARAMS = "defaults"
+inherit autotools update-rc.d
 
  # The ac_cv_header_readline_history is to stop ntpdc depending on either
  # readline or curses
-EXTRA_OECONF = "--without-openssl --without-crypto ac_cv_header_readline_history_h=no"
+EXTRA_OECONF += "--with-net-snmp-config=no --without-ntpsnmpd ac_cv_header_readline_history_h=no"
  CFLAGS_append = " -DPTYS_ARE_GETPT -DPTYS_ARE_SEARCHED"
 
-PACKAGES += "ntpdate ${PN}-bin ${PN}-tickadj ${PN}-utils"
+PACKAGECONFIG ??= ""
+PACKAGECONFIG[openssl] = "--with-openssl-libdir=${STAGING_LIBDIR} \
+                          --with-openssl-incdir=${STAGING_INCDIR} \
+                          --with-crypto, \
+                          --without-openssl --without-crypto, \
+                          openssl"
+
+do_install_append() {
+	install -d ${D}${sysconfdir}/init.d
+	install -m 644 ${WORKDIR}/ntp.conf ${D}${sysconfdir}
+	install -m 755 ${WORKDIR}/ntpd ${D}${sysconfdir}/init.d
+
+	# Fix hardcoded paths in scripts
+	sed -i 's!/usr/sbin/!${sbindir}/!g' ${D}${sysconfdir}/init.d/ntpd
+	sed -i 's!/usr/bin/!${bindir}/!g' ${D}${sysconfdir}/init.d/ntpd
+	sed -i 's!/etc/!${sysconfdir}/!g' ${D}${sysconfdir}/init.d/ntpd
+	sed -i 's!/var/!${localstatedir}/!g' ${D}${sysconfdir}/init.d/ntpd
+
+	install -d ${D}${sysconfdir}/network/if-up.d
+	install -m 755 ${WORKDIR}/ntpdate ${D}${sysconfdir}/network/if-up.d
+}
+
+PACKAGES += "ntpdate ${PN}-tickadj ${PN}-utils"
  # NOTE: you don't need ntpdate, use "ntpd -q -g -x"
-# or the ntpdate systemd service
 
-# This should use rc.update
-FILES_ntpdate = "${bindir}/ntpdate ${sysconfdir}/init.d/ntpdate"
+# ntp originally includes tickadj. It's split off for inclusion in small firmware images on platforms
+# with wonky clocks (e.g. OpenSlug)
+RDEPENDS_${PN} = "${PN}-tickadj"
+# Handle move from bin to utils package
+RPROVIDES_${PN}-utils = "${PN}-bin"
+RREPLACES_${PN}-utils = "${PN}-bin"
+RCONFLICTS_${PN}-utils = "${PN}-bin"
+
+RSUGGESTS_${PN} = "iana-etc"
+
+FILES_${PN} = "${bindir}/ntpd ${sysconfdir}/ntp.conf ${sysconfdir}/init.d/ntpd ${sbindir} ${libdir}"
+FILES_${PN}-tickadj = "${bindir}/tickadj"
+FILES_${PN}-utils = "${bindir}"
+FILES_ntpdate = "${bindir}/ntpdate ${sysconfdir}/network/if-up.d/ntpdate"
+
+CONFFILES_${PN} = "${sysconfdir}/ntp.conf"
+
+INITSCRIPT_NAME = "ntpd"
+# No dependencies, so just go in at the standard level (20)
+INITSCRIPT_PARAMS = "defaults"
+
+pkg_postinst_ntpdate() {
+if test "x$D" != "x"; then
+        exit 1
+else
+        if ! grep -q -s ntpdate /var/spool/cron/root; then
+                echo "adding crontab"
+                test -d /var/spool/cron || mkdir -p /var/spool/cron
+                echo "30 * * * *    /usr/bin/ntpdate -b -s -u pool.ntp.org" >> /var/spool/cron/root
+        fi
+fi
+}
+
meta-networking/recipes-support/ntp/ntp_4.2.6p5.bb +1 -34
index f7c5b68..f1e9ecd 100644
@@ -1,45 +1,7 @@
  require ntp.inc
 
-SRC_URI = "http://www.eecis.udel.edu/~ntp/ntp_spool/ntp4/ntp-4.2/ntp-${PV}.tar.gz \
-        file://tickadj.c.patch \
-        file://ntp-4.2.4_p6-nano.patch \
-        file://ntpd \
-        file://ntp.conf \
-        file://ntpdate \
-"
+PR = "${INC_PR}.0"
 
-SRC_URI[md5sum] = "59876a9009b098ff59767ee45a88ebd2"
-SRC_URI[sha256sum] = "6e84d4ddfa14b911c3ed88463af10867e1fa9b287e7b34d8a02e78be85a7c40e"
-
-EXTRA_OECONF += " --with-net-snmp-config=no --without-ntpsnmpd"
-
-do_install_append() {
-	install -d ${D}/${sysconfdir}/init.d
-	install -m 644 ${WORKDIR}/ntp.conf ${D}/${sysconfdir}
-	install -m 755 ${WORKDIR}/ntpd ${D}/${sysconfdir}/init.d
-	install -d ${D}/${sysconfdir}/network/if-up.d
-	install -m 755 ${WORKDIR}/ntpdate ${D}/${sysconfdir}/network/if-up.d
-}
-
-FILES_${PN}-bin = "${bindir}/ntp-wait ${bindir}/ntpdc ${bindir}/ntpq ${bindir}/ntptime ${bindir}/ntptrace"
-FILES_${PN} = "${bindir}/ntpd ${sysconfdir}/ntp.conf ${sysconfdir}/init.d/ntpd"
-FILES_${PN}-tickadj = "${bindir}/tickadj"
-FILES_ntp-utils = "${bindir}/*"
-FILES_ntpdate = "${bindir}/ntpdate ${sysconfdir}/network/if-up.d/ntpdate"
-
-# ntp originally includes tickadj. It's split off for inclusion in small firmware images on platforms
-# with wonky clocks (e.g. OpenSlug)
-RDEPENDS_${PN} = "${PN}-tickadj"
-
-pkg_postinst_ntpdate() {
-if test "x$D" != "x"; then
-        exit 1
-else

meta-networking/recipes-support/ntp/ntp_4.2.6p5.bb line 7

Quoted 10 lines
meta-networking/recipes-support/ntp/ntp_4.2.6p5.bb +2 -7
-        if ! grep -q -s ntpdate /var/spool/cron/root; then
-                echo "adding crontab"
-                test -d /var/spool/cron || mkdir -p /var/spool/cron
-                echo "30 * * * *    /usr/bin/ntpdate -b -s -u pool.ntp.org" >> /var/spool/cron/root
-        fi
-fi
-}
+SRC_URI[md5sum] = "00df80a84ec9528fcfb09498075525bc"
+SRC_URI[sha256sum] = "d6ab8371f9d31e594eb6922823d5ccd03dcc4e9d84b0e23ea25ac1405432f91c"
 

I would like to see the checksum correction made as a separate commit on danny ASAP and before applying this more significant set of changes, so there's a working stable point to back up to if something goes wrong. Accepting http://patches.openembedded.org/patch/39697/ onto danny would accomplish this; alternatively I could re-submit that specifically for danny if that's preferable.

Peter

#5 lore raw

Re: [PATCH 3/5] ntp: cleanup recipes and fix SSL support

Quoted 305 lines · [Re: [oe] [PATCH 3/5] ntp: cleanup recipes and fix SSL support] On 12.12.04…
Quoted 304 lines · Martin Jansa

From: Paul Eggleton <[email protected]>

* Move common definitions to the inc file
* Drop override of do_configure which doesn't seem to be needed anymore
* Fold ntp-ssl into the ntp recipe as a PACKAGECONFIG option for those who want it (default to off) and fix configure-time checks to detect OpenSSL properly so that it gets enabled when selected
* Remove ntp-bin package and put its contents in currently empty ntp-utils package (with migration path)
* Fix hardcoded paths in ntpd initscript
* Specify ntpd.conf as a configuration file for packaging purposes
* Rearrange so that packaging definitions are towards the end in the expected order
* Delete unused "ntp" initscript file
* Add SUMMARY
* Update HOMEPAGE

This reapplies some of the changes from the original patch by Morgan Little <[email protected]>.

---
 meta-networking/recipes-support/ntp/files/ntp      | 31 --------
 .../recipes-support/ntp/files/openssl-check.patch  | 59 +++++++++++++++
 .../recipes-support/ntp/ntp-ssl_4.2.6p5.bb         | 11 ---
 meta-networking/recipes-support/ntp/ntp.inc        | 87 +++++++++++++++++-----
 meta-networking/recipes-support/ntp/ntp_4.2.6p5.bb | 44 +----------
 5 files changed, 131 insertions(+), 101 deletions(-)
 delete mode 100755 meta-networking/recipes-support/ntp/files/ntp
 create mode 100644 meta-networking/recipes-support/ntp/files/openssl-check.patch
 delete mode 100644 meta-networking/recipes-support/ntp/ntp-ssl_4.2.6p5.bb
meta-networking/recipes-support/ntp/files/ntp deleted +0 -31
deleted file mode 100755
index e91a528..0000000
@@ -1,31 +0,0 @@
-#! /bin/sh
-
-FLAGS="defaults 23"
-
-test -f /usr/bin/ntpd || exit 0
-
-case "$1" in
-	start)
-		echo -n "Starting NTP server: ntpd"
-  		start-stop-daemon --start --quiet --exec /usr/bin/ntpd
-		echo "."
-  		;;
-	stop)
-		echo -n "Stopping NTP server: ntpd"
-  		start-stop-daemon --stop --quiet --exec /usr/bin/ntpd
-		echo "."
-  		;;
-	restart|force-reload)
-		echo -n "Restarting NTP server: ntpd... "
-  		start-stop-daemon --stop --quiet --exec /usr/bin/ntpd
-  		sleep 2
-  		start-stop-daemon --start --quiet --exec /usr/bin/ntpd
-		echo "done."
-  		;;
-	*)
-  		echo "Usage: /etc/init.d/ntp {start|stop|restart|force-reload}"
-  		exit 1
-		;;
-esac
-
-exit 0
meta-networking/recipes-support/ntp/files/openssl-check.patch new file +59 -0
new file mode 100644
index 0000000..8b4a673
@@ -0,0 +1,59 @@
+Hack OpenSSL check to work when libssl and libcrypto aren't in same dir
+
+Upstream-Status: Inappropriate [config]
+
+Signed-off-by: Paul Eggleton <[email protected]>
+---
+ configure         |    4 ++--
+ m4/ntp_openssl.m4 |    4 ++--
+ sntp/configure    |    4 ++--
+ 3 files changed, 6 insertions(+), 6 deletions(-)
+
+diff --git a/configure b/configure
+index aae2c01..6a3c15e 100755
+--- a/configure
++++ b/configure
+@@ -22868,8 +22868,8 @@ case "$ans" in
+ 	    test -f $i/libcrypto.dylib -a -f $i/libssl.dylib && break
+ 	    ;;
+ 	 *)
+-	    test -f $i/libcrypto.so -a -f $i/libssl.so && break
+-	    test -f $i/libcrypto.a -a -f $i/libssl.a && break
++	    test -f $i/libssl.so && break
++	    test -f $i/libssl.a && break
+ 	    ;;
+ 	esac
+     done
+diff --git a/m4/ntp_openssl.m4 b/m4/ntp_openssl.m4
+index 7d9f477..67bdd55 100644
+--- a/m4/ntp_openssl.m4
++++ b/m4/ntp_openssl.m4
+@@ -41,8 +41,8 @@ case "$ans" in
+ 	    test -f $i/libcrypto.dylib -a -f $i/libssl.dylib && break
+ 	    ;;
+ 	 *)
+-	    test -f $i/libcrypto.so -a -f $i/libssl.so && break
+-	    test -f $i/libcrypto.a -a -f $i/libssl.a && break
++	    test -f $i/libssl.so && break
++	    test -f $i/libssl.a && break
+ 	    ;;
+ 	esac
+     done
+diff --git a/sntp/configure b/sntp/configure
+index 7782c29..55e82d9 100755
+--- a/sntp/configure
++++ b/sntp/configure
+@@ -14810,8 +14810,8 @@ case "$ans" in
+ 	    test -f $i/libcrypto.dylib -a -f $i/libssl.dylib && break
+ 	    ;;
+ 	 *)
+-	    test -f $i/libcrypto.so -a -f $i/libssl.so && break
+-	    test -f $i/libcrypto.a -a -f $i/libssl.a && break
++	    test -f $i/libssl.so && break
++	    test -f $i/libssl.a && break
+ 	    ;;
+ 	esac
+     done
+--
+1.7.1
+
meta-networking/recipes-support/ntp/ntp-ssl_4.2.6p5.bb deleted +0 -11
deleted file mode 100644
index a158990..0000000
@@ -1,11 +0,0 @@
-require ntp_${PV}.bb
-DEPENDS = "openssl"
-
-S = "${WORKDIR}/ntp-${PV}"
-
-EXTRA_OECONF = "--with-openssl-libdir=${STAGING_LIBDIR} \
-	        --with-openssl-incdir=${STAGING_INCDIR}/openssl"
-
-
-SRC_URI[md5sum] = "98e16c7aa4ecd4c004b51bff18962e95"
-SRC_URI[sha256sum] = "9f4a5271a285d390c9225e3ea28f70049ea377d30fc6de4659007cfff278671a"
meta-networking/recipes-support/ntp/ntp.inc +69 -18
index 1d740f0..a614e3f 100644
@@ -1,35 +1,86 @@
+SUMMARY = "Network Time Protocol daemon and utilities"
 DESCRIPTION = "The Network Time Protocol (NTP) is used to \
 synchronize the time of a computer client or server to \
 another server or reference time source, such as a radio \
 or satellite receiver or modem."
-HOMEPAGE = "http://ntp.isc.org/bin/view/Main/WebHome"
+HOMEPAGE = "http://support.ntp.org"
 SECTION = "console/network"
 LICENSE = "ntp"
 LIC_FILES_CHKSUM = "file://COPYRIGHT;md5=fea4b50c33b18c2194b4b1c9ca512670"
-RSUGGESTS_${PN} = "iana-etc"
-SRC_URI = "http://www.eecis.udel.edu/~ntp/ntp_spool/ntp4/ntp-4.2/${P}.tar.gz \
-	file://ipv6only-workaround.patch \
-	file://ntpd \
-	file://ntp.conf \
-	file://ntpdate \
-	file://ntpd.service \
-"
+INC_PR = "r2"
-inherit autotools update-rc.d
+SRC_URI = "http://www.eecis.udel.edu/~ntp/ntp_spool/ntp4/ntp-4.2/ntp-${PV}.tar.gz \
+           file://tickadj.c.patch \
+           file://ntp-4.2.4_p6-nano.patch \
+           file://openssl-check.patch \
+           file://ntpd \
+           file://ntp.conf \
+           file://ntpdate \
+           "
-INITSCRIPT_NAME = "ntpd"
-# No dependencies, so just go in at the standard level (20)
-INITSCRIPT_PARAMS = "defaults"
+inherit autotools update-rc.d
 # The ac_cv_header_readline_history is to stop ntpdc depending on either
 # readline or curses
-EXTRA_OECONF = "--without-openssl --without-crypto ac_cv_header_readline_history_h=no"
+EXTRA_OECONF += "--with-net-snmp-config=no --without-ntpsnmpd ac_cv_header_readline_history_h=no"
 CFLAGS_append = " -DPTYS_ARE_GETPT -DPTYS_ARE_SEARCHED"
-PACKAGES += "ntpdate ${PN}-bin ${PN}-tickadj ${PN}-utils"
+PACKAGECONFIG ??= ""
+PACKAGECONFIG[openssl] = "--with-openssl-libdir=${STAGING_LIBDIR} \
+                          --with-openssl-incdir=${STAGING_INCDIR} \
+                          --with-crypto, \
+                          --without-openssl --without-crypto, \
+                          openssl"
+
+do_install_append() {
+	install -d ${D}${sysconfdir}/init.d
+	install -m 644 ${WORKDIR}/ntp.conf ${D}${sysconfdir}
+	install -m 755 ${WORKDIR}/ntpd ${D}${sysconfdir}/init.d
+
+	# Fix hardcoded paths in scripts
+	sed -i 's!/usr/sbin/!${sbindir}/!g' ${D}${sysconfdir}/init.d/ntpd
+	sed -i 's!/usr/bin/!${bindir}/!g' ${D}${sysconfdir}/init.d/ntpd
+	sed -i 's!/etc/!${sysconfdir}/!g' ${D}${sysconfdir}/init.d/ntpd
+	sed -i 's!/var/!${localstatedir}/!g' ${D}${sysconfdir}/init.d/ntpd
+
+	install -d ${D}${sysconfdir}/network/if-up.d
+	install -m 755 ${WORKDIR}/ntpdate ${D}${sysconfdir}/network/if-up.d
+}
+
+PACKAGES += "ntpdate ${PN}-tickadj ${PN}-utils"
 # NOTE: you don't need ntpdate, use "ntpd -q -g -x"
-# or the ntpdate systemd service
-# This should use rc.update
-FILES_ntpdate = "${bindir}/ntpdate ${sysconfdir}/init.d/ntpdate"
+# ntp originally includes tickadj. It's split off for inclusion in small firmware images on platforms
+# with wonky clocks (e.g. OpenSlug)
+RDEPENDS_${PN} = "${PN}-tickadj"
+# Handle move from bin to utils package
+RPROVIDES_${PN}-utils = "${PN}-bin"
+RREPLACES_${PN}-utils = "${PN}-bin"
+RCONFLICTS_${PN}-utils = "${PN}-bin"
+
+RSUGGESTS_${PN} = "iana-etc"
+
+FILES_${PN} = "${bindir}/ntpd ${sysconfdir}/ntp.conf ${sysconfdir}/init.d/ntpd ${sbindir} ${libdir}"
+FILES_${PN}-tickadj = "${bindir}/tickadj"
+FILES_${PN}-utils = "${bindir}"
+FILES_ntpdate = "${bindir}/ntpdate ${sysconfdir}/network/if-up.d/ntpdate"
+
+CONFFILES_${PN} = "${sysconfdir}/ntp.conf"
+
+INITSCRIPT_NAME = "ntpd"
+# No dependencies, so just go in at the standard level (20)
+INITSCRIPT_PARAMS = "defaults"
+
+pkg_postinst_ntpdate() {
+if test "x$D" != "x"; then
+        exit 1
+else
+        if ! grep -q -s ntpdate /var/spool/cron/root; then
+                echo "adding crontab"
+                test -d /var/spool/cron || mkdir -p /var/spool/cron
+                echo "30 * * * *    /usr/bin/ntpdate -b -s -u pool.ntp.org" >> /var/spool/cron/root
+        fi
+fi
+}
+
meta-networking/recipes-support/ntp/ntp_4.2.6p5.bb +2 -41
index f7c5b68..f1e9ecd 100644
@@ -1,45 +1,7 @@
 require ntp.inc
-SRC_URI = "http://www.eecis.udel.edu/~ntp/ntp_spool/ntp4/ntp-4.2/ntp-${PV}.tar.gz \
-        file://tickadj.c.patch \
-        file://ntp-4.2.4_p6-nano.patch \
-        file://ntpd \
-        file://ntp.conf \
-        file://ntpdate \
-"
+PR = "${INC_PR}.0"
-SRC_URI[md5sum] = "59876a9009b098ff59767ee45a88ebd2"
-SRC_URI[sha256sum] = "6e84d4ddfa14b911c3ed88463af10867e1fa9b287e7b34d8a02e78be85a7c40e"
-
-EXTRA_OECONF += " --with-net-snmp-config=no --without-ntpsnmpd"
-
-do_install_append() {
-	install -d ${D}/${sysconfdir}/init.d
-	install -m 644 ${WORKDIR}/ntp.conf ${D}/${sysconfdir}
-	install -m 755 ${WORKDIR}/ntpd ${D}/${sysconfdir}/init.d
-	install -d ${D}/${sysconfdir}/network/if-up.d
-	install -m 755 ${WORKDIR}/ntpdate ${D}/${sysconfdir}/network/if-up.d
-}
-
-FILES_${PN}-bin = "${bindir}/ntp-wait ${bindir}/ntpdc ${bindir}/ntpq ${bindir}/ntptime ${bindir}/ntptrace"
-FILES_${PN} = "${bindir}/ntpd ${sysconfdir}/ntp.conf ${sysconfdir}/init.d/ntpd"
-FILES_${PN}-tickadj = "${bindir}/tickadj"
-FILES_ntp-utils = "${bindir}/*"
-FILES_ntpdate = "${bindir}/ntpdate ${sysconfdir}/network/if-up.d/ntpdate"
-
-# ntp originally includes tickadj. It's split off for inclusion in small firmware images on platforms
-# with wonky clocks (e.g. OpenSlug)
-RDEPENDS_${PN} = "${PN}-tickadj"
-
-pkg_postinst_ntpdate() {
-if test "x$D" != "x"; then
-        exit 1
-else
-        if ! grep -q -s ntpdate /var/spool/cron/root; then
-                echo "adding crontab"
-                test -d /var/spool/cron || mkdir -p /var/spool/cron
-                echo "30 * * * *    /usr/bin/ntpdate -b -s -u pool.ntp.org" >> /var/spool/cron/root
-        fi
-fi
-}
+SRC_URI[md5sum] = "00df80a84ec9528fcfb09498075525bc"
Quoted 8 lines

meta-networking/recipes-support/ntp/ntp_4.2.6p5.bb line 6

Quoted 1 line
meta-networking/recipes-support/ntp/ntp_4.2.6p5.bb +1 -0
+SRC_URI[sha256sum] = "d6ab8371f9d31e594eb6922823d5ccd03dcc4e9d84b0e23ea25ac1405432f91c"

I would like to see the checksum correction made as a separate commit on danny ASAP and before applying this more significant set of changes, so there's a working stable point to back up to if something goes wrong. Accepting
http://patches.openembedded.org/patch/39697/ onto danny would accomplish this; alternatively I could re-submit that specifically for danny if that's preferable.

Agreed. As a first step to sorting out the NTP thing, I've merged the above referenced patch into danny. Sorry about the delay.

Signature · 2 lines
-Joe MacDonald.
:wq
#6 lore raw

PATCH 4/5 ntp: make servers configurable and default to none configured

In reply to Martin Jansa

From: Paul Eggleton <[email protected]>

People can't blindly use pool.ntp.org, especially if they are building for a product or something that could be used in a product, so at least try to get people to do the right thing and not use pool.ntp.org by default.

The previous network interface up script is now installed as ntpdate-sync in ${bindir} (and symlinked as the network if-up script). NTPSERVERS needs to be set in /etc/default/ntpdate.default at runtime, or a different version of this file with a default value can be provided in a bbappend. (If you intend to use ntpd you will also want to provide an ntp.conf with the appropriate server(s) set there as well.)

---
 meta-networking/recipes-support/ntp/files/ntp.conf |  2 +-
 meta-networking/recipes-support/ntp/files/ntpdate  | 11 +++++++---
 .../recipes-support/ntp/files/ntpdate.default      |  7 ++++++
 meta-networking/recipes-support/ntp/ntp.inc        | 25 ++++++++++++++--------
 4 files changed, 32 insertions(+), 13 deletions(-)
 create mode 100644 meta-networking/recipes-support/ntp/files/ntpdate.default
meta-networking/recipes-support/ntp/files/ntp.conf +1 -1
index bf52440..a9cc838 100644
@@ -5,7 +5,7 @@ driftfile /etc/ntp.drift
 # This obtains a random server which will be close
 # (in IP terms) to the machine.  Add other servers
 # as required, or change this.
-server pool.ntp.org
+server time.server.example.com
 # Using local hardware clock as fallback
 # Disable this when using ntpd -q -g -x as ntpdate or it will sync to itself
 server 127.127.1.0
meta-networking/recipes-support/ntp/files/ntpdate +8 -3
index 784b029..ab0551c 100755
@@ -6,11 +6,16 @@ test -x /usr/bin/ntpdate || exit 0
 
 if test -f /etc/default/ntpdate ; then
 . /etc/default/ntpdate
-else
-NTPSERVERS="pool.ntp.org"
 fi
 
-test -n "$NTPSERVERS" || exit 0
+if [ "$NTPSERVERS" = "" ] ; then
+	if [ "$METHOD" = "" -a "$1" != "silent" ] ; then
+		echo "Please set NTPSERVERS in /etc/default/ntpdate"
+		exit 1
+	else
+		exit 0
+	fi
+fi
 
 # This is a heuristic:  The idea is that if a static interface is brought
 # up, that is a major event, and we can put in some extra effort to fix
meta-networking/recipes-support/ntp/files/ntpdate.default new file +7 -0
new file mode 100644
index 0000000..486b6e0
@@ -0,0 +1,7 @@
+# Configuration script used by ntpdate-sync script
+
+NTPSERVERS=""
+
+# Set to "yes" to write time to hardware clock on success
+UPDATE_HWCLOCK="no"
+
meta-networking/recipes-support/ntp/ntp.inc +16 -9
index a614e3f..b3586dc 100644
@@ -17,6 +17,7 @@ SRC_URI = "http://www.eecis.udel.edu/~ntp/ntp_spool/ntp4/ntp-4.2/ntp-${PV}.tar.g
            file://ntpd \
            file://ntp.conf \
            file://ntpdate \
+           file://ntpdate.default \
            "
 
 inherit autotools update-rc.d
@@ -37,15 +38,20 @@ do_install_append() {
 	install -d ${D}${sysconfdir}/init.d
 	install -m 644 ${WORKDIR}/ntp.conf ${D}${sysconfdir}
 	install -m 755 ${WORKDIR}/ntpd ${D}${sysconfdir}/init.d
+	install -d ${D}${bindir}
+	install -m 755 ${WORKDIR}/ntpdate ${D}${bindir}/ntpdate-sync
 
 	# Fix hardcoded paths in scripts
-	sed -i 's!/usr/sbin/!${sbindir}/!g' ${D}${sysconfdir}/init.d/ntpd
-	sed -i 's!/usr/bin/!${bindir}/!g' ${D}${sysconfdir}/init.d/ntpd
-	sed -i 's!/etc/!${sysconfdir}/!g' ${D}${sysconfdir}/init.d/ntpd
-	sed -i 's!/var/!${localstatedir}/!g' ${D}${sysconfdir}/init.d/ntpd
-
-	install -d ${D}${sysconfdir}/network/if-up.d
-	install -m 755 ${WORKDIR}/ntpdate ${D}${sysconfdir}/network/if-up.d
+	sed -i 's!/usr/sbin/!${sbindir}/!g' ${D}${sysconfdir}/init.d/ntpd ${D}${bindir}/ntpdate-sync
+	sed -i 's!/usr/bin/!${bindir}/!g' ${D}${sysconfdir}/init.d/ntpd ${D}${bindir}/ntpdate-sync
+	sed -i 's!/etc/!${sysconfdir}/!g' ${D}${sysconfdir}/init.d/ntpd ${D}${bindir}/ntpdate-sync
+	sed -i 's!/var/!${localstatedir}/!g' ${D}${sysconfdir}/init.d/ntpd ${D}${bindir}/ntpdate-sync
+	sed -i 's!^PATH=.*!PATH=${base_sbindir}:${base_bindir}:${sbindir}:${bindir}!' ${D}${bindir}/ntpdate-sync
+
+	install -d ${D}/${sysconfdir}/default
+	install -m 644 ${WORKDIR}/ntpdate.default ${D}${sysconfdir}/default/ntpdate
+	install -d ${D}/${sysconfdir}/network/if-up.d
+	ln -s ${bindir}/ntpdate-sync ${D}/${sysconfdir}/network/if-up.d
 }
 
 PACKAGES += "ntpdate ${PN}-tickadj ${PN}-utils"
@@ -64,9 +70,10 @@ RSUGGESTS_${PN} = "iana-etc"
 FILES_${PN} = "${bindir}/ntpd ${sysconfdir}/ntp.conf ${sysconfdir}/init.d/ntpd ${sbindir} ${libdir}"
 FILES_${PN}-tickadj = "${bindir}/tickadj"
 FILES_${PN}-utils = "${bindir}"
-FILES_ntpdate = "${bindir}/ntpdate ${sysconfdir}/network/if-up.d/ntpdate"
+FILES_ntpdate = "${bindir}/ntpdate ${sysconfdir}/network/if-up.d/ntpdate-sync ${bindir}/ntpdate-sync ${sysconfdir}/default/ntpdate"
 
 CONFFILES_${PN} = "${sysconfdir}/ntp.conf"
+CONFFILES_ntpdate = "${sysconfdir}/default/ntpdate"
 
 INITSCRIPT_NAME = "ntpd"
 # No dependencies, so just go in at the standard level (20)
@@ -79,7 +86,7 @@ else
         if ! grep -q -s ntpdate /var/spool/cron/root; then
                 echo "adding crontab"
                 test -d /var/spool/cron || mkdir -p /var/spool/cron
-                echo "30 * * * *    /usr/bin/ntpdate -b -s -u pool.ntp.org" >> /var/spool/cron/root
+                echo "30 * * * *    ${bindir}/ntpdate-sync silent" >> /var/spool/cron/root
         fi
 fi
 }
Signature · 1 line
1.8.0
#7 lore raw

PATCH 5/5 meta-systemd: ntp: update for server config improvements

In reply to Martin Jansa

From: Paul Eggleton <[email protected]>

This makes the service use the ntpdate-sync command which reads the servers set in /etc/default/ntpdate; if nothing is set then no error is produced on startup.

---
 meta-systemd/meta-networking/recipes-support/ntp/ntp/ntpdate.service | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
meta-systemd/meta-networking/recipes-support/ntp/ntp/ntpdate.service +1 -1
index b2bc632..10cbd70 100644
@@ -4,7 +4,7 @@ Before=ntpd.service
 
 [Service]
 Type=oneshot
-ExecStart=/usr/bin/ntpd -q -g -x
+ExecStart=/usr/bin/ntpdate-sync silent
 RemainAfterExit=yes
 
 [Install]
Signature · 1 line
1.8.0
#8 lore raw
In reply to Martin Jansa
Quoted 12 lines · Martin Jansa

The following changes since commit f8ad0760abf8055bac27036853c56f56b40a36c7:

README: update to danny (2012-11-23 15:22:46 +0100)

are available in the git repository at:

git://git.openembedded.org/meta-openembedded-contrib jansa/for-danny
http://cgit.openembedded.org/cgit.cgi/meta-openembedded-contrib/log/?h=jansa/for-danny

Andrei Dinu (1):
gypsy: added to meta-oe/recipes-navigation

Quoted 7 lines

Martin Jansa (1):
samba: update waf-as-source.patch to apply

Paul Eggleton (3):
ntp: cleanup recipes and fix SSL support
ntp: make servers configurable and default to none configured
meta-systemd: ntp: update for server config improvements

ping?

Applied
#9 lore raw

Hi Martin,

Quoted 16 lines · Martin Jansa
Quoted 15 lines · Martin Jansa

The following changes since commit f8ad0760abf8055bac27036853c56f56b40a36c7:

README: update to danny (2012-11-23 15:22:46 +0100)

are available in the git repository at:

git://git.openembedded.org/meta-openembedded-contrib jansa/for-danny
http://cgit.openembedded.org/cgit.cgi/meta-openembedded-contrib/log/?h=jansa/for-danny

Andrei Dinu (1):
gypsy: added to meta-oe/recipes-navigation

Martin Jansa (1):
samba: update waf-as-source.patch to apply

Quoted 6 lines
Quoted 4 lines

Paul Eggleton (3):
ntp: cleanup recipes and fix SSL support
ntp: make servers configurable and default to none configured
meta-systemd: ntp: update for server config improvements

ping?

please don't forget to cc me for patches concerning danny.

merged into danny-next

Thanks
Eric