# HG changeset patch # User Yoshiki Yazawa # Date 1256370593 -32400 # Node ID 57bb2c26198d9ae692e9fec08851164e883f39e3 # Parent c701bbc532b459f1753b7ac012288430ecaa171e fix a problem that compilation fails if hg is not installed. diff -r c701bbc532b4 -r 57bb2c26198d recpt1/Makefile --- a/recpt1/Makefile Thu Oct 22 02:26:03 2009 +0900 +++ b/recpt1/Makefile Sat Oct 24 16:49:53 2009 +0900 @@ -26,9 +26,9 @@ $(CC) -MM $(OBJS:.o=.c) $(CPPFLAGS) > $@ version.h: - if test -d ../.hg ; then \ - revh=`hg parents --template 'const char *version = "r#rev#:#node|short# (#date|isodate#)";\n' 2>/dev/null`; \ - [ -z "$$revh" ] || echo "$$revh" > $@; \ + revh=`hg parents --template 'const char *version = "r#rev#:#node|short# (#date|isodate#)";\n' 2>/dev/null`; \ + if [ -n "$$revh" ] ; then \ + echo "$$revh" > $@; \ else \ echo "const char *version = \"$(RELEASE_VERSION)\";" > $@; \ fi