Fix tests when using a separate build dir. (#2405)

This commit is contained in:
Doug Nazar 2021-08-18 06:45:02 -04:00 committed by GitHub
parent 9d186c9cd4
commit 97f5417aaa
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 8 additions and 10 deletions

View File

@ -1495,11 +1495,6 @@ AC_SUBST(VIPS_CONFIG)
AC_SUBST(PACKAGES_USED) AC_SUBST(PACKAGES_USED)
AC_SUBST(EXTRA_LIBS_USED) AC_SUBST(EXTRA_LIBS_USED)
# needed by test/variables.sh.in
# :( what's a better way to do this, argh
TOP_SRCDIR=$ac_pwd
AC_SUBST(TOP_SRCDIR)
AC_CONFIG_FILES([ AC_CONFIG_FILES([
vips.pc vips.pc
vips-cpp.pc vips-cpp.pc

View File

@ -3,6 +3,8 @@
#set -x #set -x
set -e set -e
. ../test/variables.sh
# Glib is built without -fno-omit-frame-pointer. We need # Glib is built without -fno-omit-frame-pointer. We need
# to disable the fast unwinder to get full stacktraces. # to disable the fast unwinder to get full stacktraces.
export ASAN_OPTIONS="fast_unwind_on_malloc=0:allocator_may_return_null=1" export ASAN_OPTIONS="fast_unwind_on_malloc=0:allocator_may_return_null=1"
@ -14,7 +16,7 @@ export VIPS_WARNING=0
ret=0 ret=0
for fuzzer in *_fuzzer; do for fuzzer in *_fuzzer; do
for file in common_fuzzer_corpus/*; do for file in $top_srcdir/fuzz/common_fuzzer_corpus/*; do
if ! ./$fuzzer $file; then if ! ./$fuzzer $file; then
echo FAIL $fuzzer $file echo FAIL $fuzzer $file
ret=1 ret=1

View File

@ -1,13 +1,14 @@
top_srcdir=@TOP_SRCDIR@ top_srcdir=@abs_top_srcdir@
top_builddir=@abs_top_builddir@
PYTHON=@PYTHON@ PYTHON=@PYTHON@
# we need a different tmp for each script since make can run tests in parallel # we need a different tmp for each script since make can run tests in parallel
tmp=$top_srcdir/test/tmp-$$ tmp=$top_srcdir/test/tmp-$$
test_images=$top_srcdir/test/test-suite/images test_images=$top_srcdir/test/test-suite/images
image=$test_images/sample.jpg image=$test_images/sample.jpg
mkdir -p $tmp mkdir -p $tmp
vips=$top_srcdir/tools/vips vips=$top_builddir/tools/vips
vipsthumbnail=$top_srcdir/tools/vipsthumbnail vipsthumbnail=$top_builddir/tools/vipsthumbnail
vipsheader=$top_srcdir/tools/vipsheader vipsheader=$top_builddir/tools/vipsheader
# we need bc to use '.' for a decimal separator # we need bc to use '.' for a decimal separator
export LC_NUMERIC=C export LC_NUMERIC=C