diff auto/lib/pcre/make @ 16:74b1868dd3cd NGINX_0_1_8

nginx 0.1.8 *) Bugfix: in the ngx_http_autoindex_module if the long file names were in the listing. *) Feature: the "^~" modifier in the location directive. *) Feature: the proxy_max_temp_file_size directive.
author Igor Sysoev <http://sysoev.ru>
date Sat, 20 Nov 2004 00:00:00 +0300
parents 4b2dafa26fe2
children 6f8b0dc0f8dd
line wrap: on
line diff
--- a/auto/lib/pcre/make
+++ b/auto/lib/pcre/make
@@ -2,21 +2,21 @@
 # Copyright (C) Igor Sysoev
 
 
-case "$CC" in
+case "$NGX_CC_NAME" in
 
-    cl)
-        makefile=makefile.msvc
-        opt="CPU_OPT=$CPU_OPT LIBC=$LIBC"
+    msvc*)
+        ngx_makefile=makefile.msvc
+        ngx_opt="CPU_OPT=$CPU_OPT LIBC=$LIBC"
     ;;
 
-    wcl386)
-        makefile=makefile.owc
-        opt="CPU_OPT=$CPU_OPT"
+    owc*)
+        ngx_makefile=makefile.owc
+        ngx_opt="CPU_OPT=$CPU_OPT"
     ;;
 
-    bcc32)
-        makefile=makefile.bcc
-        opt="-DCPU_OPT=$CPU_OPT"
+    bcc)
+        ngx_makefile=makefile.bcc
+        ngx_opt="-DCPU_OPT=$CPU_OPT"
     ;;
 
 esac
@@ -27,39 +27,45 @@ case $PLATFORM in
     win32)
         cp auto/lib/pcre/patch.pcre.in $PCRE
         cp auto/lib/pcre/patch.config.in $PCRE
-        cp auto/lib/pcre/$makefile $PCRE
+        cp auto/lib/pcre/$ngx_makefile $PCRE
 
-        pcre=`echo $PCRE | sed -e "s/\//$ngx_regex_dirsep/g"`
-        line=`echo $PCRE/pcre.h: | sed -e "s/\//$ngx_regex_dirsep/g"`
+        ngx_pcre=`echo $PCRE | sed -e "s/\//$ngx_regex_dirsep/g"`
+
+        cat << END                                            >> $NGX_MAKEFILE
 
-        echo "$line"                                              >> $MAKEFILE
-        echo "	cd $pcre"                                         >> $MAKEFILE
-        echo "	\$(MAKE) -f $makefile pcre.h"                     >> $MAKEFILE
-        echo "	cd ..\\..\\.."                                    >> $MAKEFILE
-        echo                                                      >> $MAKEFILE
+`echo "$PCRE/pcre.h:	$NGX_MAKEFILE" | sed -e "s/\//$ngx_regex_dirsep/g"`
+	cd $ngx_pcre
+	\$(MAKE) -f $ngx_makefile pcre.h
+	cd ..\\..\\..
+
 
-        line="$PCRE/pcre.lib:	$PCRE/pcre.h"
-        line=`echo $line | sed -e "s/\//$ngx_regex_dirsep/g"`
+`echo "$PCRE/pcre.lib:	$PCRE/pcre.h" | sed -e "s/\//$ngx_regex_dirsep/g"`
+	cd $ngx_pcre
+	\$(MAKE) -f $ngx_makefile $ngx_opt
+	cd ..\\..\\..
 
-        echo "$line"                                              >> $MAKEFILE
-        echo "	cd $pcre"                                         >> $MAKEFILE
-        echo "	\$(MAKE) -f $makefile $opt"                       >> $MAKEFILE
-        echo "	cd ..\\..\\.."                                    >> $MAKEFILE
+END
+
     ;;
 
     *)
-        PCRE_OPT="CFLAGS=\"$PCRE_OPT\""
+        cat << END                                            >> $NGX_MAKEFILE
+
+$PCRE/pcre.h:	$NGX_MAKEFILE
+	cd $PCRE \\
+	&& if [ -f Makefile ]; then \$(MAKE) distclean; fi
 
-        echo "$PCRE/pcre.h:"                                      >> $MAKEFILE
-        echo "	cd $PCRE \\"                                      >> $MAKEFILE
-        echo "	&& CC=\"\$(CC)\" $PCRE_OPT \\"                    >> $MAKEFILE
-        echo "	./configure --disable-shared"                     >> $MAKEFILE
-        echo                                                      >> $MAKEFILE
-        echo "$PCRE/.libs/libpcre.a:	$PCRE/pcre.h"             >> $MAKEFILE
-        echo "	cd $PCRE \\"                                      >> $MAKEFILE
-        echo "	&& \$(MAKE) libpcre.la"                           >> $MAKEFILE
+	cd $PCRE \\
+	&& CC="\$(CC)" CFLAGS="$PCRE_OPT" \\
+	./configure --disable-shared
+
+
+$PCRE/.libs/libpcre.a:	$PCRE/pcre.h
+	cd $PCRE \\
+	&& \$(MAKE) libpcre.la
+
+END
+
     ;;
 
 esac
-
-echo                                                              >> $MAKEFILE