[PATCH] scripts/test-installation.pl: Handle NSS crypto libraries [BZ #21940]

Florian Weimer fweimer@redhat.com
Thu Dec 14 15:11:00 GMT 2017


On 10/18/2017 07:06 AM, Rical Jasan wrote:
> diff --git a/scripts/test-installation.pl b/scripts/test-installation.pl
> index 45c666b0a2..fcb7707889 100755
> --- a/scripts/test-installation.pl
> +++ b/scripts/test-installation.pl
> @@ -171,14 +171,20 @@ if ($?) {
>   
>   $ok = 1;
>   %found = ();
> +$librgx = qr/lib(\w+)\.so(?:\.([0-9\.]+))?/;
>   
>   open LDD, "ldd /tmp/test-prg$$ |"
>     or die ("Couldn't execute ldd");
>   while (<LDD>) {
> -  if (/^\s*lib/) {
> +  if (m,^\s*${librgx}\s*=>\s*(?:/[^/]+)*/${librgx},) {
>       ($name, $version1, $version2) =
> -      /^\s*lib(\w*)\.so\.([0-9\.]*)\s*=>.*\.so\.([0-9\.]*)/;
> +      ($1, defined($2) ? $2 : '', defined($4) ? $4 : '');
>       $found{$name} = 1;
> +    if (!exists $versions{$name}) {
> +      print "Unexpected dependency: lib$name\n";
> +      $ok = 0;
> +      next;
> +    }

This looks fine to me.  Could you commit it with a ChangeLog entry?

Thanks,
Florian



More information about the Libc-alpha mailing list