From 2101781af92f788f024695b37fc3d1444a9ecd24 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: Wed, 9 Mar 2011 12:11:11 +0800 Subject: [PATCH] added a test case for --prefix. --- t/sanity.t | 57 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 57 insertions(+) diff --git a/t/sanity.t b/t/sanity.t index b91cfba..c7b7551 100644 --- a/t/sanity.t +++ b/t/sanity.t @@ -708,3 +708,60 @@ install: clean: rm -rf build + + +=== TEST 13: --prefix +--- cmd: ./configure --prefix=/opt/blah --dry-run +--- out +cp -r bundle/ build/ +cd build +cd libdrizzle-0.8 +./configure --prefix=/opt/blah/libdrizzle +make +make install DESTDIR=$OPENRESTY_BUILD_DIR/libdrizzle-root +export LIBDRIZZLE_LIB='$OPENRESTY_BUILD_DIR/libdrizzle-root/opt/blah/libdrizzle/lib' +export LIBDRIZZLE_INC='$OPENRESTY_BUILD_DIR/libdrizzle-root/opt/blah/libdrizzle/include' +cd .. +cd lua-5.1.4 +make linux +make install INSTALL_TOP=$OPENRESTY_BUILD_DIR/lua-root/opt/blah/lua +export LUA_LIB='$OPENRESTY_BUILD_DIR/lua-root/opt/blah/lua/lib' +export LUA_INC='$OPENRESTY_BUILD_DIR/lua-root/opt/blah/lua/include' +cd .. +cd nginx-0.8.54 +./configure --prefix=/opt/blah/nginx \ + --with-cc-opt='-O2' \ + --add-module=../echo-nginx-module-0.36rc2 \ + --add-module=../xss-nginx-module-0.03rc2 \ + --add-module=../ngx_devel_kit-0.2.14 \ + --add-module=../set-misc-nginx-module-0.21rc2 \ + --add-module=../form-input-nginx-module-0.07rc4 \ + --add-module=../encrypted-session-nginx-module-0.01 \ + --add-module=../drizzle-nginx-module-0.0.15rc9 \ + --add-module=../ngx_lua-0.1.6rc2 \ + --add-module=../headers-more-nginx-module-0.14 \ + --add-module=../srcache-nginx-module-0.12rc2 \ + --add-module=../array-var-nginx-module-0.02 \ + --add-module=../memc-nginx-module-0.12rc1 \ + --add-module=../upstream-keepalive-nginx-module-0.3 \ + --add-module=../auth-request-nginx-module-0.2 \ + --add-module=../rds-json-nginx-module-0.11rc2 \ + --with-ld-opt='-Wl,-rpath=/opt/blah/libdrizzle/lib' \ + --with-http_ssl_module +cd ../.. +--- makefile +.PHONY: all install + +all: + cd build/libdrizzle-0.8 && $(MAKE) + cd build/lua-5.1.4 && $(MAKE) linux + cd build/nginx-0.8.54 && $(MAKE) + +install: + cd build/libdrizzle-0.8 && $(MAKE) install DESTDIR=$(DESTDIR) + cd build/lua-5.1.4 && $(MAKE) install INSTALL_TOP=$(DESTDIR)/opt/blah/lua + cd build/nginx-0.8.54 && $(MAKE) install DESTDIR=$(DESTDIR) + +clean: + rm -rf build +