From: Daniel Elstner Date: Mon, 9 Nov 2015 13:27:12 +0000 (+0100) Subject: build: Allow dist-bin from non-git sources X-Git-Tag: sigrok-firmware-fx2lafw-0.1.3~5 X-Git-Url: http://sigrok.org/gitweb/?p=sigrok-firmware-fx2lafw.git;a=commitdiff_plain;h=9a8e9e608edda4dcc6a89a8051a56f302863c938 build: Allow dist-bin from non-git sources Do not require the source directory to be a git checkout when creating the tarball of binary firmware files. --- diff --git a/Makefile.am b/Makefile.am index 733b81c0..4e02f430 100644 --- a/Makefile.am +++ b/Makefile.am @@ -241,10 +241,13 @@ dist-changelog: # Creates a convenience tarball with just the generated *.fw files, so that # the users don't have to build them manually. dist-bin: $(firmware_binaries) + -$(AM_V_at)rm -fr $(distdir_bin) $(AM_V_at)$(MKDIR_P) $(distdir_bin) $(AM_V_at)$(INSTALL_DATA) $(firmware_binaries) $(distdir_bin) $(AM_V_at)$(INSTALL_DATA) $(srcdir)/COPYING $(srcdir)/COPYING.LESSER $(srcdir)/NEWS $(srcdir)/README $(distdir_bin) - $(AM_V_at)git -C '$(top_srcdir)' log > $(distdir_bin)/ChangeLog + $(AM_V_at)if test -d '$(top_srcdir)/.git'; \ + then git -C '$(top_srcdir)' log > $(distdir_bin)/ChangeLog; \ + else $(INSTALL_DATA) $(srcdir)/ChangeLog $(distdir_bin); fi $(AM_V_at)tar -czf $(distdir_bin).tar.gz $(distdir_bin) -$(AM_V_at)rm -fr $(distdir_bin)