summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBernd Kuhls <bernd.kuhls@t-online.de>2018-10-20 21:48:41 (GMT)
committerThomas Petazzoni <thomas.petazzoni@bootlin.com>2018-11-04 10:42:05 (GMT)
commit03d52226e2f02d642bf3d44ca299cc190cb0b253 (patch)
treebb9151f17062b5c87518651be4f3f5f15bbf1432
parent0d03c33f22a845218681d19eadddebfda0ef39f6 (diff)
downloadbuildroot-03d52226e2f02d642bf3d44ca299cc190cb0b253.tar.gz
buildroot-03d52226e2f02d642bf3d44ca299cc190cb0b253.tar.bz2
package/php: add support for PostgreSQL (non-PDO)
Needed for example for phppgadmin. Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de> [Thomas: add missing BR2_USE_WCHAR dependency.] Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
-rw-r--r--package/php/Config.ext13
-rw-r--r--package/php/php.mk6
2 files changed, 19 insertions, 0 deletions
diff --git a/package/php/Config.ext b/package/php/Config.ext
index 808551e..3082462 100644
--- a/package/php/Config.ext
+++ b/package/php/Config.ext
@@ -117,6 +117,19 @@ config BR2_PACKAGE_PHP_EXT_MYSQLI
help
MySQL Improved extension support
+config BR2_PACKAGE_PHP_EXT_PGSQL
+ bool "PostgreSQL"
+ depends on BR2_USE_MMU # postgresql
+ depends on !BR2_STATIC_LIBS
+ depends on BR2_USE_WCHAR # postgresql
+ select BR2_PACKAGE_POSTGRESQL
+ help
+ PostgreSQL support
+
+comment "PostgreSQL extension needs a toolchain w/ dynamic library, wchar"
+ depends on BR2_USE_MMU
+ depends on BR2_STATIC_LIBS || !BR2_USE_WCHAR
+
config BR2_PACKAGE_PHP_EXT_SQLITE
bool "SQLite3"
select BR2_PACKAGE_SQLITE
diff --git a/package/php/php.mk b/package/php/php.mk
index 4365847..bd1835f 100644
--- a/package/php/php.mk
+++ b/package/php/php.mk
@@ -196,6 +196,12 @@ endif
ifeq ($(BR2_PACKAGE_PHP_EXT_MYSQLI),y)
PHP_CONF_OPTS += --with-mysqli
endif
+
+ifeq ($(BR2_PACKAGE_PHP_EXT_PGSQL),y)
+PHP_CONF_OPTS += --with-pgsql=$(STAGING_DIR)/usr
+PHP_DEPENDENCIES += postgresql
+endif
+
ifeq ($(BR2_PACKAGE_PHP_EXT_SQLITE),y)
PHP_CONF_OPTS += --with-sqlite3=$(STAGING_DIR)/usr
PHP_DEPENDENCIES += sqlite