bug-gnulib
[Top][All Lists]
Advanced

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

Re: [PATCH] git-version-gen: allow empty string as --prefix


From: Sami Kerola
Subject: Re: [PATCH] git-version-gen: allow empty string as --prefix
Date: Sun, 12 Feb 2017 08:47:11 +0000

On 11 February 2017 at 18:01, Bruno Haible <address@hidden> wrote:
> Sami Kerola wrote:
>> There are projects that try use this script, but do not have convention to
>> use 'v' in front of tags.  Earlier one had to change script default not to
>> include 'v'.  After this change the --prefix option can be used as last
>> argument without options
>
> In most cases, long options can be passed to programs in any order. If it's 
> not
> possible, it's surprising.
>
> Why would this be better than to pass an empty argument explicitly?
> I mean, in shell syntax:
>    --prefix ''
>
> The other idea is to allow a --prefix=VALUE syntax; this can accommodate an
> empty value without effort:
>    --prefix=

Hi Bruno and others,

Using --prefix '' works fine when runnign from command line, but I could not
make empty string and AC_INIT to play together without the macro starting
to throw warnings. Here is how that turns out:

$ head -1 configure.ac
AC_INIT([logrotate],[m4_esyscmd([build-aux/git-version-gen --prefix ''
.tarball-version])],

$ ./autogen.sh
configure.ac:1: warning: AC_INIT: not a literal:
m4_esyscmd([build-aux/git-version-gen --prefix '' .tarball-version])
configure.ac:1: warning: AC_INIT: not a literal:
m4_esyscmd([build-aux/git-version-gen --prefix '' .tarball-version])
configure.ac:1: warning: AC_INIT: not a literal:
m4_esyscmd([build-aux/git-version-gen --prefix '' .tarball-version])
configure.ac:1: warning: AC_INIT: not a literal:
m4_esyscmd([build-aux/git-version-gen --prefix '' .tarball-version])
configure.ac:1: warning: AC_INIT: not a literal:
m4_esyscmd([build-aux/git-version-gen --prefix '' .tarball-version])
The logrotate build system is now prepared.  To build here, run:
  ./configure && make

-- 
Sami Kerola
http://www.iki.fi/kerolasa/



reply via email to

[Prev in Thread] Current Thread [Next in Thread]