mirror of
https://github.com/MiyooCFW/buildroot.git
synced 2025-09-27 22:24:19 +03:00
Merge from bittboy/buildroot@db180c0
This commit is contained in:
16
package/inadyn/Config.in
Normal file
16
package/inadyn/Config.in
Normal file
@@ -0,0 +1,16 @@
|
||||
config BR2_PACKAGE_INADYN
|
||||
bool "inadyn"
|
||||
depends on BR2_USE_MMU # Uses fork()
|
||||
depends on !BR2_STATIC_LIBS # dlopen()
|
||||
select BR2_PACKAGE_LIBCONFUSE
|
||||
select BR2_PACKAGE_LIBITE
|
||||
help
|
||||
INADYN is a free DynDNS client. It gives the possibility
|
||||
to have your own fixed hostname registered on the internet,
|
||||
although your IP might be changing.
|
||||
|
||||
https://github.com/troglobit/inadyn
|
||||
|
||||
comment "inadyn needs a toolchain w/ dynamic library"
|
||||
depends on BR2_STATIC_LIBS
|
||||
depends on BR2_USE_MMU
|
||||
44
package/inadyn/S70inadyn
Normal file
44
package/inadyn/S70inadyn
Normal file
@@ -0,0 +1,44 @@
|
||||
#!/bin/sh
|
||||
#
|
||||
# Start & stop the inadyn client
|
||||
#
|
||||
|
||||
CONFIG=/etc/inadyn.conf
|
||||
|
||||
# check if CONFIG exists, print message & exit if it doesn't
|
||||
[ ! -f $CONFIG ] && ( echo "The config file "$CONFIG" is missing...exiting now." && exit 2 )
|
||||
|
||||
# Allow a few customizations from a config file. Especially inadyn
|
||||
# must be explicitly enabled by adding ENABLED="yes" in this file.
|
||||
test -r /etc/default/inadyn && . /etc/default/inadyn
|
||||
|
||||
case "$1" in
|
||||
start)
|
||||
printf "Starting inadyn: "
|
||||
if test "${ENABLED}" != "yes" ; then
|
||||
echo "SKIPPED"
|
||||
exit 0
|
||||
fi
|
||||
start-stop-daemon -b -q -S -p /var/run/inadyn.pid -x /usr/sbin/inadyn
|
||||
[ $? = 0 ] && echo "OK" || echo "FAIL"
|
||||
;;
|
||||
stop)
|
||||
printf "Stopping inadyn: "
|
||||
if test "${ENABLED}" != "yes" ; then
|
||||
echo "SKIPPED"
|
||||
exit 0
|
||||
fi
|
||||
start-stop-daemon -q -K -p /var/run/inadyn.pid -x /usr/sbin/inadyn
|
||||
[ $? = 0 ] && echo "OK" || echo "FAIL"
|
||||
rm -f /var/run/inadyn.pid
|
||||
;;
|
||||
restart)
|
||||
"$0" stop
|
||||
"$0" start
|
||||
;;
|
||||
*)
|
||||
echo "Usage: $0 {start|stop|restart}"
|
||||
exit 1
|
||||
esac
|
||||
|
||||
exit $?
|
||||
11
package/inadyn/inadyn.conf
Normal file
11
package/inadyn/inadyn.conf
Normal file
@@ -0,0 +1,11 @@
|
||||
# Basic configuration file for inadyn
|
||||
#
|
||||
# /etc/inadyn.conf
|
||||
iface = eth0
|
||||
period = 300
|
||||
|
||||
provider default@dyndns.org {
|
||||
username = test
|
||||
password = test
|
||||
hostname = test
|
||||
}
|
||||
5
package/inadyn/inadyn.hash
Normal file
5
package/inadyn/inadyn.hash
Normal file
@@ -0,0 +1,5 @@
|
||||
# From https://github.com/troglobit/inadyn/releases/download/v2.5/inadyn-2.5.tar.xz.md5
|
||||
md5 8a864d5186e54d24de2d7554fc01b3ec inadyn-2.5.tar.xz
|
||||
# Locally computed
|
||||
sha256 4a9ad208671f62912428413da0282450b2d2c4da38f3c95c4ac975d048c41fcd inadyn-2.5.tar.xz
|
||||
sha256 ab15fd526bd8dd18a9e77ebc139656bf4d33e97fc7238cd11bf60e2b9b8666c6 COPYING
|
||||
42
package/inadyn/inadyn.mk
Normal file
42
package/inadyn/inadyn.mk
Normal file
@@ -0,0 +1,42 @@
|
||||
################################################################################
|
||||
#
|
||||
# inadyn
|
||||
#
|
||||
################################################################################
|
||||
|
||||
INADYN_VERSION = 2.5
|
||||
INADYN_SITE = https://github.com/troglobit/inadyn/releases/download/v$(INADYN_VERSION)
|
||||
INADYN_SOURCE = inadyn-$(INADYN_VERSION).tar.xz
|
||||
INADYN_LICENSE = GPL-2.0+
|
||||
INADYN_LICENSE_FILES = COPYING
|
||||
INADYN_DEPENDENCIES = host-pkgconf libconfuse libite
|
||||
|
||||
ifeq ($(BR2_PACKAGE_OPENSSL),y)
|
||||
INADYN_CONF_OPTS += --enable-openssl
|
||||
INADYN_DEPENDENCIES += openssl
|
||||
else ifeq ($(BR2_PACKAGE_GNUTLS),y)
|
||||
INADYN_DEPENDENCIES += gnutls
|
||||
else
|
||||
INADYN_CONF_OPTS += --disable-ssl
|
||||
endif
|
||||
|
||||
define INADYN_INSTALL_SAMPLE_CONFIG
|
||||
$(INSTALL) -D -m 0600 package/inadyn/inadyn.conf \
|
||||
$(TARGET_DIR)/etc/inadyn.conf
|
||||
endef
|
||||
INADYN_POST_INSTALL_TARGET_HOOKS += INADYN_INSTALL_SAMPLE_CONFIG
|
||||
|
||||
define INADYN_INSTALL_INIT_SYSV
|
||||
$(INSTALL) -D -m 0755 package/inadyn/S70inadyn \
|
||||
$(TARGET_DIR)/etc/init.d/S70inadyn
|
||||
endef
|
||||
|
||||
define INADYN_INSTALL_INIT_SYSTEMD
|
||||
$(INSTALL) -D -m 644 package/inadyn/inadyn.service \
|
||||
$(TARGET_DIR)/usr/lib/systemd/system/inadyn.service
|
||||
mkdir -p $(TARGET_DIR)/etc/systemd/system/multi-user.target.wants
|
||||
ln -sf ../../../../usr/lib/systemd/system/inadyn.service \
|
||||
$(TARGET_DIR)/etc/systemd/system/multi-user.target.wants/inadyn.service
|
||||
endef
|
||||
|
||||
$(eval $(autotools-package))
|
||||
10
package/inadyn/inadyn.service
Normal file
10
package/inadyn/inadyn.service
Normal file
@@ -0,0 +1,10 @@
|
||||
[Unit]
|
||||
Description=DDNS client
|
||||
After=syslog.target network.target
|
||||
|
||||
[Service]
|
||||
ExecStart=/usr/bin/inadyn
|
||||
Restart=always
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
Reference in New Issue
Block a user