]> git.ipfire.org Git - location/libloc.git/commit
Declare make dependencies for Perl binding
authorPetr Písař <ppisar@redhat.com>
Wed, 19 Oct 2022 09:50:23 +0000 (11:50 +0200)
committerMichael Tremer <michael.tremer@ipfire.org>
Thu, 20 Oct 2022 13:00:18 +0000 (13:00 +0000)
commitfa07053fa365d31c090947ef49c37ebfd70e3c97
treecdeec7e6db097e422564e4746fc6c6b2c9e0053c
parenta2427902f972e4e7b2b1724fbbcfbbb332b5c576
Declare make dependencies for Perl binding

Running make in parallel (make -j5) randomly failed with:

/bin/sh ./libtool  --tag=CC   --mode=compile gcc -DHAVE_CONFIG_H -I.  -include ./config.h -DSYSCONFDIR=\""/etc"\" -I./src  -Wall -Wchar-subscripts -Wformat-security -Wmissing-declarations -Wmissing-prototypes -Wnested-externs -Wpointer-arith -Wshadow -Wsign-compare -Wstrict-prototypes -Wtype-limits  -fno-semantic-interposition -ffunction-sections -fdata-sections -DLIBLOC_PRIVATE -fvisibility=hidden -g -O2 -c -o src/libloc_internal_la-database.lo `test -f 'src/database.c' || echo './'`src/database.c
/usr/bin/ld: cannot find -lloc: No such file or directory
collect2: error: ld returned 1 exit status
make[3]: *** [Makefile:482: blib/arch/auto/Location/Location.so] Error 1
make[2]: *** [Makefile:2982: build-perl] Error 2

That's because build-perl did not depend on libloc library.

A similar issue was with running tests and installing files. Moreover,
thess two targets rebuilt Perl binding from scratch.

This patch make the dependencies explicit and turns build-perl into
non-PHONY.

Fixes: #12961
Signed-off-by: Petr Písař <ppisar@redhat.com>
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
Makefile.am