]> git.sesse.net Git - vlc/commitdiff
Don't attempt to create ChangeLogs if not in a git-tree.
authorRémi Denis-Courmont <rem@videolan.org>
Mon, 31 Mar 2008 16:40:48 +0000 (19:40 +0300)
committerRémi Denis-Courmont <rem@videolan.org>
Mon, 31 Mar 2008 16:40:48 +0000 (19:40 +0300)
There is no need to copy the files in that case thanks to VPATH.
That assumes you are using a source tarball then - if not, you are
screwed anywhow.

doc/Makefile.am

index 6c1989e3ec6462a5bcc44a1b08379d32dc7acfee..91b53372e90ae391f56e671f899f6db6370a15cd 100644 (file)
@@ -50,11 +50,16 @@ EXTRA_DIST = \
 DISTCLEANFILES = $(CHANGELOGS)
 
 $(CHANGELOGS): Makefile.am
-       y="$$(echo "$@" | sed -e 's,ChangeLog-,,')" ; \
-       git --git-dir=$(top_srcdir)/.git log\
-               --since="$$y-01-01" \
-               --until="$$y-12-31 23:00:00 -0100" \
-               > "$@"
+       if test -d "$(top_srcdir)/.git"; then \
+               y="$$(echo "$@" | sed -e 's,ChangeLog-,,')" ; \
+               git --git-dir="$(top_srcdir)/.git" log \
+                       --since="$$y-01-01" \
+                       --until="$$y-12-31 23:00:00 -0100" \
+                       > "$@" ; \
+       fi
 
 # This one needs to be rebuilt all the time :)
 .PHONY: ChangeLog-2008
+#
+#distclean-hook:
+#      test "$(srcdir)" = "$(builddir)" || rm -f -- $(CHANGELOGS)