Re: git: 8e3a5d951eb8 - main - devel/pkgconf: update to 2.0.2

From: Christoph Moench-Tegeder <cmt_at_burggraben.net>
Date: Sat, 02 Sep 2023 16:44:01 UTC
Hi,

## Baptiste Daroussin (bapt@FreeBSD.org):

This patch causes a regression:

> diff --git a/devel/pkgconf/files/patch-modversion-comparison b/devel/pkgconf/files/patch-modversion-comparison
> new file mode 100644
> index 000000000000..a8d4c26e6c0a
> --- /dev/null
> +++ b/devel/pkgconf/files/patch-modversion-comparison
> @@ -0,0 +1,13 @@
> +diff --git cli/main.c cli/main.c
> +index 25ff5ca..d75bbb7 100644
> +--- cli/main.c
> ++++ cli/main.c
> +@@ -306,7 +306,7 @@ apply_modversion(pkgconf_client_t *client, pkgconf_pkg_t *world, void *data, int
> + 			pkgconf_dependency_t *dep = world_iter->data;
> + 			pkgconf_pkg_t *pkg = dep->match;
> + 
> +-			if (strncmp(pkg->id, queue_node->package, strlen(pkg->id)))
> ++			if (strcmp(pkg->id, queue_node->package))
> + 				continue;
> + 
> + 			if (pkg->version != NULL) {

Because:
from source 1.8.1
pkgconf-1.8.1$ ./pkgconf --modversion 'gtk+-2.0 >= 2.0.0'
2.24.33
and from source 2.0.2:
pkgconf-2.0.2$ ./pkgconf --modversion 'gtk+-2.0 >= 2.0.0'
2.24.33
but as installed (with patch):
tmp$ /usr/local/bin/pkgconf --modversion 'gtk+-2.0 >= 2.0.0'
tmp$

That's bad because perl's ExtUtils::PkgConfig (from
devel/p5-ExtUtils-PkgConfig p5-ExtUtils-PkgConfig-1.16) relies on the
old behaviour - and at least x11-toolkits/p5-Gtk2 now fails.

Regards,
Christoph

-- 
Spare Space