capture-libs: Skip libs with unmet dependencies when "if exists" flag is set

If we have the CAPTURE_FLAG_IF_EXISTS option flag, we should not
propagate an error if we are not able to find some dependencies of a
library. Instead we should just skip it.

This fixes an error that some users reported because they had some
leftovers unused libraries in their system and libcapsule reported an
error while trying to capture their (missing) dependencies.

Signed-off-by: Ludovico de Nittis <ludovico.denittis@collabora.com>
6 jobs for master in 8 minutes and 46 seconds (queued for 2 seconds)
Status Job ID Name Coverage
  Test
manual build:arch #68704
allowed to fail manual
passed build:asan #68700

00:03:16

passed build:bionic #68703

00:08:12

passed build:buster #68702

00:07:28

passed build:stretch #68701

00:08:46

passed build:ubsan #68699

00:03:17