From 28079d573b56be55ca4bc1764c4b65b2eb7e111e Mon Sep 17 00:00:00 2001 From: "Ralf S. Engelschall" Date: Tue, 15 Jul 2003 10:43:10 +0000 Subject: [PATCH] add PostgreSQL support for PHP --- apache/apache.spec | 16 +++++++++++++++- php/php.spec | 16 +++++++++++++++- 2 files changed, 30 insertions(+), 2 deletions(-) diff --git a/apache/apache.spec b/apache/apache.spec index 59f656a560..eff45d97d8 100644 --- a/apache/apache.spec +++ b/apache/apache.spec @@ -60,7 +60,7 @@ Distribution: OpenPKG [BASE] Group: Web License: ASF Version: %{V_apache} -Release: 20030710 +Release: 20030715 # package options (suexec related) %option with_suexec yes @@ -89,6 +89,7 @@ Release: 20030710 # package options (optional PHP4 specific settings; requires "with_mod_php") %option with_mod_php_calendar no %option with_mod_php_mysql no +%option with_mod_php_pgsql no %option with_mod_php_gd no %option with_mod_php_db no %option with_mod_php_debug no @@ -147,6 +148,10 @@ RPM ERROR: with_mod_php conflicts with with_mod_php3 %undefine with_mod_php_zlib %define with_mod_php_zlib yes %endif +%if "%{with_mod_php_pgsql}" == "yes" +%undefine with_mod_php_openssl +%define with_mod_php_openssl yes +%endif %endif %if "%{with_mod_php3}" == "yes" %if "%{with_mod_ssl}" == "yes" @@ -207,6 +212,10 @@ BuildPreReq: gcc, sed, flex, bison BuildPreReq: mysql PreReq: mysql %endif +%if "%{with_mod_php_pgsql}" == "yes" +BuildPreReq: postgresql, openssl +PreReq: postgresql, openssl +%endif %if "%{with_mod_php_gd}" == "yes" BuildPreReq: gd, jpeg, png PreReq: gd, jpeg, png @@ -498,6 +507,11 @@ AutoReqProv: no %else --without-mysql \ %endif +%if "%{with_mod_php_pgsql}" == "yes" + --with-pgsql=%{l_prefix} \ +%else + --without-pgsql \ +%endif %if "%{with_mod_php_gd}" == "yes" --with-gd=%{l_prefix} \ --with-jpeg-dir=%{l_prefix} \ diff --git a/php/php.spec b/php/php.spec index 596a083ca5..3ecd6fd1b7 100644 --- a/php/php.spec +++ b/php/php.spec @@ -33,11 +33,12 @@ Distribution: OpenPKG [BASE] Group: Language License: PHP Version: 4.3.2 -Release: 20030708 +Release: 20030715 # package options (analog to apache.spec) %option with_calendar no %option with_mysql no +%option with_pgsql no %option with_gd no %option with_db no %option with_debug no @@ -76,6 +77,10 @@ Release: 20030708 %undefine with_zlib %define with_zlib yes %endif +%if "%{with_pgsql}" == "yes" +%undefine with_openssl +%define with_openssl yes +%endif # list of sources Source0: http://www.php.net/distributions/php-%{version}.tar.gz @@ -90,6 +95,10 @@ PreReq: OpenPKG, openpkg >= 20030708 BuildPreReq: mysql PreReq: mysql %endif +%if "%{with_pgsql}" == "yes" +BuildPreReq: postgresql +PreReq: postgresql +%endif %if "%{with_gd}" == "yes" BuildPreReq: gd, jpeg, png PreReq: gd, jpeg, png @@ -220,6 +229,11 @@ AutoReqProv: no %else --without-mysql \ %endif +%if "%{with_pgsql}" == "yes" + --with-pgsql=%{l_prefix} \ +%else + --without-pgsql \ +%endif %if "%{with_gd}" == "yes" --with-gd=%{l_prefix} \ --with-jpeg-dir=%{l_prefix} \