6
6
PREFIX=" php"
7
7
TARDIR=" ` basename \` pwd\` ` "
8
8
RELEASE=${1:- 1}
9
- VERSION=${2:- `echo $TARDIR | sed " s/$PREFIX //g" `}
9
+ VERSION=${2:- `echo $TARDIR | sed " s/$PREFIX - //g" `}
10
10
11
11
if [ " $VERSION " = " " ]
12
12
then cat << "EOH "
@@ -24,23 +24,22 @@ echo -n "Building RPM version $VERSION, release: $RELEASE "
24
24
sleep 1 ; echo -n . ; sleep 1 ; echo -n . ; sleep 1 ; echo -n .
25
25
echo
26
26
27
- TAR=php$VERSION .tar.gz
28
- SPEC=php$VERSION .spec
27
+ TAR=php- $VERSION .tar.gz
28
+ SPEC=php- $VERSION .spec
29
29
30
30
# write out the .spec file
31
31
sed -e " s/PVERSION/$VERSION /g" \
32
32
-e " s/PRELEASE/$RELEASE /g" \
33
33
-e " s/TARDIR/$TARDIR /g" \
34
34
> $SPEC << 'EOF '
35
- Summary: PHP4b1 - a powerful scripting language for HTML
35
+ Summary: PHP 4 - A powerful scripting language
36
36
Name: mod_php4
37
37
Version: PVERSION
38
38
Release: PRELEASE
39
39
Group: Networking/Daemons
40
- Source0: http://www.php.net/distributions/php%{PACKAGE_VERSION}.tar.gz
41
- #Source1: php3-manual.tar.gz
40
+ Source0: http://www.php.net/distributions/php-%{PACKAGE_VERSION}.tar.gz
42
41
Copyright: GPL
43
- BuildRoot: /tmp/php3 -root
42
+ BuildRoot: /tmp/php4 -root
44
43
Requires: webserver
45
44
46
45
%description
@@ -57,59 +56,36 @@ chown -R root.root .
57
56
%build
58
57
# first the standalone (why can't you build both at once?)
59
58
# need to run this under sh or it breaks
60
- cd ext/wddx
61
- ln -s /usr/src/redhat/BUILD/apache_1.3.9/src/lib/expat-lite ./xml
62
- cd ../..
63
59
64
60
sh ./configure --prefix=/usr \
65
- --without-gd \
66
61
--with-config-file-path=/usr/lib \
67
62
--enable-force-cgi-redirect \
68
- --enable-debugger=yes \
69
63
--enable-safe-mode \
70
64
--with-exec-dir=/usr/bin \
71
65
--with-mysql=/usr \
72
66
--with-imap=/usr \
73
67
--with-pdflib=/usr \
74
- --with-system-regex \
75
- --enable-track-vars \
76
- --with-ttf \
77
- --with-zlib \
78
- --with-xml=/usr/src/redhat/BUILD/apache_1.3.9/src/lib/expat-lite \
79
- --with-wddx \
80
-
81
- # ldap don't work
82
- # --with-ldap=/usr \
83
-
84
- # system regex conflicts with apache_ssl for some reason
68
+ --with-zlib=/usr \
69
+ --enable-xml \
70
+ --enable-wddx
85
71
86
72
make
87
73
mv php php.keepme
88
74
89
75
# then the apache module
90
76
rm config.cache
91
77
sh ./configure --prefix=/usr \
92
- --without-gd \
93
78
--with-apxs=/usr/sbin/apxs \
94
79
--enable-versioning \
95
80
--with-config-file-path=/usr/lib \
96
- --enable-debugger=yes \
97
81
--enable-safe-mode \
98
82
--with-exec-dir=/usr/bin \
99
83
--with-mysql=/usr \
100
84
--with-imap=/usr \
101
85
--with-pdflib=/usr \
102
- --with-system-regex \
103
- --enable-track-vars \
104
- --with-ttf \
105
- --with-zlib \
106
- --with-xml=/usr/src/redhat/BUILD/apache_1.3.9/src/lib/expat-lite \
107
- --with-wddx \
108
-
109
- # ldap don't work
110
- # --with-ldap=/usr \
111
-
112
- # system regex conflicts with apache_ssl for some reason
86
+ --with-zlib=/usr \
87
+ --enable-xml \
88
+ --enable-wddx
113
89
114
90
make clean
115
91
make
@@ -127,6 +103,9 @@ install -m 755 php $RPM_BUILD_ROOT/usr/bin
127
103
rm -rf $RPM_BUILD_ROOT
128
104
129
105
%changelog
106
+ * Fri Jun 29 2001 Jani Taskinen <sniper@iki.fi>
107
+ - Removed some useless configure options. Made the tar names correct.
108
+
130
109
* Sun Apr 30 2000 Joey Smith <joey@samaritan.com>
131
110
- Small fix: Description still referred to package as PHP3.
132
111
0 commit comments