Skip to content

Commit 93b5393

Browse files
peffgitster
authored andcommitted
Makefile: make perf tests optional for profile build
The perf tests need a repository to operate on; if none is defined, we fall back to the repository containing our build directory. That fails, though, for an exported tarball of git.git, which has no repository. Since 5d7fd6d we run the perf tests as part of "make profile". Therefore "make profile" fails out of the box on released tarballs of v2.1.0. We can fix this by making the perf tests optional; if they are skipped, we still run the regular test suite, which should give a lot of profile data (and is what we used to do prior to 5d7fd6d anyway). Signed-off-by: Jeff King <[email protected]> Acked-by: Andi Kleen <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 066dd26 commit 93b5393

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

Makefile

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1649,7 +1649,11 @@ endif
16491649
profile:: profile-clean
16501650
$(MAKE) PROFILE=GEN all
16511651
$(MAKE) PROFILE=GEN -j1 test
1652-
$(MAKE) PROFILE=GEN -j1 perf
1652+
@if test -n "$$GIT_PERF_REPO" || test -d .git; then \
1653+
$(MAKE) PROFILE=GEN -j1 perf; \
1654+
else \
1655+
echo "Skipping profile of perf tests..."; \
1656+
fi
16531657
$(MAKE) PROFILE=USE all
16541658

16551659
profile-fast: profile-clean

0 commit comments

Comments
 (0)