diff options
author | Igor Sysoev <igor@sysoev.ru> | 2004-03-29 21:43:58 +0400 |
---|---|---|
committer | Igor Sysoev <igor@sysoev.ru> | 2004-03-29 21:43:58 +0400 |
commit | 11dbe97ca401221313dc233aa2d6f67dfcaef1a7 (patch) | |
tree | fcd53429592c68f6fdf8d3ad4b0c151b9ebd5ff3 /auto | |
parent | 14f02ed0dde2ee19da75cd836daf76505d7f2e9c (diff) |
nginx-0.0.3-2004-03-29-21:43:58 import
Diffstat (limited to 'auto')
-rw-r--r-- | auto/cc | 84 | ||||
-rw-r--r-- | auto/init | 5 | ||||
-rw-r--r-- | auto/lib/make | 6 | ||||
-rw-r--r-- | auto/lib/md5/conf | 10 | ||||
-rw-r--r-- | auto/lib/md5/make | 16 | ||||
-rw-r--r-- | auto/lib/md5/makefile.bcc | 16 | ||||
-rw-r--r-- | auto/lib/md5/makefile.msvc | 6 | ||||
-rw-r--r-- | auto/lib/md5/makefile.owc | 4 | ||||
-rw-r--r-- | auto/lib/pcre/conf | 13 | ||||
-rw-r--r-- | auto/lib/pcre/make | 24 | ||||
-rw-r--r-- | auto/lib/pcre/makefile.bcc | 17 | ||||
-rw-r--r-- | auto/lib/zlib/conf | 10 | ||||
-rw-r--r-- | auto/lib/zlib/make | 16 | ||||
-rw-r--r-- | auto/lib/zlib/makefile.bcc | 8 | ||||
-rw-r--r-- | auto/lib/zlib/makefile.msvc | 4 | ||||
-rw-r--r-- | auto/lib/zlib/makefile.owc | 4 | ||||
-rw-r--r-- | auto/make | 109 | ||||
-rw-r--r-- | auto/sources | 12 |
18 files changed, 211 insertions, 153 deletions
@@ -62,6 +62,9 @@ case $CC in # debug CFLAGS="$CFLAGS -g" + # DragonFly's gcc3 generate DWARF + CFLAGS="$CFLAGS -g -gstabs" + have=HAVE_GCC_VARIADIC_MACROS . auto/have if [ ".$CPP" = "." ]; then @@ -70,10 +73,11 @@ case $CC in LINK="\$(CC)" - OBJEXT=o - COMPILEONLY="-c" + INCOPT="-I " + COMPOPT="-c" OBJOUT="-o " BINOUT="-o " + OBJEXT="o" CC_STRONG="$CC -Wall -Werror" ;; @@ -142,10 +146,11 @@ case $CC in LINK="\$(CC)" - OBJEXT=o - COMPILEONLY="-c" + INCOPT="-I " + COMPOPT="-c" OBJOUT="-o " BINOUT="-o " + OBJEXT="o" CC_STRONG="$CC -w1 -Werror" ;; @@ -170,7 +175,7 @@ case $CC in CFLAGS="$CFLAGS -Gs" case $CPU in - pentiumpro) + pentium) # optimize for Pentium and Athlon CPU_OPT="-G5" ;; @@ -220,13 +225,13 @@ case $CC in BUILDPCH="-Ycngx_config.h" USEPCH="-Yungx_config.h" - OBJEXT=obj - COMPILEONLY="-c" + INCOPT="-I " + COMPOPT="-c" OBJOUT="-Fo" BINOUT="-Fe" - BINEXT=.exe - - CC_STRONG="$CC -W3 -WX" + OBJEXT="obj" + BINEXT=".exe" + #DIRSEP='\\' ;; @@ -296,15 +301,64 @@ case $CC in # link flags CORE_LINK="$CORE_LINK -l=nt" - OBJEXT=obj - COMPILEONLY="-c" + INCOPT="-i=" + COMPOPT="-c" OBJOUT="-fo" BINOUT="-fe=" - BINEXT=.exe + OBJEXT="obj" + BINEXT=".exe" + DIRSEP='\\' - INC_EQ=YES - MAKE_BS=YES MAKE_SL=YES ;; + + bcc32) + # Borland C++ 5.5 + + # optimization + + # maximize speed + CFLAGS="$CFLAGS -O2" + + case $CPU in + pentium) + # optimize for Pentium and Athlon + CPU_OPT="-5" + ;; + + pentiumpro) + # optimize for Pentium Pro, Pentium II and Pentium III + CPU_OPT="-6" + ;; + esac + + CFLAGS="$CFLAGS $CPU_OPT" + + # multithreaded + CFLAGS="$CFLAGS -tWM" + + # stop on warning + CFLAGS="$CFLAGS -w!" + + # disable logo + CFLAGS="$CFLAGS -q" + + # precompiled headers + CORE_DEPS="$CORE_DEPS $OBJS\\ngx_config.csm" + PCH="$OBJS\\ngx_config.csm" + BUILDPCH="-H=$OBJS\\ngx_config.csm" + USEPCH="-Hu -H=$OBJS\\ngx_config.csm" + + LINK="\$(CC)" + + INCOPT="-I" + COMPOPT="-c" + OBJOUT="-o" + BINOUT="-e" + OBJEXT="obj" + BINEXT=".exe" + DIRSEP='\\' + ;; + esac @@ -12,11 +12,10 @@ CC_WARN=$CC PCH=NO USEPCH= +OBJEXT= BINEXT= -INC_EQ=NO -MAKE_BS=NO +DIRSEP='\/' MAKE_SL=NO -MAKE_BL=YES # checking echo's "-n" option and "\c" capabilties diff --git a/auto/lib/make b/auto/lib/make index 3bab86b71..7acae504f 100644 --- a/auto/lib/make +++ b/auto/lib/make @@ -1,12 +1,12 @@ -if [ $PCRE != NO ]; then +if [ $PCRE != NONE -a $PCRE != NO ]; then . auto/lib/pcre/make fi -if [ $MD5 != NO ]; then +if [ $MD5 != NONE -a $MD5 != NO ]; then . auto/lib/md5/make fi -if [ $ZLIB != NO ]; then +if [ $ZLIB != NONE -a $ZLIB != NO ]; then . auto/lib/zlib/make fi diff --git a/auto/lib/md5/conf b/auto/lib/md5/conf index 5c6a417a0..40fd74716 100644 --- a/auto/lib/md5/conf +++ b/auto/lib/md5/conf @@ -10,17 +10,11 @@ if [ $MD5 != NONE ]; then OPENSSL_MD5=NO fi - CORE_INCS="$CORE_INCS -I $MD5" + CORE_INCS="$CORE_INCS $MD5" case "$CC" in - cl) - LINK_DEPS="$LINK_DEPS $MD5/md5.lib" - CORE_LIBS="$CORE_LIBS md5.lib" - CORE_LINK="$CORE_LINK -libpath:$MD5" - ;; - - wcl386) + cl | wcl386 | bcc32) LINK_DEPS="$LINK_DEPS $MD5/md5.lib" CORE_LIBS="$CORE_LIBS $MD5/md5.lib" ;; diff --git a/auto/lib/md5/make b/auto/lib/md5/make index 485bf41eb..2632c9b1f 100644 --- a/auto/lib/md5/make +++ b/auto/lib/md5/make @@ -3,10 +3,17 @@ case "$CC" in cl) makefile=makefile.msvc + opt="CPU_OPT=$CPU_OPT LIBC=$LIBC MD5_ASM=$MD5_ASM" ;; wcl386) makefile=makefile.owc + opt="CPU_OPT=$CPU_OPT" + ;; + + bcc32) + makefile=makefile.bcc + opt="-DCPU_OPT=$CPU_OPT -DMD5_ASM=$MD5_ASM" ;; esac @@ -15,7 +22,8 @@ esac case $PLATFORM in win32) - echo "$MD5/md5.lib:" >> $MAKEFILE + line=`echo $MD5/md5.lib: | sed -e "s/\//$DIRSEP/g"` + echo "$line" >> $MAKEFILE ;; *) @@ -31,11 +39,11 @@ done=NO case $PLATFORM in win32) + md5=`echo $MD5 | sed -e "s/\//$DIRSEP/g"` cp auto/lib/md5/$makefile $MD5 - echo " cd $MD5" >> $MAKEFILE - echo $ngx_n " \$(MAKE) -f $makefile" $ngx_c >> $MAKEFILE - echo " CPU_OPT=$CPU_OPT LIBC=$LIBC MD5_ASM=$MD5_ASM" >> $MAKEFILE + echo " cd $md5" >> $MAKEFILE + echo " \$(MAKE) -f $makefile $opt" >> $MAKEFILE echo " cd ..\\..\\.." >> $MAKEFILE done=YES diff --git a/auto/lib/md5/makefile.bcc b/auto/lib/md5/makefile.bcc new file mode 100644 index 000000000..e3dd8aa22 --- /dev/null +++ b/auto/lib/md5/makefile.bcc @@ -0,0 +1,16 @@ + +CFLAGS = -q -O2 -tWM $(CPU_OPT) -DL_ENDIAN + +!if "$(MD5_ASM)" == "YES" + +md5.lib: + bcc32 -c $(CFLAGS) -DMD5_ASM md5_dgst.c + tlib md5.lib +md5_dgst.obj +asm/m-win32.obj + +!else + +md5.lib: + bcc32 -c $(CFLAGS) md5_dgst.c + tlib md5.lib +md5_dgst.obj + +!endif diff --git a/auto/lib/md5/makefile.msvc b/auto/lib/md5/makefile.msvc index 7ba190d86..c497c39ae 100644 --- a/auto/lib/md5/makefile.msvc +++ b/auto/lib/md5/makefile.msvc @@ -1,16 +1,16 @@ -CFLAGS = -nologo -c -MT -O2 -Ob1 -Oi -Gs $(LIBC) $(CPU_OPT) -D L_ENDIAN +CFLAGS = -nologo -MT -O2 -Ob1 -Oi -Gs $(LIBC) $(CPU_OPT) -D L_ENDIAN !if "$(MD5_ASM)" == "YES" md5.lib: - cl $(CFLAGS) -D MD5_ASM md5_dgst.c + cl -c $(CFLAGS) -D MD5_ASM md5_dgst.c link -lib -out:md5.lib md5_dgst.obj asm/m-win32.obj !else md5.lib: - cl $(CFLAGS) md5_dgst.c + cl -c $(CFLAGS) md5_dgst.c link -lib -out:md5.lib md5_dgst.obj !endif diff --git a/auto/lib/md5/makefile.owc b/auto/lib/md5/makefile.owc index 2cb6b654f..917acba30 100644 --- a/auto/lib/md5/makefile.owc +++ b/auto/lib/md5/makefile.owc @@ -1,6 +1,6 @@ -CFLAGS = -c -zq -bt=nt -bm -ot -op -oi -oe -s $(CPU_OPT) +CFLAGS = -zq -bt=nt -bm -ot -op -oi -oe -s $(CPU_OPT) md5.lib: - wcl386 $(CFLAGS) -dL_ENDIAN md5_dgst.c + wcl386 -c $(CFLAGS) -dL_ENDIAN md5_dgst.c wlib -n md5.lib md5_dgst.obj diff --git a/auto/lib/pcre/conf b/auto/lib/pcre/conf index 972c10682..3f2c7a1f6 100644 --- a/auto/lib/pcre/conf +++ b/auto/lib/pcre/conf @@ -1,21 +1,12 @@ if [ $PCRE != NONE ]; then - CORE_INCS="$CORE_INCS -I $PCRE" + CORE_INCS="$CORE_INCS $PCRE" CORE_DEPS="$CORE_DEPS $REGEX_DEPS" CORE_SRCS="$CORE_SRCS $REGEX_SRCS" case "$CC" in - cl) - have=HAVE_PCRE . auto/have - have=PCRE_STATIC . auto/have - CORE_DEPS="$CORE_DEPS $PCRE/pcre.h" - LINK_DEPS="$LINK_DEPS $PCRE/pcre.lib" - CORE_LIBS="$CORE_LIBS pcre.lib" - CORE_LINK="$CORE_LINK -libpath:$PCRE" - ;; - - wcl386) + cl | wcl386 | bcc32) have=HAVE_PCRE . auto/have have=PCRE_STATIC . auto/have CORE_DEPS="$CORE_DEPS $PCRE/pcre.h" diff --git a/auto/lib/pcre/make b/auto/lib/pcre/make index 1f26f5b83..3a42eaba8 100644 --- a/auto/lib/pcre/make +++ b/auto/lib/pcre/make @@ -3,10 +3,17 @@ case "$CC" in cl) makefile=makefile.msvc + opt="CPU_OPT=$CPU_OPT LIBC=$LIBC" ;; wcl386) makefile=makefile.owc + opt="CPU_OPT=$CPU_OPT" + ;; + + bcc32) + makefile=makefile.bcc + opt="-DCPU_OPT=$CPU_OPT" ;; esac @@ -19,14 +26,21 @@ case $PLATFORM in cp auto/lib/pcre/patch.config.in $PCRE cp auto/lib/pcre/$makefile $PCRE - echo "$PCRE/pcre.h:" >> $MAKEFILE - echo " cd $PCRE" >> $MAKEFILE + pcre=`echo $PCRE | sed -e "s/\//$DIRSEP/g"` + line=`echo $PCRE/pcre.h: | sed -e "s/\//$DIRSEP/g"` + + echo "$line" >> $MAKEFILE + echo " cd $pcre" >> $MAKEFILE echo " \$(MAKE) -f $makefile pcre.h" >> $MAKEFILE echo " cd ..\\..\\.." >> $MAKEFILE echo >> $MAKEFILE - echo "$PCRE/pcre.lib: $PCRE/pcre.h" >> $MAKEFILE - echo " cd $PCRE" >> $MAKEFILE - echo " \$(MAKE) -f $makefile CPU_OPT=$CPU_OPT LIBC=$LIBC">> $MAKEFILE + + line="$PCRE/pcre.lib: $PCRE/pcre.h" + line=`echo $line | sed -e "s/\//$DIRSEP/g"` + + echo "$line" >> $MAKEFILE + echo " cd $pcre" >> $MAKEFILE + echo " \$(MAKE) -f $makefile $opt" >> $MAKEFILE echo " cd ..\\..\\.." >> $MAKEFILE ;; diff --git a/auto/lib/pcre/makefile.bcc b/auto/lib/pcre/makefile.bcc new file mode 100644 index 000000000..5744b90b5 --- /dev/null +++ b/auto/lib/pcre/makefile.bcc @@ -0,0 +1,17 @@ + +CFLAGS = -q -O2 -tWM $(CPU_OPT) +PCREFLAGS = -DPCRE_STATIC -DPOSIX_MALLOC_THRESHOLD=10 + + +pcre.lib: pcre.h + bcc32 -q -edftables dftables.c + + dftables > chartables.c + + bcc32 -c $(CFLAGS) $(PCREFLAGS) maketables.c get.c study.c pcre.c + + tlib pcre.lib +maketables.obj +get.obj +study.obj +pcre.obj + +pcre.h: + patch -o pcre.h pcre.in patch.pcre.in + patch -o config.h config.in patch.config.in diff --git a/auto/lib/zlib/conf b/auto/lib/zlib/conf index c699ca63f..82cc5edc8 100644 --- a/auto/lib/zlib/conf +++ b/auto/lib/zlib/conf @@ -1,16 +1,10 @@ if [ $ZLIB != NONE ]; then - CORE_INCS="$CORE_INCS -I $ZLIB" + CORE_INCS="$CORE_INCS $ZLIB" case "$CC" in - cl) - LINK_DEPS="$LINK_DEPS $ZLIB/zlib.lib" - CORE_LIBS="$CORE_LIBS zlib.lib" - CORE_LINK="$CORE_LINK -libpath:$ZLIB" - ;; - - wcl386) + cl | wcl386 | bcc32) LINK_DEPS="$LINK_DEPS $ZLIB/zlib.lib" CORE_LIBS="$CORE_LIBS $ZLIB/zlib.lib" ;; diff --git a/auto/lib/zlib/make b/auto/lib/zlib/make index 00b08bb1e..c44273065 100644 --- a/auto/lib/zlib/make +++ b/auto/lib/zlib/make @@ -3,10 +3,18 @@ case "$CC" in cl) makefile=makefile.msvc + opt="CPU_OPT=$CPU_OPT LIBC=$LIBC" + ;; wcl386) makefile=makefile.owc + opt="CPU_OPT=$CPU_OPT" + ;; + + bcc32) + makefile=makefile.bcc + opt="-DCPU_OPT=$CPU_OPT" ;; esac @@ -15,7 +23,8 @@ esac case $PLATFORM in win32) - echo "$ZLIB/zlib.lib:" >> $MAKEFILE + line=`echo $ZLIB/zlib.lib: | sed -e "s/\//$DIRSEP/g"` + echo "$line" >> $MAKEFILE ;; *) @@ -31,10 +40,11 @@ done=NO case $PLATFORM in win32) + zlib=`echo $ZLIB | sed -e "s/\//$DIRSEP/g"` cp auto/lib/zlib/$makefile $ZLIB - echo " cd $ZLIB" >> $MAKEFILE - echo " \$(MAKE) -f $makefile CPU_OPT=$CPU_OPT LIBC=$LIBC">> $MAKEFILE + echo " cd $zlib" >> $MAKEFILE + echo " \$(MAKE) -f $makefile $opt" >> $MAKEFILE echo " cd ..\\..\\.." >> $MAKEFILE done=YES diff --git a/auto/lib/zlib/makefile.bcc b/auto/lib/zlib/makefile.bcc new file mode 100644 index 000000000..0ec4de835 --- /dev/null +++ b/auto/lib/zlib/makefile.bcc @@ -0,0 +1,8 @@ + +CFLAGS = -q -O2 -tWM $(CPU_OPT) + +zlib.lib: + bcc32 -c $(CFLAGS) adler32.c crc32.c deflate.c trees.c zutil.c + + tlib zlib.lib +adler32.obj +crc32.obj +deflate.obj \ + +trees.obj +zutil.obj diff --git a/auto/lib/zlib/makefile.msvc b/auto/lib/zlib/makefile.msvc index fe3f4f35d..a9983efdf 100644 --- a/auto/lib/zlib/makefile.msvc +++ b/auto/lib/zlib/makefile.msvc @@ -1,8 +1,8 @@ -CFLAGS = -nologo -c -O2 -Ob1 -Oi -Gs $(LIBC) $(CPU_OPT) +CFLAGS = -nologo -O2 -Ob1 -Oi -Gs $(LIBC) $(CPU_OPT) zlib.lib: - cl $(CFLAGS) adler32.c crc32.c deflate.c trees.c zutil.c + cl -c $(CFLAGS) adler32.c crc32.c deflate.c trees.c zutil.c link -lib -out:zlib.lib adler32.obj crc32.obj deflate.obj \ trees.obj zutil.obj diff --git a/auto/lib/zlib/makefile.owc b/auto/lib/zlib/makefile.owc index e119bb9e3..bc57d20cf 100644 --- a/auto/lib/zlib/makefile.owc +++ b/auto/lib/zlib/makefile.owc @@ -1,6 +1,6 @@ -CFLAGS = -c -zq -bt=nt -ot -op -oi -oe -s -bm $(CPU_OPT) +CFLAGS = -zq -bt=nt -ot -op -oi -oe -s -bm $(CPU_OPT) zlib.lib: - wcl386 $(CFLAGS) adler32.c crc32.c deflate.c trees.c zutil.c + wcl386 -c $(CFLAGS) adler32.c crc32.c deflate.c trees.c zutil.c wlib -n zlib.lib adler32.obj crc32.obj deflate.obj trees.obj zutil.obj @@ -18,14 +18,9 @@ if [ $MAKE_SL = YES ]; then echo >> $MAKEFILE fi -all_inc="$CORE_INCS -I $OBJS $HTTP_INCS" -if [ $INC_EQ = YES ]; then - all_inc=`echo $all_inc | sed -e "s/-I /-i=/g"` -fi - -if [ $MAKE_BS = YES ]; then - all_inc=`echo $all_inc | sed -e "s/\//\\\\\\/g"` -fi +all_inc="$CORE_INCS $OBJS $HTTP_INCS" +all_inc=`echo " $all_inc" | sed -e "s/ \([^ ]\)/ $INCOPT\1/g"` +all_inc=`echo $all_inc | sed -e "s/\//$DIRSEP/g"` echo "ALL_INCS = $all_inc" >> $MAKEFILE echo >> $MAKEFILE @@ -41,9 +36,7 @@ fi for dep in $CORE_DEPS do - if [ $MAKE_BS = YES ]; then - dep=`echo $dep | sed -e "s/\//\\\\\\/g"` - fi + dep=`echo $dep | sed -e "s/\//$DIRSEP/g"` if [ $MAKE_SL = YES ]; then echo $ngx_n " $dep" $ngx_c >> $MAKEFILE @@ -60,14 +53,8 @@ if [ $MAKE_SL = YES ]; then echo >> $MAKEFILE fi -inc="$CORE_INCS -I $OBJS" -if [ $INC_EQ = YES ]; then - inc=`echo $inc | sed -e "s/-I /-i=/g"` -fi - -if [ $MAKE_BS = YES ]; then - inc=`echo $inc | sed -e "s/\//\\\\\\/g"` -fi +inc="$CORE_INCS $OBJS" +inc=`echo " $inc" | sed -e "s/ \([^ ]\)/ $INCOPT\1/g" -e "s/\//$DIRSEP/g"` echo "CORE_INCS = $inc" >> $MAKEFILE echo >> $MAKEFILE @@ -83,9 +70,7 @@ fi for dep in $HTTP_DEPS do - if [ $MAKE_BS = YES ]; then - dep=`echo $dep | sed -e "s/\//\\\\\\/g"` - fi + dep=`echo $dep | sed -e "s/\//$DIRSEP/g"` if [ $MAKE_SL = YES ]; then echo $ngx_n " $dep" $ngx_c >> $MAKEFILE @@ -102,14 +87,8 @@ if [ $MAKE_SL = YES ]; then echo >> $MAKEFILE fi -inc="$HTTP_INCS -I $OBJS" -if [ $INC_EQ = YES ]; then - inc=`echo $inc | sed -e "s/-I /-i=/g"` -fi - -if [ $MAKE_BS = YES ]; then - inc=`echo $inc | sed -e "s/\//\\\\\\/g"` -fi +inc="$HTTP_INCS $OBJS" +inc=`echo " $inc" | sed -e "s/ \([^ ]\)/ $INCOPT\1/g" -e "s/\//$DIRSEP/g"` echo "HTTP_INCS = $inc" >> $MAKEFILE echo >> $MAKEFILE @@ -129,11 +108,7 @@ fi for src in $CORE_SRCS $HTTP_SRCS do obj=`echo $src | sed -e "s/\.c\$/.$OBJEXT/" -e "s/\.S\$/.$OBJEXT/"` - obj="$OBJS/$obj" - - if [ $MAKE_BS = YES ]; then - obj=`echo $obj | sed -e "s/\//\\\\\\/g"` - fi + obj=`echo $OBJS/$obj | sed -e "s/\//$DIRSEP/g"` if [ $MAKE_SL = YES ]; then echo $ngx_n " $obj" $ngx_c >> $MAKEFILE @@ -145,10 +120,7 @@ done for src in $NGX_MODULES_C $LINK_DEPS do obj=`echo $src | sed -e "s/\.c\$/.$OBJEXT/"` - - if [ $MAKE_BS = YES ]; then - obj=`echo $obj | sed -e "s/\//\\\\\\/g"` - fi + obj=`echo $obj | sed -e "s/\//$DIRSEP/g"` if [ $MAKE_SL = YES ]; then echo $ngx_n " $obj" $ngx_c >> $MAKEFILE @@ -173,11 +145,7 @@ fi for src in $CORE_SRCS $HTTP_SRCS do obj=`echo $src | sed -e "s/\.c\$/.$OBJEXT/" -e "s/\.S\$/.$OBJEXT/"` - obj="$OBJS/$obj" - - if [ $MAKE_BS = YES ]; then - obj=`echo $obj | sed -e "s/\//\\\\\\/g"` - fi + obj=`echo $OBJS/$obj | sed -e "s/\//$DIRSEP/g"` if [ $MAKE_SL = YES ]; then echo $ngx_n " $obj" $ngx_c >> $MAKEFILE @@ -189,22 +157,18 @@ done # nginx build ngx_modules.c and libs -obj=`echo $NGX_MODULES_C | sed -e "s/\.c\$/.$OBJEXT/"` -libs=`echo $CORE_LIBS | sed -e "s/\.c\$/.$OBJEXT/"` -src=$NGX_MODULES_C -if [ $MAKE_BS = YES ]; then - obj=`echo $obj | sed -e "s/\//\\\\\\/g"` - src=`echo $src | sed -e "s/\//\\\\\\/g"` - libs=`echo $libs | sed -e "s/\//\\\\\\/g"` -fi +obj=`echo $NGX_MODULES_C | sed -e "s/\.c\$/.$OBJEXT/" -e "s/\//$DIRSEP/g"` +src=`echo $NGX_MODULES_C | sed -e "s/\//$DIRSEP/g"` +libs=`echo $CORE_LIBS | sed -e "s/\.c\$/.$OBJEXT/" -e "s/\//$DIRSEP/g"` +link=`echo $CORE_LINK | sed -e "s/\.c\$/.$OBJEXT/" -e "s/\//$DIRSEP/g"` if [ $MAKE_SL = YES ]; then echo " $obj $libs $CORE_LINK" >> $MAKEFILE echo >> $MAKEFILE else echo " $obj \\" >> $MAKEFILE - echo " $CORE_LIBS \\" >> $MAKEFILE - echo " $CORE_LINK" >> $MAKEFILE + echo " $libs \\" >> $MAKEFILE + echo " $link" >> $MAKEFILE echo >> $MAKEFILE fi @@ -221,13 +185,13 @@ fi if [ $MAKE_SL = YES ]; then echo "$obj: $NGX_MODULES_C $deps" >> $MAKEFILE - echo $ngx_n " \$(CC) $COMPILEONLY $args" $ngx_c >> $MAKEFILE + echo $ngx_n " \$(CC) $COMPOPT $args" $ngx_c >> $MAKEFILE echo " $OBJOUT$obj $src" >> $MAKEFILE echo >> $MAKEFILE else echo "$obj: \\" >> $MAKEFILE echo " $NGX_MODULES_C $deps" >> $MAKEFILE - echo " \$(CC) $COMPILEONLY $args \\" >> $MAKEFILE + echo " \$(CC) $COMPOPT $args \\" >> $MAKEFILE echo " $OBJOUT$obj \\" >> $MAKEFILE echo " $src" >> $MAKEFILE echo >> $MAKEFILE @@ -239,21 +203,17 @@ fi for src in $CORE_SRCS do obj=`echo $src | sed -e "s/\.c\$/.$OBJEXT/" -e "s/\.S\$/.$OBJEXT/"` - obj="$OBJS/$obj" - - if [ $MAKE_BS = YES ]; then - obj=`echo $obj | sed -e "s/\//\\\\\\/g"` - src=`echo $src | sed -e "s/\//\\\\\\/g"` - fi + obj=`echo $OBJS/$obj | sed -e "s/\//$DIRSEP/g"` + src=`echo $src | sed -e "s/\//$DIRSEP/g"` if [ $MAKE_SL = YES ]; then echo "$obj: $src $deps" >> $MAKEFILE - echo " \$(CC) $COMPILEONLY $args $OBJOUT$obj $src" >> $MAKEFILE + echo " \$(CC) $COMPOPT $args $OBJOUT$obj $src" >> $MAKEFILE echo >> $MAKEFILE else echo "$obj: \\" >> $MAKEFILE echo " $src $deps" >> $MAKEFILE - echo " \$(CC) $COMPILEONLY $args \\" >> $MAKEFILE + echo " \$(CC) $COMPOPT $args \\" >> $MAKEFILE echo " $OBJOUT$obj \\" >> $MAKEFILE echo " $src" >> $MAKEFILE echo >> $MAKEFILE @@ -274,21 +234,17 @@ fi for src in $HTTP_SRCS do obj=`echo $src | sed -e "s/\.c\$/.$OBJEXT/"` - obj="$OBJS/$obj" - - if [ $MAKE_BS = YES ]; then - obj=`echo $obj | sed -e "s/\//\\\\\\/g"` - src=`echo $src | sed -e "s/\//\\\\\\/g"` - fi + obj=`echo $OBJS/$obj | sed -e "s/\//$DIRSEP/g"` + src=`echo $src | sed -e "s/\//$DIRSEP/g"` if [ $MAKE_SL = YES ]; then echo "$obj: $src $deps" >> $MAKEFILE - echo " \$(CC) $COMPILEONLY $args $OBJOUT$obj $src" >> $MAKEFILE + echo " \$(CC) $COMPOPT $args $OBJOUT$obj $src" >> $MAKEFILE echo >> $MAKEFILE else echo "$obj: \\" >> $MAKEFILE echo " $src $deps" >> $MAKEFILE - echo " \$(CC) $COMPILEONLY $args \\" >> $MAKEFILE + echo " \$(CC) $COMPOPT $args \\" >> $MAKEFILE echo " $OBJOUT$obj \\" >> $MAKEFILE echo " $src" >> $MAKEFILE echo >> $MAKEFILE @@ -302,13 +258,10 @@ if [ $PCH != NO ]; then echo "#include <ngx_config.h>" > $OBJS/pch.c pch="$PCH: src/core/ngx_config.h $OS_CONFIG $OBJS/ngx_auto_config.h" - src="\$(CC) \$(CFLAGS) $BUILDPCH $COMPILEONLY \$(ALL_INCS)" + pch=`echo $pch | sed -e "s/\//$DIRSEP/g"` + src="\$(CC) \$(CFLAGS) $BUILDPCH $COMPOPT \$(ALL_INCS)" src="$src $OBJOUT$OBJS/pch.obj $OBJS/pch.c" - - if [ $MAKE_BS = YES ]; then - pch=`echo $pch | sed -e "s/\//\\\\\\/g"` - src=`echo $src | sed -e "s/\//\\\\\\/g"` - fi + src=`echo $src | sed -e "s/\//$DIRSEP/g"` echo "$pch" >> $MAKEFILE echo " $src" >> $MAKEFILE diff --git a/auto/sources b/auto/sources index f8e43700d..9aa9da0b5 100644 --- a/auto/sources +++ b/auto/sources @@ -1,7 +1,7 @@ CORE_MODULES="ngx_core_module ngx_errlog_module" -CORE_INCS="-I src/core" +CORE_INCS="src/core" CORE_DEPS="src/core/nginx.h \ src/core/ngx_config.h \ @@ -48,7 +48,7 @@ REGEX_SRCS=src/core/ngx_regex.c EVENT_MODULES="ngx_events_module ngx_event_core_module" -EVENT_INCS="-I src/event -I src/event/modules" +EVENT_INCS="src/event src/event/modules" EVENT_DEPS="src/event/ngx_event.h \ src/event/ngx_event_timer.h \ @@ -93,7 +93,7 @@ AIO_SRCS="src/event/modules/ngx_aio_module.c \ src/os/unix/ngx_aio_write_chain.c" -UNIX_INCS="$CORE_INCS $EVENT_INCS -I src/os/unix" +UNIX_INCS="$CORE_INCS $EVENT_INCS src/os/unix" UNIX_DEPS="$CORE_DEPS $EVENT_DEPS \ src/os/unix/ngx_time.h \ @@ -135,7 +135,7 @@ SOLARIS_SRCS=src/os/unix/ngx_solaris_init.c SOLARIS_SENDFILEV_SRCS=src/os/unix/ngx_solaris_sendfilev_chain.c -WIN32_INCS="$CORE_INCS $EVENT_INCS -I src/os/win32" +WIN32_INCS="$CORE_INCS $EVENT_INCS src/os/win32" WIN32_DEPS="$CORE_DEPS $EVENT_DEPS \ src/os/win32/ngx_win32_config.h \ @@ -182,7 +182,7 @@ HTTP_NOT_MODIFIED_FILTER_MODULE=ngx_http_not_modified_filter_module HTTP_STATIC_MODULE=ngx_http_static_module HTTP_INDEX_MODULE=ngx_http_index_module -HTTP_INCS="-I src/http -I src/http/modules" +HTTP_INCS="src/http src/http/modules" HTTP_DEPS="src/http/ngx_http.h \ src/http/ngx_http_request.h \ @@ -232,7 +232,7 @@ HTTP_SSI_SRCS=src/http/modules/ngx_http_ssi_filter.c HTTP_PROXY_MODULE=ngx_http_proxy_module -HTTP_PROXY_INCS="-I src/http/modules/proxy" +HTTP_PROXY_INCS="src/http/modules/proxy" HTTP_PROXY_DEPS=src/http/modules/proxy/ngx_http_proxy_handler.h HTTP_PROXY_SRCS="src/http/modules/proxy/ngx_http_proxy_handler.c \ src/http/modules/proxy/ngx_http_proxy_upstream.c \ |