diff options
author | Luboš Luňák <l.lunak@suse.cz> | 2013-04-03 18:01:35 +0200 |
---|---|---|
committer | Luboš Luňák <l.lunak@suse.cz> | 2013-04-04 10:33:20 +0000 |
commit | 68c314fc80b5dd5be26a7207b3459a2be9625240 (patch) | |
tree | 8ca00e82e930ae993cd8c4d829d454b11f80c18f /autogen.sh | |
parent | 864e22e14720dc6456e08cb4a01d99353d9c7402 (diff) |
revert back to usign autogen.sh cmdline arguments if given
This is a partial revert of ca0c54d0fe3812cec64e5c7cc83309d4397f5e0a .
Ignoring cmdline arguments if autogen.* exists is broken for several reasons:
- autogen.sh of every other package passes cmdline arguments to configure
- that's because if I was bothered to give them, I want them used
- there's no reason to prefer autogen.input now, given that autogen.input
cannot be overwritten by autogen.sh, unlike autogen.lastrun , so there's
no accidental loss of the switches
- running autogen.sh --foo followed by autogen.sh --bar actually runs
configure with --foo the second time too, because the first one creates
autogen.lastrun and the second one first complains about the cmdline
args, then complains about autogen.lastrun, and then uses it
Change-Id: I5868610935d0312915be74602b6435eea069f937
Reviewed-on: https://gerrit.libreoffice.org/3190
Reviewed-by: Luboš Luňák <l.lunak@suse.cz>
Tested-by: Luboš Luňák <l.lunak@suse.cz>
Diffstat (limited to 'autogen.sh')
-rwxr-xr-x | autogen.sh | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/autogen.sh b/autogen.sh index f5960e375005..2498c5a3313a 100755 --- a/autogen.sh +++ b/autogen.sh @@ -112,14 +112,14 @@ my @cmdline_args = (); my $input = "autogen.input"; my $lastrun = "autogen.lastrun"; -if (-f $input) { - warn "Ignoring command-line arguments, using $input.\n" if (@ARGV); - warn "Ignoring $lastrun, using $input.\n" if (-f $lastrun); - @cmdline_args = read_args ($input); -} elsif (-f $lastrun) { - warn "Ignoring command-line arguments, using $lastrun.\n" if (@ARGV); - print STDERR "Reading $lastrun. Please rename it to $input to avoid this message.\n"; - @cmdline_args = read_args ($lastrun); +if (!@ARGV) { + if (-f $input) { + warn "Ignoring $lastrun, using $input.\n" if (-f $lastrun); + @cmdline_args = read_args ($input); + } elsif (-f $lastrun) { + print STDERR "Reading $lastrun. Please rename it to $input to avoid this message.\n"; + @cmdline_args = read_args ($lastrun); + } } else { @cmdline_args = @ARGV; } |