support to add relative path module in configure

This commit is contained in:
Weibin Yao 2011-12-28 16:19:09 +08:00 committed by agentzh (章亦春)
parent 1a91ab941c
commit 35afee967e
1 changed files with 19 additions and 0 deletions

19
util/configure vendored
View File

@ -212,6 +212,25 @@ for my $opt (@ARGV) {
} elsif ($opt eq '--without-http_ssl_module') {
$resty_opts{no_http_ssl} = 1;
} 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;
} elsif ($opt =~ /^--\w.*/) {
push @ngx_opts, $opt;