summaryrefslogtreecommitdiffstats
path: root/Makefile
diff options
context:
space:
mode:
authorKaz Kylheku <kaz@kylheku.com>2015-08-07 21:42:31 -0700
committerKaz Kylheku <kaz@kylheku.com>2015-08-07 21:42:31 -0700
commite7c7d32277dd4ab3b381f9d5daa03e4b2ded75d1 (patch)
tree44841711ef66261e174c7ffd3748c96e5dac711b /Makefile
parentabca512937091e35608a2a5531aaf73da56f503f (diff)
downloadtxr-e7c7d32277dd4ab3b381f9d5daa03e4b2ded75d1.tar.gz
txr-e7c7d32277dd4ab3b381f9d5daa03e4b2ded75d1.tar.bz2
txr-e7c7d32277dd4ab3b381f9d5daa03e4b2ded75d1.zip
* Makefile (SRCS): When top_srcdir is blank, elide the entire
--work-tree argument to git. On Cygwin, git throws a strange error message when --work-tree is given a blank argument.
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile3
1 files changed, 2 insertions, 1 deletions
diff --git a/Makefile b/Makefile
index 80c22556..b6e98487 100644
--- a/Makefile
+++ b/Makefile
@@ -57,7 +57,8 @@ EXTRA_OBJS-$(add_win_res) += win/txr.res
ifneq ($(have_git),)
SRCS := $(addprefix $(top_srcdir),\
$(filter-out lex.yy.c y.tab.c y.tab.h,\
- $(shell git --work-tree=$(top_srcdir) \
+ $(shell git $(if $(top_srcdir), \
+ --work-tree=$(top_srcdir)) \
--git-dir=$(top_srcdir).git \
ls-files "*.c" "*.h" "*.l" "*.y")))
endif