summaryrefslogtreecommitdiff
path: root/databases/postgresql91-server/files
diff options
context:
space:
mode:
Diffstat (limited to 'databases/postgresql91-server/files')
-rw-r--r--databases/postgresql91-server/files/502.pgsql30
-rw-r--r--databases/postgresql91-server/files/extra-patch-icu430
-rw-r--r--databases/postgresql91-server/files/patch-doc-Makefile44
3 files changed, 52 insertions, 52 deletions
diff --git a/databases/postgresql91-server/files/502.pgsql b/databases/postgresql91-server/files/502.pgsql
index d2235e414cd2..281189a59c46 100644
--- a/databases/postgresql91-server/files/502.pgsql
+++ b/databases/postgresql91-server/files/502.pgsql
@@ -15,7 +15,8 @@
# Define these variables in either /etc/periodic.conf or
# /etc/periodic.conf.local to override the default values.
#
-# daily_pgsql_backup_enable="YES" # do backup
+# daily_pgsql_backup_enable="YES" # do backup of all databases
+# daily_pgsql_backup_enable="foo bar db1 db2" # only do backup of a limited selection of databases
# daily_pgsql_vacuum_enable="YES" # do vacuum
daily_pgsql_vacuum_args="-z"
@@ -37,9 +38,7 @@ eval backupdir=${daily_pgsql_backupdir}
rc=0
-case "$daily_pgsql_backup_enable" in
- [Yy][Ee][Ss])
-
+pgsql_backup() {
# daily_pgsql_backupdir must be writeable by user pgsql
# ~pgsql is just that under normal circumstances,
# but this might not be where you want the backups...
@@ -53,16 +52,18 @@ case "$daily_pgsql_backup_enable" in
# Protect the data
umask 077
- dbnames=`su -l pgsql -c "umask 077; psql -q -t -A -d template1 -c SELECT\ datname\ FROM\ pg_database\ WHERE\ datname!=\'template0\'"`
rc=$?
now=`date "+%Y-%m-%dT%H:%M:%S"`
file=${daily_pgsql_backupdir}/pgglobals_${now}
su -l pgsql -c "umask 077; pg_dumpall -g | gzip -9 > ${file}.gz"
- for db in ${dbnames}; do
+
+ db=$1
+ while shift; do
echo -n " $db"
file=${backupdir}/pgdump_${db}_${now}
su -l pgsql -c "umask 077; pg_dump ${daily_pgsql_pgdump_args} -f ${file} ${db}"
[ $? -gt 0 ] && rc=3
+ db=$1
done
if [ $rc -gt 0 ]; then
@@ -73,6 +74,23 @@ case "$daily_pgsql_backup_enable" in
# cleaning up old data
find ${backupdir} \( -name 'pgdump_*' -o -name 'pgglobals_*' \) \
-a -mtime +${daily_pgsql_savedays} -delete
+ echo
+}
+
+case "$daily_pgsql_backup_enable" in
+ [Yy][Ee][Ss])
+ dbnames=`su -l pgsql -c "umask 077; psql -q -t -A -d template1 -c SELECT\ datname\ FROM\ pg_database\ WHERE\ datname!=\'template0\'"`
+ pgsql_backup $dbnames
+ ;;
+
+ [Nn][Oo])
+ ;;
+
+ "")
+ ;;
+
+ *)
+ pgsql_backup $daily_pgsql_backup_enable
;;
esac
diff --git a/databases/postgresql91-server/files/extra-patch-icu4 b/databases/postgresql91-server/files/extra-patch-icu4
deleted file mode 100644
index 28c8a8cfff33..000000000000
--- a/databases/postgresql91-server/files/extra-patch-icu4
+++ /dev/null
@@ -1,30 +0,0 @@
---- configure.in.orig 2010-03-25 22:25:10.655197193 +0100
-+++ configure.in 2010-03-25 22:25:13.611658318 +0100
-@@ -945,15 +945,19 @@
- fi
-
- if test "$with_icu" = yes ; then
-- AC_CHECK_LIB(icui18n, ucol_open_3_8, [], [
-- AC_CHECK_LIB(icui18n, ucol_open_3_6, [], [
-- AC_CHECK_LIB(icui18n, ucol_open_3_4, [], [AC_MSG_ERROR([library 'icui18n' is required for ICU])])
-- ])
-+ AC_CHECK_LIB(icui18n, ucol_open_43, [], [
-+ AC_CHECK_LIB(icui18n, ucol_open_3_8, [], [
-+ AC_CHECK_LIB(icui18n, ucol_open_3_6, [], [
-+ AC_CHECK_LIB(icui18n, ucol_open_3_4, [], [AC_MSG_ERROR([library 'icui18n' is required for ICU])])
-+ ])
-+ ])
- ])
-- AC_CHECK_LIB(icuuc, ucnv_fromUChars_3_8, [], [
-- AC_CHECK_LIB(icuuc, ucnv_fromUChars_3_6, [], [
-- AC_CHECK_LIB(icuuc, ucnv_fromUChars_3_4, [], [AC_MSG_ERROR([library 'icuuc' is required for ICU])])
-- ])
-+ AC_CHECK_LIB(icuuc, ucnv_fromUChars_43, [], [
-+ AC_CHECK_LIB(icuuc, ucnv_fromUChars_3_8, [], [
-+ AC_CHECK_LIB(icuuc, ucnv_fromUChars_3_6, [], [
-+ AC_CHECK_LIB(icuuc, ucnv_fromUChars_3_4, [], [AC_MSG_ERROR([library 'icuuc' is required for ICU])])
-+ ])
-+ ])
- ])
- fi
-
diff --git a/databases/postgresql91-server/files/patch-doc-Makefile b/databases/postgresql91-server/files/patch-doc-Makefile
index 8e08132e175b..a366d4ca2620 100644
--- a/databases/postgresql91-server/files/patch-doc-Makefile
+++ b/databases/postgresql91-server/files/patch-doc-Makefile
@@ -1,16 +1,28 @@
---- doc/Makefile.orig 2009-05-15 15:58:05.000000000 +0200
-+++ doc/Makefile 2009-05-15 15:58:18.000000000 +0200
-@@ -25,9 +25,10 @@
-
- .NOTPARALLEL:
-
--ifneq ($(wildcard $(srcdir)/postgres.tar.gz),)
--found_html = yes
--endif
-+# FreeBSD has a separate port for installing the documentation
-+#ifneq ($(wildcard $(srcdir)/postgres.tar.gz),)
-+#found_html = yes
-+#endif
-
- ifneq ($(wildcard $(srcdir)/man.tar.gz),)
- # SCO OpenServer's man system is sufficiently different to not bother.
+--- doc/src/sgml/Makefile.orig 2010-06-12 23:40:31.000000000 +0200
++++ doc/src/sgml/Makefile 2010-09-19 22:07:11.210759927 +0200
+@@ -15,14 +15,14 @@
+
+ # Make "html" the default target, since that is what most people tend
+ # to want to use.
+-html:
++man:
+
+ subdir = doc/src/sgml
+ top_builddir = ../../..
+ include $(top_builddir)/src/Makefile.global
+
+
+-all: html man
++all: man
+
+ distprep: html distprep-man
+
+@@ -285,7 +285,7 @@
+ ## Install
+ ##
+
+-install: install-html
++##install: install-html
+
+ ifneq ($(PORTNAME), sco)
+ install: install-man