+
+ # iterate across our sub-directories and find the perl scripts.
+ # this currently only looks one level down.
+ for i in $FEISTY_MEOW_SCRIPTS/*; do
+ if [ -d "$i" ]; then
+ # check if there is a perl file present; add the folder to PERLLIB if so.
+ ls $i/*.pl &>/dev/null
+ if [ $? -eq 0 ]; then
+ PERLLIB+=":$i"
+ fi
+ fi
+ done
+ #echo PERLLIB is now $PERLLIB
+
+ ##############
+
+ # set this so nechung can find its data.
+ export NECHUNG=$FEISTY_MEOW_DIR/database/fortunes.dat
+
+ # ensure we use the right kind of secure shell.
+ export CVS_RSH=$FEISTY_MEOW_SCRIPTS/security/ssh.sh
+ export GIT_SSH=$FEISTY_MEOW_SCRIPTS/security/ssh.sh
+
+ # the base checkout list is just to update feisty_meow. additional folder
+ # names can be added in your customized scripts.
+ export REPOSITORY_LIST="feisty_meow"
+
+ # initializes the feisty meow build variables, if possible.
+ function initialize_build_variables()
+ {
+ found_build_vars=0
+ # we need to know the feisty meow directory, or we bail.
+ if [ -z "$FEISTY_MEOW_DIR" ]; then return; fi
+ # pick from our expected generator folder, but make sure it's there...
+ buildvars="$FEISTY_MEOW_DIR/scripts/generator/build_variables.sh"
+ if [ -f "$buildvars" ]; then
+ # yep, that one looks good, so pull in the build defs.
+ source "$buildvars" "$buildvars"
+ found_build_vars=1
+ fi
+ # now augment the environment if we found our build variables.
+ if [ $found_build_vars == 1 ]; then
+ # the binary directory contains handy programs we use a lot. we set
+ # up the path to it here based on the operating system.
+ export BINDIR=$FEISTY_MEOW_DIR/production/binaries
+ # add binaries created within build to the path.
+ export PATH="$BINDIR:$PATH"
+ # Shared libraries are located via this variable.
+ export LD_LIBRARY_PATH="$LD_LIBRARY_PATH:$BINDIR"
+ fi
+ }
+
+ ##############
+
+ # windoze specific patching up missing things.
+
+ if [ "$OS" == "Windows_NT" ]; then
+ export HOSTNAME=$(echo $HOSTNAME | tr A-Z a-z)
+ fi
+
+ ##############
+
+ # load in the build environment.
+ initialize_build_variables
+
+ ##############
+
+ # set the path for locating applications. this is done after any
+ # potential overrides from the user.
+ #export PATH="$(dos_to_msys_path $BINDIR):$(dos_to_msys_path $FEISTY_MEOW_GENERATED):$PATH:/bin:/sbin:/usr/sbin:/usr/local/bin:/usr/local/lib:/usr/games:/usr/bin:."
+ export PATH="$FEISTY_MEOW_GENERATED:$PATH:/sbin:."
+###noise! :/bin:/sbin:/usr/sbin:/usr/local/bin:/usr/local/lib:/usr/games:/usr/bin:.
+
+ ##############
+
+ # set the SHUNIT_DIR so our shunit tests can find the codebase.
+ export SHUNIT_DIR="$FEISTY_MEOW_SCRIPTS/shunit"
+
+ ##############
+
+ if [ ! -z "$SHELL_DEBUG" ]; then echo variables initialization ends....; fi