FreeBSD Bugzilla – Attachment 120037 Details for
Bug 162776
[patch] databases/postgresql90-server: add profile support for multiple databases
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
patch.txt
patch.txt (text/plain; charset=us-ascii), 12.13 KB, created by
Jason
on 2011-11-23 17:34:13 UTC
(
hide
)
Description:
patch.txt
Filename:
MIME Type:
Creator:
Jason
Created:
2011-11-23 17:34:13 UTC
Size:
12.13 KB
patch
obsolete
>Index: postgresql82-server/Makefile >=================================================================== >RCS file: /home/jhelfman/ncvs/ports/databases/postgresql82-server/Makefile,v >retrieving revision 1.205 >diff -u -r1.205 Makefile >--- postgresql82-server/Makefile 21 Oct 2011 20:36:55 -0000 1.205 >+++ postgresql82-server/Makefile 23 Nov 2011 05:14:06 -0000 >@@ -7,7 +7,7 @@ > > PORTNAME?= postgresql > DISTVERSION?= 8.2.22 >-PORTREVISION?= 2 >+PORTREVISION?= 3 > CATEGORIES?= databases > MASTER_SITES= ${MASTER_SITE_PGSQL} > MASTER_SITE_SUBDIR= source/v${DISTVERSION} >Index: postgresql82-server/files/postgresql.in >=================================================================== >RCS file: /home/jhelfman/ncvs/ports/databases/postgresql82-server/files/postgresql.in,v >retrieving revision 1.4 >diff -u -r1.4 postgresql.in >--- postgresql82-server/files/postgresql.in 27 Mar 2010 00:12:50 -0000 1.4 >+++ postgresql82-server/files/postgresql.in 23 Nov 2011 05:13:51 -0000 >@@ -14,6 +14,7 @@ > # postgresql_flags="-w -s -m fast" > # postgresql_initdb_flags="--encoding=utf-8 --lc-collate=C" > # postgresql_class="default" >+# postgresql_profiles="" > # > # See %%PREFIX%%/share/doc/postgresql/README-server for more info > # >@@ -39,7 +40,6 @@ > > name=postgresql > rcvar=`set_rcvar` >-command_args="-D ${postgresql_data} ${postgresql_flags}" > extra_commands="reload initdb" > > start_cmd="postgresql_command start" >@@ -50,6 +50,57 @@ > > initdb_cmd="postgresql_initdb" > >+if [ -n "$2" ]; then >+ profile="$2" >+ if [ "x${postgresql_profiles}" != "x" ]; then >+ eval postgresql_data="\${postgresql_${profile}_data:-}" >+ if [ "x${postgresql_data}" = "x" ]; then >+ echo "You must define a data directory (postgresql_${profile}_data)" >+ exit 1 >+ fi >+ eval postgresql_enable="\${postgresql_${profile}_enable:-${postgresql_enable}} >+ eval postgresql_data="\${postgresql_${profile}_data:-${postgresql_data}} >+ eval postgresql_flags="\${postgresql_${profile}_flags:-${postgresql_flags}}" >+ eval postgresql_initdb_flags="\${postgresql_${profile}_initdb_flags:-${postgresql_initdb_flags}}" >+ fi >+else >+ if [ "x${postgresql_profiles}" != "x" -a "x$1" != "x" ]; then >+ for profile in ${postgresql_profiles}; do >+ eval _enable="\${postgresql_${profile}_enable}" >+ case "x${_enable:-${postgresql_enable}}" in >+ x|x[Nn][Oo]|x[Nn][Oo][Nn][Ee]) >+ continue >+ ;; >+ x[Yy][Ee][Ss]) >+ ;; >+ *) >+ if test -z "$_enable"; then >+ _var=postgresql_enable >+ else >+ _var=postgresql_"${profile}"_enable >+ fi >+ echo "Bad value" \ >+ "'${_enable:-${postgresql_enable}}'" \ >+ "for ${_var}. " \ >+ "Profile ${profile} skipped." >+ continue >+ ;; >+ esac >+ echo "===> postgresql profile: ${profile}" >+ %%PREFIX%%/etc/rc.d/postgresql $1 ${profile} >+ retcode="$?" >+ if [ "0${retcode}" -ne 0 ]; then >+ failed="${profile} (${retcode}) ${failed:-}" >+ else >+ success="${profile} ${success:-}" >+ fi >+ done >+ exit 0 >+ fi >+fi >+ >+command_args="-D ${postgresql_data} ${postgresql_flags}" >+ > postgresql_command() > { > su -l ${postgresql_user} -c "exec ${command} ${command_args} ${rc_arg}" >Index: postgresql84-server/Makefile >=================================================================== >RCS file: /home/jhelfman/ncvs/ports/databases/postgresql84-server/Makefile,v >retrieving revision 1.237 >diff -u -r1.237 Makefile >--- postgresql84-server/Makefile 2 Nov 2011 18:09:16 -0000 1.237 >+++ postgresql84-server/Makefile 23 Nov 2011 05:33:21 -0000 >@@ -7,7 +7,7 @@ > > PORTNAME?= postgresql > DISTVERSION?= 8.4.9 >-PORTREVISION?= 3 >+PORTREVISION?= 4 > CATEGORIES?= databases > MASTER_SITES= ${MASTER_SITE_PGSQL} > MASTER_SITE_SUBDIR= source/v${DISTVERSION} >Index: postgresql84-server/files/postgresql.in >=================================================================== >RCS file: /home/jhelfman/ncvs/ports/databases/postgresql84-server/files/postgresql.in,v >retrieving revision 1.5 >diff -u -r1.5 postgresql.in >--- postgresql84-server/files/postgresql.in 18 Apr 2011 23:34:27 -0000 1.5 >+++ postgresql84-server/files/postgresql.in 23 Nov 2011 05:33:02 -0000 >@@ -14,6 +14,7 @@ > # postgresql_flags="-w -s -m fast" > # postgresql_initdb_flags="--encoding=utf-8 --lc-collate=C" > # postgresql_class="default" >+# postgresql_profiles="" > # > # See %%PREFIX%%/share/doc/postgresql/README-server for more info > # >@@ -39,7 +40,6 @@ > > name=postgresql > rcvar=`set_rcvar` >-command_args="-D ${postgresql_data} ${postgresql_flags}" > extra_commands="reload initdb" > > start_cmd="postgresql_command start" >@@ -50,6 +50,57 @@ > > initdb_cmd="postgresql_initdb" > >+if [ -n "$2" ]; then >+ profile="$2" >+ if [ "x${postgresql_profiles}" != "x" ]; then >+ eval postgresql_data="\${postgresql_${profile}_data:-}" >+ if [ "x${postgresql_data}" = "x" ]; then >+ echo "You must define a data directory (postgresql_${profile}_data)" >+ exit 1 >+ fi >+ eval postgresql_enable="\${postgresql_${profile}_enable:-${postgresql_enable}} >+ eval postgresql_data="\${postgresql_${profile}_data:-${postgresql_data}} >+ eval postgresql_flags="\${postgresql_${profile}_flags:-${postgresql_flags}}" >+ eval postgresql_initdb_flags="\${postgresql_${profile}_initdb_flags:-${postgresql_initdb_flags}}" >+ fi >+else >+ if [ "x${postgresql_profiles}" != "x" -a "x$1" != "x" ]; then >+ for profile in ${postgresql_profiles}; do >+ eval _enable="\${postgresql_${profile}_enable}" >+ case "x${_enable:-${postgresql_enable}}" in >+ x|x[Nn][Oo]|x[Nn][Oo][Nn][Ee]) >+ continue >+ ;; >+ x[Yy][Ee][Ss]) >+ ;; >+ *) >+ if test -z "$_enable"; then >+ _var=postgresql_enable >+ else >+ _var=postgresql_"${profile}"_enable >+ fi >+ echo "Bad value" \ >+ "'${_enable:-${postgresql_enable}}'" \ >+ "for ${_var}. " \ >+ "Profile ${profile} skipped." >+ continue >+ ;; >+ esac >+ echo "===> postgresql profile: ${profile}" >+ %%PREFIX%%/etc/rc.d/postgresql $1 ${profile} >+ retcode="$?" >+ if [ "0${retcode}" -ne 0 ]; then >+ failed="${profile} (${retcode}) ${failed:-}" >+ else >+ success="${profile} ${success:-}" >+ fi >+ done >+ exit 0 >+ fi >+fi >+ >+command_args="-D ${postgresql_data} ${postgresql_flags}" >+ > postgresql_command() > { > su -l ${postgresql_user} -c "exec ${command} ${command_args} ${rc_arg}" >Index: postgresql90-server/Makefile >=================================================================== >RCS file: /home/jhelfman/ncvs/ports/databases/postgresql90-server/Makefile,v >retrieving revision 1.230 >diff -u -r1.230 Makefile >--- postgresql90-server/Makefile 20 Oct 2011 21:07:28 -0000 1.230 >+++ postgresql90-server/Makefile 23 Nov 2011 01:38:28 -0000 >@@ -7,7 +7,7 @@ > > PORTNAME?= postgresql > DISTVERSION?= 9.0.5 >-PORTREVISION?= 1 >+PORTREVISION?= 2 > CATEGORIES?= databases > MASTER_SITES= ${MASTER_SITE_PGSQL} > MASTER_SITE_SUBDIR= source/v${DISTVERSION} >Index: postgresql90-server/files/postgresql.in >=================================================================== >RCS file: /home/jhelfman/ncvs/ports/databases/postgresql90-server/files/postgresql.in,v >retrieving revision 1.5 >diff -u -r1.5 postgresql.in >--- postgresql90-server/files/postgresql.in 18 Apr 2011 23:34:27 -0000 1.5 >+++ postgresql90-server/files/postgresql.in 23 Nov 2011 01:37:51 -0000 >@@ -14,6 +14,7 @@ > # postgresql_flags="-w -s -m fast" > # postgresql_initdb_flags="--encoding=utf-8 --lc-collate=C" > # postgresql_class="default" >+# postgresql_profiles="" > # > # See %%PREFIX%%/share/doc/postgresql/README-server for more info > # >@@ -39,7 +40,6 @@ > > name=postgresql > rcvar=`set_rcvar` >-command_args="-D ${postgresql_data} ${postgresql_flags}" > extra_commands="reload initdb" > > start_cmd="postgresql_command start" >@@ -50,6 +50,57 @@ > > initdb_cmd="postgresql_initdb" > >+if [ -n "$2" ]; then >+ profile="$2" >+ if [ "x${postgresql_profiles}" != "x" ]; then >+ eval postgresql_data="\${postgresql_${profile}_data:-}" >+ if [ "x${postgresql_data}" = "x" ]; then >+ echo "You must define a data directory (postgresql_${profile}_data)" >+ exit 1 >+ fi >+ eval postgresql_enable="\${postgresql_${profile}_enable:-${postgresql_enable}} >+ eval postgresql_data="\${postgresql_${profile}_data:-${postgresql_data}} >+ eval postgresql_flags="\${postgresql_${profile}_flags:-${postgresql_flags}}" >+ eval postgresql_initdb_flags="\${postgresql_${profile}_initdb_flags:-${postgresql_initdb_flags}}" >+ fi >+else >+ if [ "x${postgresql_profiles}" != "x" -a "x$1" != "x" ]; then >+ for profile in ${postgresql_profiles}; do >+ eval _enable="\${postgresql_${profile}_enable}" >+ case "x${_enable:-${postgresql_enable}}" in >+ x|x[Nn][Oo]|x[Nn][Oo][Nn][Ee]) >+ continue >+ ;; >+ x[Yy][Ee][Ss]) >+ ;; >+ *) >+ if test -z "$_enable"; then >+ _var=postgresql_enable >+ else >+ _var=postgresql_"${profile}"_enable >+ fi >+ echo "Bad value" \ >+ "'${_enable:-${postgresql_enable}}'" \ >+ "for ${_var}. " \ >+ "Profile ${profile} skipped." >+ continue >+ ;; >+ esac >+ echo "===> postgresql profile: ${profile}" >+ %%PREFIX%%/etc/rc.d/postgresql $1 ${profile} >+ retcode="$?" >+ if [ "0${retcode}" -ne 0 ]; then >+ failed="${profile} (${retcode}) ${failed:-}" >+ else >+ success="${profile} ${success:-}" >+ fi >+ done >+ exit 0 >+ fi >+fi >+ >+command_args="-D ${postgresql_data} ${postgresql_flags}" >+ > postgresql_command() > { > su -l ${postgresql_user} -c "exec ${command} ${command_args} ${rc_arg}" >Index: postgresql91-server/Makefile >=================================================================== >RCS file: /home/jhelfman/ncvs/ports/databases/postgresql91-server/Makefile,v >retrieving revision 1.232 >diff -u -r1.232 Makefile >--- postgresql91-server/Makefile 29 Oct 2011 10:11:05 -0000 1.232 >+++ postgresql91-server/Makefile 23 Nov 2011 17:09:27 -0000 >@@ -7,7 +7,7 @@ > > PORTNAME?= postgresql > DISTVERSION?= 9.1.1 >-PORTREVISION?= 1 >+PORTREVISION?= 3 > CATEGORIES?= databases > MASTER_SITES= ${MASTER_SITE_PGSQL} > MASTER_SITE_SUBDIR= source/v${DISTVERSION} >Index: postgresql91-server/files/postgresql.in >=================================================================== >RCS file: /home/jhelfman/ncvs/ports/databases/postgresql91-server/files/postgresql.in,v >retrieving revision 1.6 >diff -u -r1.6 postgresql.in >--- postgresql91-server/files/postgresql.in 11 Jun 2011 23:14:30 -0000 1.6 >+++ postgresql91-server/files/postgresql.in 23 Nov 2011 17:09:45 -0000 >@@ -14,6 +14,7 @@ > # postgresql_flags="-w -s -m fast" > # postgresql_initdb_flags="--encoding=utf-8 --lc-collate=C" > # postgresql_class="default" >+# postgresql_profiles="" > # > # See %%PREFIX%%/share/doc/postgresql/README-server for more info > # >@@ -39,7 +40,6 @@ > > name=postgresql > rcvar=`set_rcvar` >-command_args="-D ${postgresql_data} ${postgresql_flags}" > extra_commands="reload initdb" > > start_cmd="postgresql_command start" >@@ -50,6 +50,57 @@ > > initdb_cmd="postgresql_initdb" > >+if [ -n "$2" ]; then >+ profile="$2" >+ if [ "x${postgresql_profiles}" != "x" ]; then >+ eval postgresql_data="\${postgresql_${profile}_data:-}" >+ if [ "x${postgresql_data}" = "x" ]; then >+ echo "You must define a data directory (postgresql_${profile}_data)" >+ exit 1 >+ fi >+ eval postgresql_enable="\${postgresql_${profile}_enable:-${postgresql_enable}} >+ eval postgresql_data="\${postgresql_${profile}_data:-${postgresql_data}} >+ eval postgresql_flags="\${postgresql_${profile}_flags:-${postgresql_flags}}" >+ eval postgresql_initdb_flags="\${postgresql_${profile}_initdb_flags:-${postgresql_initdb_flags}}" >+ fi >+else >+ if [ "x${postgresql_profiles}" != "x" -a "x$1" != "x" ]; then >+ for profile in ${postgresql_profiles}; do >+ eval _enable="\${postgresql_${profile}_enable}" >+ case "x${_enable:-${postgresql_enable}}" in >+ x|x[Nn][Oo]|x[Nn][Oo][Nn][Ee]) >+ continue >+ ;; >+ x[Yy][Ee][Ss]) >+ ;; >+ *) >+ if test -z "$_enable"; then >+ _var=postgresql_enable >+ else >+ _var=postgresql_"${profile}"_enable >+ fi >+ echo "Bad value" \ >+ "'${_enable:-${postgresql_enable}}'" \ >+ "for ${_var}. " \ >+ "Profile ${profile} skipped." >+ continue >+ ;; >+ esac >+ echo "===> postgresql profile: ${profile}" >+ %%PREFIX%%/etc/rc.d/postgresql $1 ${profile} >+ retcode="$?" >+ if [ "0${retcode}" -ne 0 ]; then >+ failed="${profile} (${retcode}) ${failed:-}" >+ else >+ success="${profile} ${success:-}" >+ fi >+ done >+ exit 0 >+ fi >+fi >+ >+command_args="-D ${postgresql_data} ${postgresql_flags}" >+ > postgresql_command() > { > su -l ${postgresql_user} -c "exec ${command} ${command_args} ${rc_arg}"
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 162776
:
120036
| 120037