buildit revision 970
#
# buildit
# Script for building OpenSolaris X Consolidation
#
###########################################################################
#
#
# Permission is hereby granted, free of charge, to any person obtaining a
# copy of this software and associated documentation files (the "Software"),
# to deal in the Software without restriction, including without limitation
# the rights to use, copy, modify, merge, publish, distribute, sublicense,
# Software is furnished to do so, subject to the following conditions:
#
# The above copyright notice and this permission notice (including the next
# paragraph) shall be included in all copies or substantial portions of the
# Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
# THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
# DEALINGS IN THE SOFTWARE.
#
###########################################################################
#
#
export PATH
while getopts pP:v i; do
case $i in
p) MAKE_PKGS=1 ;;
v) VERBOSE_FLAGS="-v" ;;
P) PUBLISHER_FLAGS="-p $OPTARG" ;;
esac
done
if [[ $? != 0 ]] ; then
print -u2 "USAGE: $0 [-p [-P publisher]] [-v]"
exit 2
fi
# Send all further output & errors to the log file
# Find hg id and export it so set-elf-comments.pl doesn't have to re-run
# for every module built
*) print "${tag}" ;;
esac
}
print "------------------------------------------------------------------------------"
print "Building gate at hg id: ${XBUILD_HG_ID}"
print -n "Start time: " ; date
print -n "Building on: " ; uname -a
print "Using these compilers: "
# Make sure Sun C compiler is at least version 5.9 (Studio 12)
print $_ ; print "*** Compiler too old!\n" if ( ($1 != 5) || ($2 < 9) ) }'
gcc -v
# Exported to stop Sun compilers from reporting home on each usage
export SUNW_NO_UPDATE_NOTIFY='true'
export UT_NO_USAGE_TRACKING='1'
print "Using these environment variables: "
print "------------------------------------------------------------------------------"
# Remove old proto area & package area to clean after moving to new locations
if [ "${MACH}" = "i386" ]; then
else
fi
# Clean new proto areas for this architecture
# Run as two steps to avoid race between cleaning & rebuilding when
# using parallel make
cd ..
print "\nFinished building the X Window System Consolidation for OpenSolaris.\n"
print -n "Finish time: " ; date
perl -e '$runtime = time - $ARGV[0];
printf("Runtime: %d:%02d\n", $runtime/3600, ($runtime%3600)/60); ' \
"${START}"
if [ "${MAKE_PKGS}" = 1 ] ; then
fi