Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Angelo Compagnucci <angelo@amarulasolutions.com>
To: buildroot@buildroot.org
Cc: Angelo Compagnucci <angelo@amarulasolutions.com>
Subject: [Buildroot] [PATCH] package/htpdate: bump to version 1.3.3
Date: Thu, 20 Jan 2022 22:19:41 +0100	[thread overview]
Message-ID: <20220120211941.1033249-1-angelo@amarulasolutions.com> (raw)

Update project to its new location and move to use the package provided
init scripts.

Signed-off-by: Angelo Compagnucci <angelo@amarulasolutions.com>
---
 package/htpdate/S43htpdate      | 51 ---------------------------------
 package/htpdate/htpdate.hash    |  2 +-
 package/htpdate/htpdate.mk      |  6 ++--
 package/htpdate/htpdate.service | 13 ---------
 4 files changed, 4 insertions(+), 68 deletions(-)
 delete mode 100644 package/htpdate/S43htpdate
 delete mode 100644 package/htpdate/htpdate.service

diff --git a/package/htpdate/S43htpdate b/package/htpdate/S43htpdate
deleted file mode 100644
index 75f9a995ff..0000000000
--- a/package/htpdate/S43htpdate
+++ /dev/null
@@ -1,51 +0,0 @@
-#!/bin/sh
-
-DAEMON="htpdate"
-PIDFILE="/var/run/$DAEMON.pid"
-
-HTPDATE_ARGS="-a -s -t https://google.com"
-test -r "/etc/default/$DAEMON" && . "/etc/default/$DAEMON"
-
-start() {
-	printf 'Starting %s: ' "$DAEMON"
-	# shellcheck disable=SC2086 # we need the word splitting
-	start-stop-daemon -S -q -x "/usr/bin/$DAEMON" \
-		-- -D -i "$PIDFILE" $HTPDATE_ARGS
-	status=$?
-	if [ "$status" -eq 0 ]; then
-		echo "OK"
-	else
-		echo "FAIL"
-	fi
-	return "$status"
-}
-
-stop() {
-	printf 'Stopping %s: ' "$DAEMON"
-	start-stop-daemon -K -q -p "$PIDFILE"
-	status=$?
-	if [ "$status" -eq 0 ]; then
-		rm -f "$PIDFILE"
-		echo "OK"
-	else
-		echo "FAIL"
-	fi
-	return "$status"
-}
-
-restart() {
-	stop
-	sleep 1
-	start
-}
-
-case "$1" in
-	start|stop|restart)
-		"$1";;
-	reload)
-		# Restart, since there is no true "reload" feature.
-		restart;;
-	*)
-		echo "Usage: $0 {start|stop|restart|reload}"
-		exit 1
-esac
diff --git a/package/htpdate/htpdate.hash b/package/htpdate/htpdate.hash
index c38e8784e1..ef27f8f94c 100644
--- a/package/htpdate/htpdate.hash
+++ b/package/htpdate/htpdate.hash
@@ -1,3 +1,3 @@
 # Locally calculated:
-sha256 f6fb63b18a0d836fda721ae5655ae0b87055db1b582e98c4700f64e1ba5e2d5a  htpdate-1.3.1.tar.gz
+sha256 74f34b013eba6f99369819fa4b3d48e9ab5e531ad04f6af59cc04e8777c76ed7  htpdate-1.3.3.tar.gz
 sha256 b1c8d41afde943cacedab52cbb44ef7ffb7026e738b9c891009e89559fe31c20  LICENSE
diff --git a/package/htpdate/htpdate.mk b/package/htpdate/htpdate.mk
index e9323f9106..3c4412b283 100644
--- a/package/htpdate/htpdate.mk
+++ b/package/htpdate/htpdate.mk
@@ -4,7 +4,7 @@
 #
 ################################################################################
 
-HTPDATE_VERSION = 1.3.1
+HTPDATE_VERSION = 1.3.3
 HTPDATE_SITE = $(call github,twekkel,htpdate,v$(HTPDATE_VERSION))
 HTPDATE_LICENSE = GPL-2.0+
 HTPDATE_LICENSE_FILES = LICENSE
@@ -23,12 +23,12 @@ define HTPDATE_INSTALL_TARGET_CMDS
 endef
 
 define HTPDATE_INSTALL_INIT_SYSV
-	$(INSTALL) -D -m 0755 package/htpdate/S43htpdate \
+	$(INSTALL) -D -m 0755 $(@D)/scripts/htpdate.init \
 		$(TARGET_DIR)/etc/init.d/S43htpdate
 endef
 
 define HTPDATE_INSTALL_INIT_SYSTEMD
-	$(INSTALL) -D -m 0644 package/htpdate/htpdate.service \
+	$(INSTALL) -D -m 0644 $(@D)/scripts/htpdate.service \
 		$(TARGET_DIR)/usr/lib/systemd/system/htpdate.service
 endef
 
diff --git a/package/htpdate/htpdate.service b/package/htpdate/htpdate.service
deleted file mode 100644
index b7f1371b08..0000000000
--- a/package/htpdate/htpdate.service
+++ /dev/null
@@ -1,13 +0,0 @@
-[Unit]
-Description=htpdate daemon
-After=network.target
-
-[Service]
-Type=forking
-PIDFile=/run/htpdate.pid
-Environment=HTPDATE_ARGS="-a -s -t https://www.google.com"
-EnvironmentFile=-/etc/default/htpdate
-ExecStart=/usr/bin/htpdate -D -i /run/htpdate.pid $HTPDATE_ARGS
-
-[Install]
-WantedBy=multi-user.target
-- 
2.25.1

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

             reply	other threads:[~2022-01-20 21:19 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-01-20 21:19 Angelo Compagnucci [this message]
2022-01-21 20:39 ` [Buildroot] [PATCH] package/htpdate: bump to version 1.3.3 Yann E. MORIN
2022-01-21 20:44   ` Yann E. MORIN

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20220120211941.1033249-1-angelo@amarulasolutions.com \
    --to=angelo@amarulasolutions.com \
    --cc=buildroot@buildroot.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox