Merge of r4474, r4493: configure/build fixes.

*) Fixed build with embedded perl and --with-openssl.

*) Configure: moved icc detection before gcc.  New versions of icc
   confuse auto/cc/name due to introduced handling of a "icc -v".
This commit is contained in:
Maxim Dounin 2012-03-05 12:58:10 +00:00
parent be909c35b0
commit 01f5961540
3 changed files with 11 additions and 6 deletions

View File

@ -63,16 +63,16 @@ if [ "$CC" = bcc32 ]; then
NGX_CC_NAME=bcc
echo " + using Borland C++ compiler"
else
if `$CC -v 2>&1 | grep 'gcc version' >/dev/null 2>&1`; then
NGX_CC_NAME=gcc
echo " + using GNU C compiler"
else
if `$CC -V 2>&1 | grep '^Intel(R) C' >/dev/null 2>&1`; then
NGX_CC_NAME=icc
echo " + using Intel C++ compiler"
else
if `$CC -v 2>&1 | grep 'gcc version' >/dev/null 2>&1`; then
NGX_CC_NAME=gcc
echo " + using GNU C compiler"
else
if `$CC -V 2>&1 | grep 'Sun C' >/dev/null 2>&1`; then
NGX_CC_NAME=sunc

View File

@ -28,6 +28,7 @@ $NGX_OBJS/src/http/modules/perl/Makefile: \
&& NGX_PM_CFLAGS="\$(NGX_PM_CFLAGS) -g $NGX_CC_OPT" \
NGX_PCRE=$PCRE \
NGX_OBJS=$NGX_OBJS \
NGX_OPENSSL=$OPENSSL \
$NGX_PERL Makefile.PL \
LIB=$NGX_PERL_MODULES \
INSTALLSITEMAN3DIR=$NGX_PERL_MODULES_MAN

View File

@ -25,7 +25,11 @@ WriteMakefile(
"-I ../../../../../$ENV{NGX_OBJS} " .
($ENV{NGX_PCRE} =~ /^(YES|NO)/ ? "" :
($ENV{NGX_PCRE} =~ m#^/# ? "-I $ENV{NGX_PCRE} " :
"-I ../../../../../$ENV{NGX_PCRE} ")),
"-I ../../../../../$ENV{NGX_PCRE} ")) .
($ENV{NGX_OPENSSL} =~ /^(YES|NO)/ ? "" :
($ENV{NGX_OPENSSL} =~ m#^/# ?
"-I $ENV{NGX_OPENSSL}/.openssl/include " :
"-I ../../../../../$ENV{NGX_OPENSSL}/.openssl/include ")),
depend => {
'nginx.c' =>