Re: make installcheck on non-default ports - Mailing list pgsql-patches

From Joe Conway
Subject Re: make installcheck on non-default ports
Date
Msg-id 3FC46776.5050607@joeconway.com
Whole thread Raw
In response to Re: make installcheck on non-default ports  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-patches
Tom Lane wrote:
> I think there is something wrong with your setup procedures, because
> I've never needed such.

The main problem seemed to be that I had --disable-rpath in my configure
script, left over from when I was playing with options used by the RPM
spec file. Once I got rid of that, and started using a derivative of
Tom's scripts, it all started to work just fine.

Now I can do:

   . pg73          (or pg74 or pg75)
   cvs up
   make clean
   pgconfig
   make all
   pgctl stop
   make install
   pgctl start
   make installcheck

I've attached the scripts in case anyone is interested.

Joe
# Source this, eg with ". bin/setvariables", to prepare for Postgres work.
# This version is for a debug install.

STDPATH=${STDPATH:-$PATH}
STDMANPATH=${STDMANPATH:-$MANPATH}

PGVER="7.5"
PGPORT=55435
PGUSER=postgres
PGTAGNAME="pgsql ${PGVER}"
PGSRCROOT=/opt/src/pgsql-cvs/pgsql-${PGVER}
PGINSTROOT=/usr/local/pgsql-${PGVER}
PATH=$PGINSTROOT/bin:$STDPATH
MANPATH=$PGINSTROOT/man:$STDMANPATH
PGLIB=$PGINSTROOT/lib
PGDATA=$PGINSTROOT/data
PMOPTIONS="-p ${PGPORT} -i -F"
PMLOGFILE=$PGINSTROOT/debugserver.log

export PGSRCROOT PGINSTROOT PATH MANPATH PGLIB PGDATA
export STDPATH STDMANPATH PGTAGNAME PGPORT PGUSER
export PMOPTIONS PMLOGFILE#!/bin/sh

. /opt/src/pgsql-cvs/setvariables.74
cd ${PGSRCROOT}


#!/bin/sh

. /opt/src/pgsql-cvs/setvariables.75
cd ${PGSRCROOT}


#! /bin/sh

./configure \
 --prefix=${PGINSTROOT} \
 --with-pgport=${PGPORT} \
 --with-perl \
 --with-tcl \
 --with-tclconfig=/usr/lib \
 --without-tk \
 --with-python \
 --enable-nls \
 --enable-debug \
 --enable-cassert \
 --enable-depend \
 --with-openssl \
 --with-pam \
 --enable-integer-datetimes \
 --with-krb5=/usr/kerberos

#! /bin/sh

PGCTL="${PGINSTROOT}/bin/pg_ctl"

start(){
    echo "Starting ${PGTAGNAME}"
        su -l postgres -s /bin/sh -c "${PGCTL} start -D ${PGDATA} -l ${PMLOGFILE} -o '${PMOPTIONS}'"
}

stop(){
    echo $"Stopping ${PGTAGNAME}"
    su -l postgres -s /bin/sh -c "${PGCTL} stop -D ${PGDATA} -s -m fast"
}

restart(){
    stop
    start
}

reload(){
    echo $"Reloading ${PGTAGNAME}"
    su -l postgres -s /bin/sh -c "${PGCTL} reload -D ${PGDATA} -s"
}


# See how we were called.
case "$1" in
  start)
    start
    ;;
  stop)
    stop
    ;;
  restart)
    restart
    ;;
  reload)
    reload
    ;;
  *)
    echo $"Usage: $0 {start|stop|restart|reload}"
    exit 1
esac

exit 0

# Source this, eg with ". bin/setvariables", to prepare for Postgres work.
# This version is for a debug install.

STDPATH=${STDPATH:-$PATH}
STDMANPATH=${STDMANPATH:-$MANPATH}

PGVER="7.3"
PGPORT=55433
PGUSER=postgres
PGTAGNAME="pgsql ${PGVER}"
PGSRCROOT=/opt/src/pgsql-cvs/pgsql-${PGVER}
PGINSTROOT=/usr/local/pgsql-${PGVER}
PATH=$PGINSTROOT/bin:$STDPATH
MANPATH=$PGINSTROOT/man:$STDMANPATH
PGLIB=$PGINSTROOT/lib
PGDATA=$PGINSTROOT/data
PMOPTIONS="-p ${PGPORT} -i -F"
PMLOGFILE=$PGINSTROOT/debugserver.log

export PGSRCROOT PGINSTROOT PATH MANPATH PGLIB PGDATA
export STDPATH STDMANPATH PGTAGNAME PGPORT PGUSER
export PMOPTIONS PMLOGFILE
# Source this, eg with ". bin/setvariables", to prepare for Postgres work.
# This version is for a debug install.

STDPATH=${STDPATH:-$PATH}
STDMANPATH=${STDMANPATH:-$MANPATH}

PGVER="7.4"
PGPORT=55434
PGUSER=postgres
PGTAGNAME="pgsql ${PGVER}"
PGSRCROOT=/opt/src/pgsql-cvs/pgsql-${PGVER}
PGINSTROOT=/usr/local/pgsql-${PGVER}
PATH=$PGINSTROOT/bin:$STDPATH
MANPATH=$PGINSTROOT/man:$STDMANPATH
PGLIB=$PGINSTROOT/lib
PGDATA=$PGINSTROOT/data
PMOPTIONS="-p ${PGPORT} -i -F"
PMLOGFILE=$PGINSTROOT/debugserver.log

export PGSRCROOT PGINSTROOT PATH MANPATH PGLIB PGDATA
export STDPATH STDMANPATH PGTAGNAME PGPORT PGUSER
export PMOPTIONS PMLOGFILE#!/bin/sh

. /opt/src/pgsql-cvs/setvariables.73
cd ${PGSRCROOT}



pgsql-patches by date:

Previous
From: Joe Conway
Date:
Subject: Re: make installcheck on non-default ports
Next
From: Serguei Mokhov
Date:
Subject: Re: postgress-ru.po - further translation