merging the edits made in the 1.0.x branch to the trunk, for /bin

This commit is contained in:
fgerlits 2005-11-21 16:44:38 +00:00
parent e2a17bc81b
commit 51181f7b45
4 changed files with 53 additions and 87 deletions

View file

@ -1,48 +0,0 @@
#!/bin/sh
#-------------------------------------------------------------------------------
# Copyright (c) 2004 Media Development Loan Fund
#
# This file is part of the LiveSupport project.
# http://livesupport.campware.org/
# To report bugs, send an e-mail to bugs@campware.org
#
# LiveSupport is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
#
# LiveSupport is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with LiveSupport; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
#
#
# Author : $Author$
# Version : $Revision$
# Location : $URL$
#-------------------------------------------------------------------------------
#-------------------------------------------------------------------------------
# This script runs cvs to update the LiveSupport source code.
#-------------------------------------------------------------------------------
reldir=`dirname $0`/..
basedir=`cd $reldir; pwd;`
bindir=$basedir/bin
docdir=$basedir/doc
tmpdir=$basedir/tmp
logdir=$basedir/tmp
echo "";
echo "The LiveSupport source code will be updated now. The update will be";
echo "loged within cvs_checkout.log and printed to the console";
echo "";
cd $bindir/../..
cvs -z3 -d :pserver:anonymous@netfinity-5.mdlf.org:/home/cvs checkout livesupport >& $logdir/cvs_checkout.log
ls -l $logdir/cvs_checkout.log >> $logdir/cvs_checkout.log
cat $logdir/cvs_checkout.log

View file

@ -64,6 +64,8 @@ printUsage()
echo " database. [default: livesupport]"; echo " database. [default: livesupport]";
echo " -w, --dbpassword The database user password."; echo " -w, --dbpassword The database user password.";
echo " [default: livesupport]"; echo " [default: livesupport]";
echo " -p, --postgresql-dir The postgresql data directory, containing"
echo " pg_hba.conf [default: /etc/postgresql]"
echo " -h, --help Print this message and exit."; echo " -h, --help Print this message and exit.";
echo ""; echo "";
} }
@ -74,7 +76,7 @@ printUsage()
#------------------------------------------------------------------------------- #-------------------------------------------------------------------------------
CMD=${0##*/} CMD=${0##*/}
opts=$(getopt -o d:D:g:H:hp:P:r:s:u:w:o: -l apache-group:,database:,dbserver:,dbuser:,dbpassword:,directory:,host:,help,port:,scheduler-port:,www-root:,output-device -n $CMD -- "$@") || exit 1 opts=$(getopt -o d:D:g:hp:r:s:u:w: -l apache-group:,database:,dbserver:,dbuser:,dbpassword:,directory:,help,postgresql-dir:,www-root: -n $CMD -- "$@") || exit 1
eval set -- "$opts" eval set -- "$opts"
while true; do while true; do
case "$1" in case "$1" in
@ -90,6 +92,9 @@ while true; do
-h|--help) -h|--help)
printUsage; printUsage;
exit 0;; exit 0;;
-p|--postgresql-dir)
postgresql_dir=$2;
shift; shift;;
-r|--www-root) -r|--www-root)
www_root=$2; www_root=$2;
shift; shift;; shift; shift;;
@ -138,6 +143,10 @@ if [ "x$apache_group" == "x" ]; then
apache_group=www-data; apache_group=www-data;
fi fi
if [ "x$postgresql_dir" == "x" ]; then
postgresql_dir=/etc/postgresql;
fi
if [ "x$www_root" == "x" ]; then if [ "x$www_root" == "x" ]; then
www_root=/var/www; www_root=/var/www;
fi fi
@ -153,6 +162,7 @@ echo " database user: $dbuser";
echo " database user password: $dbpassword"; echo " database user password: $dbpassword";
echo " apache daemon group: $apache_group"; echo " apache daemon group: $apache_group";
echo " apache document root: $www_root"; echo " apache document root: $www_root";
echo " postgresql data directory: $postgresql_dir";
echo "" echo ""
#------------------------------------------------------------------------------- #-------------------------------------------------------------------------------
@ -230,7 +240,7 @@ rm -f $group_tmp_file;
#------------------------------------------------------------------------------- #-------------------------------------------------------------------------------
echo "Modifying postgresql access permissions..."; echo "Modifying postgresql access permissions...";
pg_config_dir=/etc/postgresql pg_config_dir=$postgresql_dir
pg_config_file=pg_hba.conf pg_config_file=pg_hba.conf
pg_config_file_saved=pg_hba.conf.before-livesupport pg_config_file_saved=pg_hba.conf.before-livesupport
@ -240,7 +250,10 @@ fi
cp $install_etc/$pg_config_file $pg_config_dir/$pg_config_file cp $install_etc/$pg_config_file $pg_config_dir/$pg_config_file
chown root:$postgres_user $pg_config_dir/$pg_config_file chown root:$postgres_user $pg_config_dir/$pg_config_file
/etc/init.d/postgresql restart # don't use restart for the init script, as it might return prematurely
# and in the later call to psql we wouldn't be able to connect
/etc/init.d/postgresql stop
/etc/init.d/postgresql start
#------------------------------------------------------------------------------- #-------------------------------------------------------------------------------
@ -303,8 +316,11 @@ odbcinst -i -s -l -f $odbc_template || exit 1;
#------------------------------------------------------------------------------- #-------------------------------------------------------------------------------
# Install PEAR packages (locally in the LiveSupport) # Install PEAR packages (locally in the LiveSupport)
# only if necessary
#------------------------------------------------------------------------------- #-------------------------------------------------------------------------------
$install_usr/lib/pear/bin/install.sh -d $installdir || exit 1; if [ -f $install_usr/lib/pear/bin/install.sh ]; then
$install_usr/lib/pear/bin/install.sh -d $installdir || exit 1;
fi
#------------------------------------------------------------------------------- #-------------------------------------------------------------------------------

View file

@ -27,55 +27,52 @@
#------------------------------------------------------------------------------- #-------------------------------------------------------------------------------
#------------------------------------------------------------------------------- #-------------------------------------------------------------------------------
# This script runs cvs to update the LiveSupport source code and starts # This script starts the LiveSupport recompile process.
# the recompile process.
#------------------------------------------------------------------------------- #-------------------------------------------------------------------------------
reldir=`dirname $0`/.. reldir=`dirname $0`/..
basedir=`cd $reldir; pwd;` basedir=`cd $reldir; pwd;`
bindir=$basedir/bin bindir=$basedir/bin
docdir=$basedir/doc
tmpdir=$basedir/tmp tmpdir=$basedir/tmp
logdir=$basedir/tmp logdir=$basedir/tmp
export PATH=~/bin:$PATH export PATH=~/bin:$PATH
echo ""; echo "";
echo "The source code will be updated by cvs and the recompile process"; echo "The recompile process will be started. All steps are being logged in";
echo "will be started. All steps are being logged within the log"; echo "$logdir ";
echo "directory $logdir";
echo ""; echo "";
echo "Are you certainly of ran ./configure first !"; echo "Are you certainly of ran ./configure first !";
echo "";
echo "Now updating the code by cvs...";
cd $bindir/.. cd $bindir/..
cvs update -dP >& $logdir/cvs_update_just_before_setup.log make modprod_distclean >& $logdir/make_modprod_distclean_setup.log
ls -l $logdir/cvs_update_just_before_setup.log >> $logdir/cvs_update_just_before_setup.log ls -l $logdir/make_modprod_distclean_setup.log >> $logdir/make_modprod_distclean_setup.log
echo "Compare with cvs is be done, cvs_update_just_before_setup.log is created"; echo "";
make distclean >& $logdir/make_distclean_setup.log echo "Cleaning the setup is done, make_modprod_distclean_setup.log is created";
ls -l $logdir/make_distclean_setup.log >> $logdir/make_distclean_setup.log #echo "";
echo "Cleaning the setup is be done, make_distclean_setup.log is created"; #echo "Now Recompiling ... Tools";
#make tools_setup >& $logdir/make_install_tools_setup.log #make tools_setup >& $logdir/make_install_tools_setup.log
#ls -l $logdir/make_install_tools_setup.log >> $logdir/make_install_tools_setup.log #ls -l $logdir/make_install_tools_setup.log >> $logdir/make_install_tools_setup.log
#echo "Done Tools Setup, make_install_tools_setup.log is created"; #echo "Done Tools Setup, make_install_tools_setup.log is created";
echo ""; echo "";
echo "Skipping Tools setup, remove # for recompiling tools"; echo "Skipping Tools setup, remove # for recompiling tools";
echo ""; echo "";
echo "Now Configure ..."; echo "Now Configure ... Modules ... Products";
make modules_setup >& $logdir/configure_modules_setup.log make modules_setup >& $logdir/make_configure_modules_setup.log
ls -l $logdir/configure_modules_setup.log >> $logdir/configure_modules_setup.log ls -l $logdir/make_configure_modules_setup.log >> $logdir/make_configure_modules_setup.log
echo "Configure the Modules is be done, configure_modules_setup.log is created"; echo "Configure the Modules is done, make_configure_modules_setup.log is created";
make products_setup >& $logdir/configure_products_setup.log make products_setup >& $logdir/make_configure_products_setup.log
ls -l $logdir/configure_products_setup.log >> $logdir/configure_products_setup.log ls -l $logdir/make_configure_products_setup.log >> $logdir/make_configure_products_setup.log
echo "Configure the Products is be done, configure_products_setup.log is created"; echo "Configure the Products is done, make_configure_products_setup.log is created";
echo ""; echo "";
echo "Now Recompiling ..."; echo "Now Recompiling ... ";
make compile >& $logdir/make_compile_setup.log make compile >& $logdir/make_compile_setup.log
ls -l $logdir/make_compile_setup.log >> $logdir/make_compile_setup.log ls -l $logdir/make_compile_setup.log >> $logdir/make_compile_setup.log
echo "Compiling is be done, make_compile_setup.log is created"; echo "Compiling is done, make_compile_setup.log is created";
echo ""; echo "";
echo "Now checking ..."; echo "Now checking ...";
make check >& $logdir/make_check_setup.log make check >& $logdir/make_check_setup.log
ls -l $logdir/make_check_setup.log >> $logdir/make_check_setup.log ls -l $logdir/make_check_setup.log >> $logdir/make_check_setup.log
echo "Checking is be done, make_check_setup.log is created"; echo "Checking is be done, make_check_setup.log is created";
echo ""; echo "";
ls -l $logdir

View file

@ -33,16 +33,17 @@
reldir=`dirname $0`/.. reldir=`dirname $0`/..
basedir=`cd $reldir; pwd;` basedir=`cd $reldir; pwd;`
bindir=$basedir/bin bindir=$basedir/bin
docdir=$basedir/doc
tmpdir=$basedir/tmp tmpdir=$basedir/tmp
logdir=$basedir/tmp logdir=$basedir/tmp
echo ""; echo "";
echo "The source code will be updated now ... logged within the log directory"; echo "The LiveSupport source code will be updated now ... and logged in";
echo "$logdir"; echo "$logdir";
echo ""; echo "";
cd $bindir/.. cd $bindir/..
cvs update -dP >& $logdir/cvs_update.log svn update >& $logdir/svn_update.log
ls -l $logdir/cvs_update.log >> $logdir/cvs_update.log ls -l $logdir/svn_update.log >> $logdir/svn_update.log
cat $logdir/cvs_update.log cat $logdir/svn_update.log
echo "";
echo "The svn update is done, svn_update.log is created";