]> git.sur5r.net Git - kconfig-frontends/commit
libs/parser: support gperf v3.1+
authorYann E. MORIN <yann.morin.1998@free.fr>
Sat, 8 Apr 2017 10:03:04 +0000 (12:03 +0200)
committerYann E. MORIN <yann.morin.1998@free.fr>
Sat, 8 Apr 2017 10:10:48 +0000 (12:10 +0200)
commit095eba4a2c163f67bdc50dca7b75ca8895da6814
tree5c2d09a33bd71016d6261ca24cd535a423ca8c2c
parentaea126a53970788117508307aa1bc9d876a80547
libs/parser: support gperf v3.1+

As Freddie wrote:

    New version of gperf (3.1, released in January 2017) breaks the
    build of kconfig-frontends both for the last package you uploaded
    (3.12.0.0) and for the HEAD from the repository.

    The problem is that gperf 3.1 now uses "size_t" as the length
    argument for the functions, while earlier versions use "unsigned
    int".

As suggested by Freddie, add a configure check to detect the type used
in gperf declarations. Unlike the patch from Freddie, we use as much
autoconf code as possible, rather than canned shell commands. This makes
the code about twice bigger, but it is full autoconf stuff, so
presumably more portable.

Also add a patch to be applied by scripts/ksync.sh, so that the change
persists with future update from upstream (as so we catch it when
upstream fixes it by themselves).

Reported-by: Freddie Chopin <freddie.chopin@gmail.com>
Inspired-by: https://gist.github.com/FreddieChopin/b2ec415ee4eacbd4b92499bbf4e934be
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Makefile.am
configure.ac
libs/parser/hconf.gperf
libs/parser/hconf.gperf.patch [new file with mode: 0644]