summaryrefslogtreecommitdiffstats
path: root/package/postgresql
diff options
context:
space:
mode:
Diffstat (limited to 'package/postgresql')
-rw-r--r--package/postgresql/0001-Compare-linker-compiler-output-with-their-default-ou.patch56
-rw-r--r--package/postgresql/Config.in7
-rw-r--r--package/postgresql/postgresql.hash4
-rw-r--r--package/postgresql/postgresql.mk7
4 files changed, 70 insertions, 4 deletions
diff --git a/package/postgresql/0001-Compare-linker-compiler-output-with-their-default-ou.patch b/package/postgresql/0001-Compare-linker-compiler-output-with-their-default-ou.patch
new file mode 100644
index 0000000000..3eca82ff74
--- /dev/null
+++ b/package/postgresql/0001-Compare-linker-compiler-output-with-their-default-ou.patch
@@ -0,0 +1,56 @@
+From 58d05b2a57802345f43e628bc0807dbf0116cdcc Mon Sep 17 00:00:00 2001
+From: Max Filippov <jcmvbkbc@gmail.com>
+Date: Fri, 20 Mar 2015 16:37:51 +0300
+Subject: [PATCH] Compare linker/compiler output with their default output
+
+linker and compiler may have noisy output by default, making
+acx_pthread.m4 believe that pthread options that it tries are ignored
+as invalid.
+
+Record default compiler and linker output and see if adding pthread
+option changes that, instead of assuming that linker and compiler are
+silent by default.
+
+Signed-off-by: Max Filippov <jcmvbkbc@gmail.com>
+---
+ config/acx_pthread.m4 | 18 +++++++++++++++++-
+ 1 file changed, 17 insertions(+), 1 deletion(-)
+
+diff --git a/config/acx_pthread.m4 b/config/acx_pthread.m4
+index 581164b..d254612 100644
+--- a/config/acx_pthread.m4
++++ b/config/acx_pthread.m4
+@@ -80,6 +80,22 @@
+ esac
+
+ if test x"$acx_pthread_ok" = xno; then
++
++cat >conftest.$ac_ext <<_ACEOF
++int
++main (int argc, char **argv)
++{
++ (void) argc;
++ (void) argv;
++ return 0;
++}
++_ACEOF
++rm -f conftest.$ac_objext conftest$ac_exeext
++
++# Record the default linker and compiler output
++ld_default_output="`(eval $ac_link 2>&1 1>&5)`"
++cc_default_output="`(eval $ac_compile 2>&1 1>&5)`"
++
+ for flag in $acx_pthread_flags; do
+
+ tryPTHREAD_CFLAGS=""
+@@ -143,7 +159,7 @@
+ _ACEOF
+ rm -f conftest.$ac_objext conftest$ac_exeext
+ # Check both linking and compiling, because they might tolerate different options.
+- if test "`(eval $ac_link 2>&1 1>&5)`" = "" && test "`(eval $ac_compile 2>&1 1>&5)`" = ""; then
++ if test "`(eval $ac_link 2>&1 1>&5)`" = "$ld_default_output" && test "`(eval $ac_compile 2>&1 1>&5)`" = "$cc_default_output"; then
+ # we continue with more flags because Linux needs -lpthread
+ # for libpq builds on PostgreSQL. The test above only
+ # tests for building binaries, not shared libraries.
+--
+1.8.1.4
diff --git a/package/postgresql/Config.in b/package/postgresql/Config.in
index 4c53703568..e9b8f48d4a 100644
--- a/package/postgresql/Config.in
+++ b/package/postgresql/Config.in
@@ -1,6 +1,10 @@
config BR2_PACKAGE_POSTGRESQL
bool "postgresql"
depends on BR2_USE_MMU # fork()
+ # fails to build in a pure static linking scenario, and
+ # postgresql is unlikely to be used in a pure statically
+ # linked environment.
+ depends on !BR2_STATIC_LIBS
help
PostgreSQL is a powerful, open source object-relational
database system.
@@ -13,3 +17,6 @@ config BR2_PACKAGE_POSTGRESQL
archives with pg_dump and pg_restore.
http://www.postgresql.org
+
+comment "postgresql needs a toolchain w/ dynamic library"
+ depends on BR2_STATIC_LIBS
diff --git a/package/postgresql/postgresql.hash b/package/postgresql/postgresql.hash
index ea2be3e537..2f8de30fa5 100644
--- a/package/postgresql/postgresql.hash
+++ b/package/postgresql/postgresql.hash
@@ -1,2 +1,2 @@
-# From https://ftp.postgresql.org/pub/source/v9.4.1/postgresql-9.4.1.tar.bz2.sha256
-sha256 29ddb77c820095b8f52e5455e9c6c6c20cf979b0834ed1986a8857b84888c3a6 postgresql-9.4.1.tar.bz2
+# From https://ftp.postgresql.org/pub/source/v9.4.2/postgresql-9.4.2.tar.bz2.sha256
+sha256 81fda191c165ba1d25d75cd0166ece5abdcb4a7f5eca01b349371e279ebb4d11 postgresql-9.4.2.tar.bz2
diff --git a/package/postgresql/postgresql.mk b/package/postgresql/postgresql.mk
index 85ac0e6da9..d4895a0adc 100644
--- a/package/postgresql/postgresql.mk
+++ b/package/postgresql/postgresql.mk
@@ -4,14 +4,17 @@
#
################################################################################
-POSTGRESQL_VERSION = 9.4.1
+POSTGRESQL_VERSION = 9.4.2
POSTGRESQL_SOURCE = postgresql-$(POSTGRESQL_VERSION).tar.bz2
POSTGRESQL_SITE = http://ftp.postgresql.org/pub/source/v$(POSTGRESQL_VERSION)
POSTGRESQL_LICENSE = PostgreSQL
POSTGRESQL_LICENSE_FILES = COPYRIGHT
POSTGRESQL_INSTALL_STAGING = YES
POSTGRESQL_CONFIG_SCRIPTS = pg_config
-POSTGRESQL_CONF_ENV = ac_cv_type_struct_sockaddr_in6=yes
+POSTGRESQL_CONF_ENV = ac_cv_type_struct_sockaddr_in6=yes \
+ pgac_cv_snprintf_long_long_int_format="%lld" \
+ pgac_cv_snprintf_size_t_support=yes
+POSTGRESQL_AUTORECONF = YES
ifeq ($(BR2_TOOLCHAIN_USES_UCLIBC),y)
# PostgreSQL does not build against uClibc with locales
OpenPOWER on IntegriCloud