Re: [virt-viewer 2/2] build-sys: Don't substitute buildid when it was not set

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hey,

On Tue, Jun 02, 2015 at 03:24:38PM +0100, Daniel P. Berrange wrote:
> On Tue, Jun 02, 2015 at 04:18:59PM +0200, Christophe Fergeau wrote:
> > Since it defaults to being 0, we'll get a spurious 0 on remote-viewer
> > --version if we AC_DEFINE/AC_SUBST it when the user did not specify it.
> > ---
> >  configure.ac | 8 ++++++--
> >  1 file changed, 6 insertions(+), 2 deletions(-)
> > 
> > diff --git a/configure.ac b/configure.ac
> > index ef13477..2933d89 100644
> > --- a/configure.ac
> > +++ b/configure.ac
> > @@ -233,8 +233,12 @@ fi
> >  AC_ARG_WITH([buildid],
> >      AS_HELP_STRING([--with-buildid=id], [Set additional build version details]),
> >      [buildid="-$with_buildid"], [buildid="0"])
> > -AC_DEFINE_UNQUOTED([BUILDID], "$buildid", [Build version details])
> > -AC_SUBST([BUILDID], "$buildid")
> > +if test "x$buildid" != "x0"; then
> > +    AC_DEFINE_UNQUOTED([BUILDID], "$buildid", [Build version details])
> > +    AC_SUBST([BUILDID], "$buildid")
> > +else
> > +    AC_DEFINE_UNQUOTED([BUILDID], "", [Build version details])
> > +fi
> 
> Again, this impacts the WINDOWS_PRODUCTVERSION variable - we want to
> have the 0

I don't think this commit is going to impact WINDOWS_PRODUCTVERSION as this
does not modifies $buildid, and WINDOWS_PRODUCT_VERSION is defined after
this block as:

major=`echo $PACKAGE_VERSION | cut -d. -f1`
minor=`echo $PACKAGE_VERSION | cut -d. -f2`
WINDOWS_PRODUCTVERSION="$major.$minor.$buildid"
AC_SUBST([WINDOWS_PRODUCTVERSION])

This is going to change BUILDID as it will not always be set, but I
think this is ok:

$ git grep BUILDID
configure.ac:    AC_DEFINE_UNQUOTED([BUILDID], "$buildid", [Build version details])
configure.ac:    AC_SUBST([BUILDID], "$buildid")
configure.ac:    AC_DEFINE_UNQUOTED([BUILDID], "", [Build version details])
data/virt-viewer.wxs.in:           Name="VirtViewer @VERSION@@BUILDID@ ($(var.ArchString))"
data/virt-viewer.wxs.in:        <Directory Id="INSTALLDIR" Name="VirtViewer v@VERSION@@BUILDID@">
src/remote-viewer-main.c:    g_print(_("remote-viewer version %s\n"), VERSION BUILDID);
src/virt-viewer-file.c:    version_cmp = virt_viewer_compare_buildid(min_version, PACKAGE_VERSION BUILDID);
src/virt-viewer-main.c:    g_print(_("%s version %s\n"), PACKAGE, VERSION BUILDID);
src/virt-viewer-window.c:    gtk_about_dialog_set_version(GTK_ABOUT_DIALOG(dialog), VERSION BUILDID);

Christophe

Attachment: pgpHo1k4HsPhT.pgp
Description: PGP signature

_______________________________________________
virt-tools-list mailing list
virt-tools-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/virt-tools-list

[Index of Archives]     [Linux Virtualization]     [KVM Development]     [CentOS Virtualization]     [Netdev]     [Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite Forum]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]     [Video 4 Linux]

  Powered by Linux