From 9ab517d65bbe24869c2c449a52eb17f572d1ac8d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Frings-F=C3=BCrst?= Date: Sun, 18 Nov 2018 13:52:53 +0100 Subject: New upstream version 3.24 --- configure | 20 ++++++++++---------- configure.ac | 2 +- doc/changelog.txt | 7 +++++++ doc/libHX_Documentation.lyx | 2 +- doc/libHX_Documentation.pdf | Bin 507683 -> 507850 bytes include/libHX/list.h | 14 +++++++------- include/libHX/option.h | 6 ++++-- src/opt.c | 28 +++++++++++++--------------- 8 files changed, 43 insertions(+), 36 deletions(-) diff --git a/configure b/configure index ccbfcdb..2e849c1 100755 --- a/configure +++ b/configure @@ -1,6 +1,6 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.69 for libHX 3.23. +# Generated by GNU Autoconf 2.69 for libHX 3.24. # # # Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc. @@ -587,8 +587,8 @@ MAKEFLAGS= # Identity of this package. PACKAGE_NAME='libHX' PACKAGE_TARNAME='libhx' -PACKAGE_VERSION='3.23' -PACKAGE_STRING='libHX 3.23' +PACKAGE_VERSION='3.24' +PACKAGE_STRING='libHX 3.24' PACKAGE_BUGREPORT='' PACKAGE_URL='' @@ -1342,7 +1342,7 @@ if test "$ac_init_help" = "long"; then # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF -\`configure' configures libHX 3.23 to adapt to many kinds of systems. +\`configure' configures libHX 3.24 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1412,7 +1412,7 @@ fi if test -n "$ac_init_help"; then case $ac_init_help in - short | recursive ) echo "Configuration of libHX 3.23:";; + short | recursive ) echo "Configuration of libHX 3.24:";; esac cat <<\_ACEOF @@ -1527,7 +1527,7 @@ fi test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF -libHX configure 3.23 +libHX configure 3.24 generated by GNU Autoconf 2.69 Copyright (C) 2012 Free Software Foundation, Inc. @@ -2253,7 +2253,7 @@ cat >config.log <<_ACEOF This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. -It was created by libHX $as_me 3.23, which was +It was created by libHX $as_me 3.24, which was generated by GNU Autoconf 2.69. Invocation command line was $ $0 $@ @@ -3119,7 +3119,7 @@ fi # Define the identity of the package. PACKAGE='libhx' - VERSION='3.23' + VERSION='3.24' cat >>confdefs.h <<_ACEOF @@ -17720,7 +17720,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" -This file was extended by libHX $as_me 3.23, which was +This file was extended by libHX $as_me 3.24, which was generated by GNU Autoconf 2.69. Invocation command line was CONFIG_FILES = $CONFIG_FILES @@ -17786,7 +17786,7 @@ _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" ac_cs_version="\\ -libHX config.status 3.23 +libHX config.status 3.24 configured by $0, generated by GNU Autoconf 2.69, with options \\"\$ac_cs_config\\" diff --git a/configure.ac b/configure.ac index 04ff937..f03a863 100644 --- a/configure.ac +++ b/configure.ac @@ -1,4 +1,4 @@ -AC_INIT([libHX], [3.23]) +AC_INIT([libHX], [3.24]) AC_CONFIG_AUX_DIR([build-aux]) AC_CONFIG_HEADERS([config.h]) AC_CONFIG_MACRO_DIR([m4]) diff --git a/doc/changelog.txt b/doc/changelog.txt index 6ce5889..9aff713 100644 --- a/doc/changelog.txt +++ b/doc/changelog.txt @@ -1,5 +1,12 @@ +v3.24 (2018-10-17) +================== +Fixes: +- defs: avoid compiler warning when using HX_list_for_each when used in C++ +- opt: synchronize HXOPT_AUTOHELP C behavior to C++ mode + + v3.23 (2018-08-28) ================== Enhancements: diff --git a/doc/libHX_Documentation.lyx b/doc/libHX_Documentation.lyx index afaff61..a28f1c6 100644 --- a/doc/libHX_Documentation.lyx +++ b/doc/libHX_Documentation.lyx @@ -91,7 +91,7 @@ \begin_body \begin_layout Title -libHX 3.23 +libHX 3.24 \begin_inset Newline newline \end_inset diff --git a/doc/libHX_Documentation.pdf b/doc/libHX_Documentation.pdf index 40e8c81..1e9db69 100644 Binary files a/doc/libHX_Documentation.pdf and b/doc/libHX_Documentation.pdf differ diff --git a/include/libHX/list.h b/include/libHX/list.h index 3146c22..f226bec 100644 --- a/include/libHX/list.h +++ b/include/libHX/list.h @@ -63,37 +63,37 @@ static __inline__ bool HXlist_empty(const struct HXlist_head *head) } #define HXlist_for_each(pos, head) \ - for ((pos) = (head)->next; (pos) != static_cast(void *, (head)); \ + for ((pos) = (head)->next; (pos) != static_cast(const void *, (head)); \ (pos) = (pos)->next) #define HXlist_for_each_rev(pos, head) \ - for ((pos) = (head)->prev; (pos) != static_cast(void *, (head)); \ + for ((pos) = (head)->prev; (pos) != static_cast(const void *, (head)); \ (pos) = (pos)->prev) #define HXlist_for_each_safe(pos, n, head) \ for ((pos) = (head)->next, (n) = (pos)->next; \ - (pos) != static_cast(void *, (head)); \ + (pos) != static_cast(const void *, (head)); \ (pos) = (n), (n) = (pos)->next) #define HXlist_for_each_rev_safe(pos, n, head) \ for ((pos) = (head)->prev, (n) = (pos)->prev; \ - (pos) != static_cast(void *, (head)); \ + (pos) != static_cast(const void *, (head)); \ (pos) = (n), (n) = (pos)->prev) #define HXlist_for_each_entry(pos, head, member) \ for ((pos) = HXlist_entry((head)->next, __typeof__(*(pos)), member); \ - &(pos)->member != static_cast(void *, (head)); \ + &(pos)->member != static_cast(const void *, (head)); \ (pos) = HXlist_entry((pos)->member.next, __typeof__(*(pos)), member)) #define HXlist_for_each_entry_rev(pos, head, member) \ for ((pos) = HXlist_entry((head)->prev, __typeof__(*(pos)), member); \ - &(pos)->member != static_cast(void *, (head)); \ + &(pos)->member != static_cast(const void *, (head)); \ (pos) = HXlist_entry((pos)->member.prev, __typeof__(*(pos)), member)) #define HXlist_for_each_entry_safe(pos, n, head, member) \ for ((pos) = HXlist_entry((head)->next, __typeof__(*(pos)), member), \ (n) = HXlist_entry((pos)->member.next, __typeof__(*(pos)), member); \ - &(pos)->member != static_cast(void *, (head)); \ + &(pos)->member != static_cast(const void *, (head)); \ (pos) = (n), (n) = HXlist_entry((n)->member.next, __typeof__(*(n)), \ member)) diff --git a/include/libHX/option.h b/include/libHX/option.h index d60c3f1..82255d3 100644 --- a/include/libHX/option.h +++ b/include/libHX/option.h @@ -254,8 +254,10 @@ extern void HX_shconfig_free(const struct HXoption *); # define HXOPT_TABLEEND {.type = HXTYPE_XSNTMARK} #else # define HXOPT_AUTOHELP \ - {NULL, '?', HXTYPE_XHELP, NULL, NULL, HX_getopt_help_cb, \ - 0, "Show this help message"} + {"help", '?', HXTYPE_XHELP, NULL, NULL, HX_getopt_help_cb, \ + 0, "Show this help message"}, \ + {"usage", 0, HXTYPE_NONE, NULL, NULL, HX_getopt_usage_cb, \ + 0, "Display brief usage message"} # define HXOPT_TABLEEND {NULL, 0, HXTYPE_XSNTMARK} #endif diff --git a/src/opt.c b/src/opt.c index d64e521..8efbf52 100644 --- a/src/opt.c +++ b/src/opt.c @@ -304,22 +304,20 @@ static void opt_to_text(const struct HXoption *opt, char *buf, size_t len, buf[i++] = opt->sh; if (!takes_void(opt->type)) i += snprintf(buf + i, len - i, " %s", htyp); + } else if (opt->sh == '\0') { + if (takes_void(opt->type)) + i += snprintf(buf + i, len - i, + "--%s", opt->ln); + else + i += snprintf(buf + i, len - i, + "--%s=%s", opt->ln, htyp); } else { - if (opt->sh == '\0') { - if (takes_void(opt->type)) - i += snprintf(buf + i, len - i, - "--%s", opt->ln); - else - i += snprintf(buf + i, len - i, - "--%s=%s", opt->ln, htyp); - } else { - if (takes_void(opt->type)) - i += snprintf(buf + i, len - i, "-%c%s--%s", - opt->sh, alt, opt->ln); - else - i += snprintf(buf + i, len - i, "-%c%s--%s%c%s", - opt->sh, alt, opt->ln, equ, htyp); - } + if (takes_void(opt->type)) + i += snprintf(buf + i, len - i, "-%c%s--%s", + opt->sh, alt, opt->ln); + else + i += snprintf(buf + i, len - i, "-%c%s--%s%c%s", + opt->sh, alt, opt->ln, equ, htyp); } if (flags & W_BRACKET) -- cgit v1.2.3 From 17a05a59623b5dc54d7649904581f72a1260a3cf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Frings-F=C3=BCrst?= Date: Sun, 18 Nov 2018 13:53:50 +0100 Subject: New upstream release --- debian/changelog | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/debian/changelog b/debian/changelog index d0da703..205456e 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,9 @@ +libhx (3.24-1) UNRELEASED; urgency=medium + + * New upstream release. + + -- Jörg Frings-Fürst Sun, 18 Nov 2018 13:53:17 +0100 + libhx (3.23-1) unstable; urgency=medium * New upstream release. -- cgit v1.2.3 From 78840c450373b421627af4506508438ed94e9158 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Frings-F=C3=BCrst?= Date: Sun, 18 Nov 2018 14:05:27 +0100 Subject: Testbuild --- debian/files | 1 - 1 file changed, 1 deletion(-) delete mode 100644 debian/files diff --git a/debian/files b/debian/files deleted file mode 100644 index f9c45fc..0000000 --- a/debian/files +++ /dev/null @@ -1 +0,0 @@ -libhx_3.23-1_source.buildinfo libs optional -- cgit v1.2.3 From b123453ef809983c17c1438410a13f799b42e5f9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Frings-F=C3=BCrst?= Date: Fri, 21 Dec 2018 20:04:12 +0100 Subject: d/changelog: change date / time / distribution to release --- debian/changelog | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/debian/changelog b/debian/changelog index 205456e..57e2e10 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,8 +1,8 @@ -libhx (3.24-1) UNRELEASED; urgency=medium +libhx (3.24-1) unstable; urgency=medium * New upstream release. - -- Jörg Frings-Fürst Sun, 18 Nov 2018 13:53:17 +0100 + -- Jörg Frings-Fürst Sun, 18 Nov 2018 14:06:24 +0100 libhx (3.23-1) unstable; urgency=medium -- cgit v1.2.3