From 50e6dd5079e06bf8232a6fbaa9373a5d5930f7b5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?agentzh=20=28=E7=AB=A0=E4=BA=A6=E6=98=A5=29?= Date: Mon, 7 Mar 2011 00:58:23 +0800 Subject: [PATCH] fixed error checking order. --- t/sanity.t | 3 --- util/configure | 16 ++++++++-------- 2 files changed, 8 insertions(+), 11 deletions(-) diff --git a/t/sanity.t b/t/sanity.t index 9434974..ed42e11 100644 --- a/t/sanity.t +++ b/t/sanity.t @@ -187,7 +187,4 @@ cd nginx-0.8.54 --- err --with-http_ssl_module conflicts with --without-http_ssl_module --- out -cp -r bundle/ build/ -cd build -cd nginx-0.8.54 diff --git a/util/configure b/util/configure index 29c1dca..d12d3a4 100755 --- a/util/configure +++ b/util/configure @@ -108,6 +108,14 @@ for my $opt (@ARGV) { } } +my $ngx_prefix = "$prefix/nginx"; + +my $cmd = "./configure --prefix=$ngx_prefix" + . " --with-ld-opt='-Wl,-rpath=$ngx_prefix/lib'" + . build_resty_opts(\%resty_opts) + . (@ngx_opts ? " " . join(" ", @ngx_opts) : ""); + ; + if (-d 'build') { system("rm -rf build"); } @@ -124,14 +132,6 @@ my $ngx_dir = auto_complete "nginx"; cd $ngx_dir; -my $ngx_prefix = "$prefix/nginx"; - -my $cmd = "./configure --prefix=$ngx_prefix" - . " --with-ld-opt='-Wl,-rpath=$ngx_prefix/lib'" - . build_resty_opts(\%resty_opts) - . (@ngx_opts ? " " . join(" ", @ngx_opts) : ""); - ; - if ($dry_run) { print "$cmd\n"; exit 0;