bugfix: we removed the existing Makefile even for ./configure --help.

Signed-off-by: Yichun Zhang (agentzh) <agentzh@gmail.com>
This commit is contained in:
spacewander
2017-12-09 23:33:25 +08:00
committed by Yichun Zhang (agentzh)
parent dd46539557
commit 2cc5ba6c91
2 changed files with 12 additions and 11 deletions

9
util/configure vendored
View File

@ -23,10 +23,6 @@ my $OS = $^O;
my $ngx_dir;
if (-f 'Makefile') {
unlink 'Makefile' or die "ERROR: failed to remove existing Makefile: $!\n";
}
for my $opt (@ARGV) {
if ($opt =~ /^--platform=(.*)/) {
$OS = $1;
@ -1368,6 +1364,11 @@ _EOC_
}
sub gen_makefile {
if (-f 'Makefile') {
unlink 'Makefile' or
die "ERROR: failed to remove existing Makefile: $!\n";
}
open my $out, ">Makefile" or
die "Cannot open Makefile for writing: $!\n";