diff options
author | Igor Sysoev <igor@sysoev.ru> | 2007-01-10 19:15:49 +0300 |
---|---|---|
committer | Igor Sysoev <igor@sysoev.ru> | 2007-01-10 19:15:49 +0300 |
commit | feb42254baab0cd0f34c8c914223b297b8b0c9cd (patch) | |
tree | 100494c5a67835bc950726e5265dbe1c819e7900 /auto/lib | |
parent | 673382f2aaf790f3a7bc6bbe88be89be0eb09534 (diff) |
icc and PCRE-6.5+ compatibility
Diffstat (limited to 'auto/lib')
-rw-r--r-- | auto/lib/pcre/conf | 24 |
1 files changed, 21 insertions, 3 deletions
diff --git a/auto/lib/pcre/conf b/auto/lib/pcre/conf index 045e6c855..a1143814d 100644 --- a/auto/lib/pcre/conf +++ b/auto/lib/pcre/conf @@ -25,14 +25,24 @@ if [ $PCRE != NONE ]; then echo $ngx_n "checking for PCRE library ...$ngx_c" - ngx_pcre_ver=`grep PCRE_MAJOR= $PCRE/configure.in \ - | sed -e 's/^.*=\(.*\)$/\1/'` + if [ -e $PCRE/pcre.h ]; then + ngx_pcre_ver=`grep PCRE_MAJOR $PCRE/pcre.h \ + | sed -e 's/^.*PCRE_MAJOR.* \(.*\)$/\1/'` + + else + ngx_pcre_ver=`grep PCRE_MAJOR= $PCRE/configure.in \ + | sed -e 's/^.*=\(.*\)$/\1/'` + fi echo " $ngx_pcre_ver major version found" # to allow -ipo optimization we link with the *.o but not library case "$ngx_pcre_ver" in + 4|5) + CORE_LIBS="$CORE_LIBS $PCRE/pcre.o" + ;; + 6) CORE_LIBS="$CORE_LIBS $PCRE/pcre_chartables.o" CORE_LIBS="$CORE_LIBS $PCRE/pcre_compile.o" @@ -44,8 +54,16 @@ if [ $PCRE != NONE ]; then ;; *) - CORE_LIBS="$CORE_LIBS $PCRE/pcre.o" + CORE_LIBS="$CORE_LIBS $PCRE/pcre_chartables.o" + CORE_LIBS="$CORE_LIBS $PCRE/pcre_compile.o" + CORE_LIBS="$CORE_LIBS $PCRE/pcre_exec.o" + CORE_LIBS="$CORE_LIBS $PCRE/pcre_fullinfo.o" + CORE_LIBS="$CORE_LIBS $PCRE/pcre_globals.o" + CORE_LIBS="$CORE_LIBS $PCRE/pcre_tables.o" + CORE_LIBS="$CORE_LIBS $PCRE/pcre_try_flipped.o" + CORE_LIBS="$CORE_LIBS $PCRE/pcre_newline.o" ;; + esac ;; |