Skip to contentSkip to conversation

libite: new package

PATCH New Ryan Coe 2 participants 6 messages Oct 13, 2016 – Oct 16, 2016

lore
Share & tools
lore

Ryan Coe

author
#0 lore raw

PATCH 1/3 libite: new package

---
 DEVELOPERS                 |  3 +++
 package/Config.in          |  1 +
 package/libite/Config.in   | 15 +++++++++++++++
 package/libite/libite.hash |  2 ++
 package/libite/libite.mk   | 14 ++++++++++++++
 5 files changed, 35 insertions(+)
 create mode 100644 package/libite/Config.in
 create mode 100644 package/libite/libite.hash
 create mode 100644 package/libite/libite.mk
DEVELOPERS +3 -0
index 0ae3150..7a23c78 100644
@@ -1259,6 +1259,9 @@ F:	package/python-pysnmp-apps/
 F:	package/python-pysnmp-mibs/
 F:	package/python-tornado/
 
+N:	Ryan Coe <[email protected]>
+F:	package/libite/
+
 N:	Ryan Wilkins <[email protected]>
 F:	package/biosdevname/
 
package/Config.in +1 -0
index 60184ce..4c3f588 100644
@@ -1310,6 +1310,7 @@ menu "Other"
 	source "package/libgee/Config.in"
 	source "package/libglib2/Config.in"
 	source "package/libical/Config.in"
+	source "package/libite/Config.in"
 	source "package/liblinear/Config.in"
 	source "package/libnspr/Config.in"
 	source "package/libpfm4/Config.in"
package/libite/Config.in new file +15 -0
new file mode 100644
index 0000000..78ac22f
@@ -0,0 +1,15 @@
+config BR2_PACKAGE_LIBITE
+	bool "libite"
+	help
+	  Libite is a lightweight library of frog DNA. It can be used to fill
+	  the gaps in any dinosaur project. It holds useful functions and
+	  macros developed by both Finit and the OpenBSD project. Most notably
+	  the string functions: strlcpy(3), strlcat(3) and the highly useful
+	  *BSD sys/queue.h and sys/tree.h API's.
+
+	  Libite is the frog DNA missing in GNU libc. However, -lite does not
+	  aim to become another GLIB! One noticeable gap in GLIBC is the
+	  missing _SAFE macros in the BSD sys/queue.h API - highly recommended
+	  when traversing lists to delete/free nodes.
+
+	  https://github.com/troglobit/libite
package/libite/libite.hash new file +2 -0
new file mode 100644
index 0000000..67ad009
@@ -0,0 +1,2 @@
+# Locally calculated
+sha256 b27e4af69e9e5b4d00924538d3a41b53752082cc439b9246edec5501aff2f22f libite-v1.8.2.tar.gz
package/libite/libite.mk new file +14 -0
new file mode 100644
index 0000000..ff19aa2
@@ -0,0 +1,14 @@
+################################################################################
+#
+# libite
+#
+################################################################################
+
+LIBITE_VERSION = v1.8.2
+LIBITE_SITE = $(call github,troglobit,libite,$(LIBITE_VERSION))
+LIBITE_LICENSE = MIT X11 ISC BSD
+LIBITE_LICENSE_FILES = LICENSE
+LIBITE_INSTALL_STAGING = YES
+LIBITE_AUTORECONF = YES
+
+$(eval $(autotools-package))
Signature · 1 line
2.9.3
author
#1 lore raw

PATCH 2/3 inadyn: do not install default conf file

---
 package/inadyn/S70inadyn      |  4 ++--
 package/inadyn/inadyn.conf    | 11 -----------
 package/inadyn/inadyn.mk      |  6 ------
 package/inadyn/inadyn.service |  2 +-
 4 files changed, 3 insertions(+), 20 deletions(-)
 delete mode 100644 package/inadyn/inadyn.conf
package/inadyn/S70inadyn +2 -2
index ca7b414..a66c3bd 100644
@@ -5,8 +5,8 @@
 
 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 )
+# check if CONFIG exists, exit silently if it does not
+[ ! -f $CONFIG ] && exit 1
 
 # Allow a few customizations from a config file. Especially inadyn
 # must be explicitly enabled by adding ENABLED="yes" in this file.
package/inadyn/inadyn.conf deleted +0 -11
deleted file mode 100644
index ab8aa36..0000000
@@ -1,11 +0,0 @@
-# Basic configuration file for inadyn
-#
-# /etc/inadyn.conf
-pidfile /var/run/inadyn.pid
-update_period_sec 600 # Check for a new IP every 600 seconds
-username test		# replace 'test' with your username
-password test		# replace 'test' with your password
-dyndns_system default at dyndns.org   # replace w/ your provider
-
-alias test.homeip.net
-# replace 'test.homeip.net' with yourdomainname for actual (non-test) use
package/inadyn/inadyn.mk +0 -6
index 8ceca4c..cf071da 100644
@@ -19,12 +19,6 @@ 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
package/inadyn/inadyn.service +1 -1
index abc0a1e..199ad62 100644
@@ -3,7 +3,7 @@ Description=DDNS client
 After=syslog.target network.target
 
 [Service]
-ExecStart=/usr/bin/inadyn
+ExecStart=test -f /etc/inadyn.conf && /usr/bin/inadyn
 Restart=always
 
 [Install]
Signature · 1 line
2.9.3
#2 lore raw

PATCH 2/3 inadyn: do not install default conf file

Hello,

Quoted 1 line · Ryan Coe

The commit message is empty, and therefore we don't understand why you are removing this default configuration file. Having a default configuration file seems very useful: it clearly shows to the user what needs to be tweaked to configure inadyn.

What is your motivation for removing this? Is it because the 2.0 version has a different configuration file format? Something else?

Please write a more verbose commit log, in any case.

Thanks!

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com
author
#3 lore raw

PATCH 3/3 inadyn: bump to version 2.0

In reply to Ryan Coe
---
 DEVELOPERS                 |  1 +
 package/inadyn/Config.in   |  2 ++
 package/inadyn/inadyn.hash |  4 ++--
 package/inadyn/inadyn.mk   | 14 +++++++++++---
 4 files changed, 16 insertions(+), 5 deletions(-)
DEVELOPERS +1 -0
index 7a23c78..bd85c3b 100644
@@ -1260,6 +1260,7 @@ F:	package/python-pysnmp-mibs/
 F:	package/python-tornado/
 
 N:	Ryan Coe <[email protected]>
+F:	package/inadyn/
 F:	package/libite/
 
 N:	Ryan Wilkins <[email protected]>
package/inadyn/Config.in +2 -0
index 65f6851..55894ae 100644
@@ -1,4 +1,6 @@
 config BR2_PACKAGE_INADYN
+	select BR2_PACKAGE_LIBCONFUSE
+	select BR2_PACKAGE_LIBITE
 	bool "inadyn"
 	depends on BR2_USE_MMU # Uses fork()
 	depends on !BR2_STATIC_LIBS # dlopen()
package/inadyn/inadyn.hash +2 -2
index 940bd16..a4e60c9 100644
@@ -1,2 +1,2 @@
-# From https://github.com/troglobit/inadyn/releases/download/1.99.12/inadyn-1.99.12.tar.xz.md5
-md5	a620c9eab9cd31c8923e7264b08376f3	inadyn-1.99.12.tar.xz
+# Locally computed
+sha256	763c53eb3856decfe8b921cab8a54b428b079a62264fbcf6c89690713d63529a  inadyn-v2.0.tar.gz
package/inadyn/inadyn.mk +11 -3
index cf071da..4885831 100644
@@ -4,11 +4,19 @@
 #
 ################################################################################
 
-INADYN_VERSION = 1.99.12
-INADYN_SITE = https://github.com/troglobit/inadyn/releases/download/$(INADYN_VERSION)
-INADYN_SOURCE = inadyn-$(INADYN_VERSION).tar.xz
+INADYN_VERSION = v2.0
+INADYN_SITE = $(call github,troglobit,inadyn,$(INADYN_VERSION))
 INADYN_LICENSE = GPLv2+
 INADYN_LICENSE_FILES = COPYING
+INADYN_AUTORECONF = YES
+
+# Needed for autoreconf to work properly, see ./autogen.sh
+define INADYN_FIXUP_M4_DIR
+	mkdir $(@D)/m4
+endef
+INADYN_POST_EXTRACT_HOOKS += INADYN_FIXUP_M4_DIR
+
+INADYN_DEPENDENCIES += host-pkgconf libconfuse libite
 
 ifeq ($(BR2_PACKAGE_OPENSSL),y)
 INADYN_CONF_OPTS += --enable-openssl
Signature · 1 line
2.9.3
#4 lore raw

PATCH 3/3 inadyn: bump to version 2.0

Hello,

Quoted 1 line · Ryan Coe

This is almost ready to go, but since I had some comments on PATCH 2/3, I'll give you the few minor comments I had on this patch as well.

DEVELOPERS F: package/python-pysnmp-mibs/ · line 1264

Quoted 10 lines
DEVELOPERS +1 -0
index 7a23c78..bd85c3b 100644
@@ -1260,6 +1260,7 @@ F:	package/python-pysnmp-mibs/
 F:	package/python-tornado/
 
 N:	Ryan Coe <[email protected]>
+F:	package/inadyn/
 F:	package/libite/

The change to the DEVELOPERS file should be part of a separate patch.

package/inadyn/Config.in line 3

Quoted 8 lines
package/inadyn/Config.in +2 -0
index 65f6851..55894ae 100644
@@ -1,4 +1,6 @@
 config BR2_PACKAGE_INADYN
+	select BR2_PACKAGE_LIBCONFUSE
+	select BR2_PACKAGE_LIBITE

Please put the select below the "depends on". As explained in the Buildroot documentation, we try to be consistent across all packages, by using the following order:

	bool
	depends on ...
	depends on ...
	select ...
	select ...
Quoted 6 lines
package/inadyn/Config.in +2 -3
-INADYN_VERSION = 1.99.12
-INADYN_SITE = https://github.com/troglobit/inadyn/releases/download/$(INADYN_VERSION)
-INADYN_SOURCE = inadyn-$(INADYN_VERSION).tar.xz
+INADYN_VERSION = v2.0
+INADYN_SITE = $(call github,troglobit,inadyn,$(INADYN_VERSION))
 INADYN_LICENSE = GPLv2+

package/inadyn/Config.in

Quoted 10 lines
package/inadyn/Config.in +9 -0
 INADYN_LICENSE_FILES = COPYING
+INADYN_AUTORECONF = YES
+
+# Needed for autoreconf to work properly, see ./autogen.sh
+define INADYN_FIXUP_M4_DIR
+	mkdir $(@D)/m4
+endef
+INADYN_POST_EXTRACT_HOOKS += INADYN_FIXUP_M4_DIR
+
+INADYN_DEPENDENCIES += host-pkgconf libconfuse libite

Minor detail, but could you move this DEPENDENCIES line earlier, i.e right after the AUTORECONF = YES line, and use the = sign rather than += ?

I've marked your patches 2/3 and 3/3 as "Changes Requested" in our patch tracking system. So could you send an updated version that takes into account the review comments? Otherwise, we will forget about those patches as they are no longer in our TODO-list of patches to be applied.

Thanks a lot!

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com
#5 lore raw

PATCH 1/3 libite: new package

In reply to Ryan Coe

Hello,

Quoted 11 lines · Ryan Coe
---
 DEVELOPERS                 |  3 +++
 package/Config.in          |  1 +
 package/libite/Config.in   | 15 +++++++++++++++
 package/libite/libite.hash |  2 ++
 package/libite/libite.mk   | 14 ++++++++++++++
 5 files changed, 35 insertions(+)
 create mode 100644 package/libite/Config.in
 create mode 100644 package/libite/libite.hash
 create mode 100644 package/libite/libite.mk

The DEVELOPERS change should have been part of a separate patch. We do this to ease the work of backporting changes in older Buildroot releases (the changes in DEVELOPERS file tend to cause a large number of conflicts).

I also rewrapped the Config.in help text, and adjusted the license information to be more precise.

With those changes: applied. Thanks!

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com