blob: 5822762484657b8501a4963463601e808e81deae (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
|
# Copyright (C) Igor Sysoev
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
case $PLATFORM in
win32)
line=`echo $ZLIB/zlib.lib: | sed -e "s/\//$ngx_regex_dirsep/g"`
echo "$line" >> $MAKEFILE
;;
*)
echo "$ZLIB/libz.a:" >> $MAKEFILE
;;
esac
done=NO
case $PLATFORM in
win32)
zlib=`echo $ZLIB | sed -e "s/\//$ngx_regex_dirsep/g"`
cp auto/lib/zlib/$makefile $ZLIB
echo " cd $zlib" >> $MAKEFILE
echo " \$(MAKE) -f $makefile $opt" >> $MAKEFILE
echo " cd ..\\..\\.." >> $MAKEFILE
done=YES
;;
# FreeBSD: i386
# Linux: i686
*:i386 | *:i686)
case $ZLIB_ASM in
pentium)
echo " cd $ZLIB \\" >> $MAKEFILE
echo " && cp contrib/asm586/match.S . \\" >> $MAKEFILE
echo " && CFLAGS=\"$ZLIB_OPT -DASMV\" \\" >> $MAKEFILE
echo " CC=\"\$(CC)\" \\" >> $MAKEFILE
echo " ./configure \\" >> $MAKEFILE
echo " && \$(MAKE) OBJA=match.o libz.a" >> $MAKEFILE
done=YES
;;
pentiumpro)
echo " cd $ZLIB \\" >> $MAKEFILE
echo " && cp contrib/asm686/match.S . \\" >> $MAKEFILE
echo " && CFLAGS=\"$ZLIB_OPT -DASMV\" \\" >> $MAKEFILE
echo " CC=\"\$(CC)\" \\" >> $MAKEFILE
echo " ./configure \\" >> $MAKEFILE
echo " && \$(MAKE) OBJA=match.o libz.a" >> $MAKEFILE
done=YES
;;
NO)
;;
*)
echo "$0: error: invalid --with-zlib-asm=$ZLIB_ASM option."
echo "The valid values are \"pentium\" and \"pentiumpro\" only".
echo
exit 1;
;;
esac
;;
esac
if [ $done = NO ]; then
echo " cd $ZLIB \\" >> $MAKEFILE
echo " && CFLAGS=\"$ZLIB_OPT\" CC=\"\$(CC)\" \\" >> $MAKEFILE
echo " ./configure \\" >> $MAKEFILE
echo " && \$(MAKE) libz.a" >> $MAKEFILE
fi
echo >> $MAKEFILE
|