]> git.ipfire.org Git - people/ms/libloc.git/commitdiff
perl: Use absolute paths for opening database
authorMichael Tremer <michael.tremer@ipfire.org>
Tue, 1 Oct 2019 12:10:14 +0000 (12:10 +0000)
committerMichael Tremer <michael.tremer@ipfire.org>
Tue, 1 Oct 2019 12:10:14 +0000 (12:10 +0000)
This makes distcheck happy which runs the build in a different
directory from the source directory.

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
Makefile.am
src/perl/t/Location.t

index ef74fdb69ae1a7a72fbf17402c71350f16c8557a..3d003246c30ef0053aed9f1282acbb01c012e621 100644 (file)
@@ -160,7 +160,7 @@ build-perl:
 
 .PHONY: check-perl
 check-perl:
-       cd $(builddir)/src/perl && $(MAKE) test
+       cd $(builddir)/src/perl && $(MAKE) test srcdir=$(abs_srcdir)
 
 .PHONY: install-perl
 install-perl:
index aef15c3f4496e0e49dce0d13047e46236d5eca1d..75cd92f039ada44680e05d9b44bafec0ed3d7a4a 100644 (file)
@@ -9,7 +9,7 @@ use strict;
 use warnings;
 
 # Where to find the test database.
-my $testdb = "../../testdata/test.db";
+my $testdb = "$ENV{'srcdir'}/testdata/test.db";
 
 use Test::More tests => 5;
 BEGIN { use_ok('Location') };