mirror of
https://github.com/openresty/openresty.git
synced 2024-10-13 00:29:41 +00:00
improved Yao Weibin's patch for the --add-module option a bit and also added a test case.
This commit is contained in:
18
util/configure
vendored
18
util/configure
vendored
@ -214,22 +214,8 @@ for my $opt (@ARGV) {
|
||||
|
||||
} elsif ($opt =~ /^--add-module=(.*)/) {
|
||||
|
||||
my $mod_path=$1;
|
||||
my $path;
|
||||
my $new_opt;
|
||||
|
||||
if ($mod_path =~ /^\//) {
|
||||
#absolute path
|
||||
$path = $mod_path;
|
||||
}
|
||||
else{
|
||||
#relative path
|
||||
$path = "$root_dir/$mod_path";
|
||||
}
|
||||
|
||||
$new_opt = "--add-module=$path";
|
||||
|
||||
push @ngx_opts, $new_opt;
|
||||
my $mod_path = File::Spec->rel2abs($1);
|
||||
push @ngx_opts, "--add-module=$mod_path";
|
||||
|
||||
} elsif ($opt =~ /^--\w.*/) {
|
||||
push @ngx_opts, $opt;
|
||||
|
Reference in New Issue
Block a user