@@ -1169,9 +1169,7 @@ PHP_HELP_SEPARATOR([PEAR:])
1169
1169
PHP_CONFIGURE_PART(Configuring PEAR)
1170
1170
1171
1171
dnl If CLI is disabled disable PEAR.
1172
- if test "$PHP_CLI" = "no"; then
1173
- with_pear=no
1174
- fi
1172
+ AS_VAR_IF ( [ PHP_CLI] , [ no] , [ with_pear=no] )
1175
1173
1176
1174
PHP_ARG_WITH([ pear] ,
1177
1175
[ whether to install PEAR] ,
@@ -1180,34 +1178,29 @@ PHP_ARG_WITH([pear],
1180
1178
[ no] ,
1181
1179
[ yes] )
1182
1180
1183
- if test "$PHP_PEAR" != "no"; then
1181
+ AS_VAR_IF ( [ PHP_PEAR] , [ no] ,, [
1182
+ AC_MSG_WARN ( [ The --with-pear option is deprecated] )
1184
1183
1185
1184
dnl PEAR dependencies.
1186
- if test "$ PHP_XML" = "no"; then
1187
- pear_error_msg="$pear_error_msg
1188
- PEAR requires XML to be enabled. Add --enable-xml to the configure line. (or --without-pear)"
1189
- fi
1185
+ AS_VAR_IF ( [ PHP_XML] , [ no ] , [ AC_MSG_ERROR ( [ m4_normalize ( [
1186
+ PEAR requires XML to be enabled. Add '--enable-xml' to the configure line,
1187
+ or disable PEAR ( --without-pear).
1188
+ ] ) ] ) ] )
1190
1189
1191
- if test "$pear_error_msg"; then
1192
- AC_MSG_ERROR ( [ $pear_error_msg] )
1193
- fi
1194
-
1195
- AC_MSG_WARN ( [ The --with-pear option is deprecated] )
1190
+ install_pear=install-pear
1196
1191
1197
- install_pear="install-pear"
1198
- PEAR_INSTALLDIR=$PHP_PEAR
1199
-
1200
- if test "$PHP_PEAR" = "yes"; then
1201
- case $PHP_LAYOUT in
1202
- GNU) PEAR_INSTALLDIR=$datadir/pear;;
1203
- *) PEAR_INSTALLDIR=$libdir/php;;
1204
- esac
1205
- fi
1192
+ AS_VAR_IF ( [ PHP_PEAR] , [ yes] ,
1193
+ [ AS_CASE ( [ $PHP_LAYOUT] ,
1194
+ [ GNU] , [ PEAR_INSTALLDIR=$datadir/pear] ,
1195
+ [ PEAR_INSTALLDIR=$libdir/php] ) ] ,
1196
+ [ PEAR_INSTALLDIR=$PHP_PEAR] )
1206
1197
1207
1198
PHP_SUBST([ PEAR_INSTALLDIR] )
1208
1199
PHP_ADD_BUILD_DIR([ pear] )
1209
- PHP_ADD_MAKEFILE_FRAGMENT($abs_srcdir/pear/Makefile.frag,$abs_srcdir/pear,pear)
1210
- fi
1200
+ PHP_ADD_MAKEFILE_FRAGMENT([ $abs_srcdir/pear/Makefile.frag] ,
1201
+ [ $abs_srcdir/pear] ,
1202
+ [ pear] )
1203
+ ] )
1211
1204
1212
1205
dnl Configuring Zend and TSRM.
1213
1206
dnl ----------------------------------------------------------------------------
0 commit comments