Fix make check fail when srcdir != builddir.
This commit is contained in:
parent
58f52853d5
commit
2cf2e79cb6
|
@ -8,19 +8,19 @@ AM_TESTS_ENVIRONMENT= \
|
|||
EXEEXT=${EXEEXT}; export EXEEXT; \
|
||||
$(NULL)
|
||||
|
||||
BUILT_SOURCES = out.expected
|
||||
BUILT_SOURCES = $(builddir)/out.expected
|
||||
|
||||
SH_LOG_COMPILER = sh
|
||||
TESTS=run-test.sh
|
||||
|
||||
TESTDATA=4x6.pcf 8x16.pcf out.expected fonts.conf.in
|
||||
TESTDATA=4x6.pcf 8x16.pcf fonts.conf.in
|
||||
|
||||
if FREETYPE_PCF_LONG_FAMILY_NAMES
|
||||
$(srcdir)/out.expected: $(srcdir)/out.expected-long-family-names
|
||||
cp $(srcdir)/out.expected-long-family-names $(srcdir)/out.expected
|
||||
$(builddir)/out.expected: $(srcdir)/out.expected-long-family-names Makefile
|
||||
cp $(srcdir)/out.expected-long-family-names $(builddir)/out.expected
|
||||
else
|
||||
$(srcdir)/out.expected: $(srcdir)/out.expected-no-long-family-names
|
||||
cp $(srcdir)/out.expected-no-long-family-names $(srcdir)/out.expected
|
||||
$(builddir)/out.expected: $(srcdir)/out.expected-no-long-family-names Makefile
|
||||
cp $(srcdir)/out.expected-no-long-family-names $(builddir)/out.expected
|
||||
endif
|
||||
|
||||
AM_CPPFLAGS = -I$(top_srcdir) -I$(top_builddir)
|
||||
|
@ -61,8 +61,6 @@ TESTS += test-name-parse
|
|||
|
||||
EXTRA_DIST=run-test.sh $(TESTDATA) out.expected-long-family-names out.expected-no-long-family-names
|
||||
|
||||
CLEANFILES=out fonts.conf
|
||||
|
||||
MAINTAINERCLEANFILES=out.expected
|
||||
CLEANFILES=out fonts.conf out.expected
|
||||
|
||||
-include $(top_srcdir)/git.mk
|
||||
|
|
|
@ -26,6 +26,7 @@ case "$OSTYPE" in
|
|||
esac
|
||||
|
||||
TESTDIR=${srcdir-"$MyPWD"}
|
||||
BUILDTESTDIR=${builddir-"$MyPWD"}
|
||||
|
||||
FONTDIR="$MyPWD"/fonts
|
||||
CACHEDIR="$MyPWD"/cache.dir
|
||||
|
@ -51,7 +52,7 @@ check () {
|
|||
echo "=" >> out
|
||||
$FCLIST - family pixelsize | sort >> out
|
||||
tr -d '\015' <out >out.tmp; mv out.tmp out
|
||||
if cmp out $TESTDIR/$EXPECTED > /dev/null ; then : ; else
|
||||
if cmp out $BUILDTESTDIR/$EXPECTED > /dev/null ; then : ; else
|
||||
echo "*** Test failed: $TEST"
|
||||
echo "*** output is in 'out', expected output in '$EXPECTED'"
|
||||
exit 1
|
||||
|
|
Loading…
Reference in New Issue