about summary refs log tree commit diff
path: root/local.mk
diff options
context:
space:
mode:
Diffstat (limited to 'local.mk')
-rw-r--r--local.mk3
1 files changed, 2 insertions, 1 deletions
diff --git a/local.mk b/local.mk
index 160057ad2625..2541f3f32290 100644
--- a/local.mk
+++ b/local.mk
@@ -1,5 +1,6 @@
 ifeq ($(MAKECMDGOALS), dist)
-  dist-files += $(shell git ls-files)
+  # Make sure we are in repo root with `--git-dir`
+  dist-files += $(shell git --git-dir=.git ls-files || find * -type f)
 endif
 
 dist-files += configure config.h.in nix.spec