# --- T2-COPYRIGHT-NOTE-BEGIN --- # T2 SDE: package/*/postgresql/postgresql.conf # Copyright (C) 2004 - 2021 The T2 SDE Project # Copyright (C) 1998 - 2003 ROCK Linux Project # # This Copyright note is generated by scripts/Create-CopyPatch, # more information can be found in the files COPYING and README. # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License version 2. # --- T2-COPYRIGHT-NOTE-END --- if [ $prefix_auto = 1 ]; then if [ "$SDECFG_PKG_POSTGRESQL_CORE_PREFIX" ]; then prefix="$SDECFG_PKG_POSTGRESQL_CORE_PREFIX" else prefix="opt/postgresql" fi set_confopt fi var_append extraconfopt " " "--with-CXX" var_append extraconfopt " " "--with-gnu-ld" var_append extraconfopt " " "--with-perl" var_append extraconfopt " " "--with-openssl" # --with-tcl build Tcl modules (PL/Tcl) if pkginstalled perl; then var_append extraconfopt " " "--with-perl" fi if pkginstalled python; then var_append extraconfopt " " "--with-python" fi postgresql_pm() { # Create the data directory mkdir -p $root$localstatedir/lib/postgres/ chown -R postgres:postgres $root$localstatedir/lib/postgres # Create the Profile echo "Creating /etc/profile.d/$pkg ..." cat <<- EOT > $root/etc/profile.d/$pkg export PGDATA=$localstatedir/lib/postgres EOT } hook_add postmake 5 "postgresql_pm" hook_add postmake 4 "make -C contrib/" hook_add postdoc 3 "cp -dR contrib/ $docdir/"