[Spice-devel,3/3] Pass fallback version to git-version-gen

Submitted by Eduardo Lima (Etrunko) on April 29, 2016, 7:32 p.m.

Details

Message ID 1461958341-11359-4-git-send-email-etrunko@redhat.com
State New
Headers show
Series "Fixes to git-version-gen" ( rev: 1 ) in Spice

Not browsing as part of any series.

Commit Message

Eduardo Lima (Etrunko) April 29, 2016, 7:32 p.m.
Signed-off-by: Eduardo Lima (Etrunko) <etrunko@redhat.com>
---
 configure.ac | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Patch hide | download patch | download mbox

diff --git a/configure.ac b/configure.ac
index 18b907a..35f2f06 100644
--- a/configure.ac
+++ b/configure.ac
@@ -15,7 +15,7 @@  m4_define([SPICE_CURRENT], [12])
 m4_define([SPICE_REVISION], [0])
 m4_define([SPICE_AGE], [11])
 
-AC_INIT(spice, [m4_esyscmd(build-aux/git-version-gen .tarball-version)],
+AC_INIT(spice, [m4_esyscmd(build-aux/git-version-gen --fallback 0.13.2 .tarball-version)],
         [spice-devel@lists.freedesktop.org], spice)
 
 major=`echo $PACKAGE_VERSION | cut -d. -f1`

Comments

> 
> Signed-off-by: Eduardo Lima (Etrunko) <etrunko@redhat.com>
> ---
>  configure.ac | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/configure.ac b/configure.ac
> index 18b907a..35f2f06 100644
> --- a/configure.ac
> +++ b/configure.ac
> @@ -15,7 +15,7 @@ m4_define([SPICE_CURRENT], [12])
>  m4_define([SPICE_REVISION], [0])
>  m4_define([SPICE_AGE], [11])
>  
> -AC_INIT(spice, [m4_esyscmd(build-aux/git-version-gen .tarball-version)],
> +AC_INIT(spice, [m4_esyscmd(build-aux/git-version-gen --fallback 0.13.2
> .tarball-version)],
>          [spice-devel@lists.freedesktop.org], spice)
>  
>  major=`echo $PACKAGE_VERSION | cut -d. -f1`

Another way could be using a version + date if git-version-gen fails (so
fallback to something like 0.13.2.YYYYMMYY where YYYY is the year and so on).
I would also prefer that a specific release commit has a fixed version like

AC_INIT(spice, 0.13.2, [spice-devel@lists.freedesktop.org], spice)

But this would require a commit just after the release to add the date again.

Frediano