252N/A#!/bin/ksh93 -x
252N/A#
252N/A# CDDL HEADER START
252N/A#
252N/A# The contents of this file are subject to the terms of the
252N/A# Common Development and Distribution License (the "License").
252N/A# You may not use this file except in compliance with the License.
252N/A#
252N/A# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
252N/A# or http://www.opensolaris.org/os/licensing.
252N/A# See the License for the specific language governing permissions
252N/A# and limitations under the License.
252N/A#
252N/A# When distributing Covered Code, include this CDDL HEADER in each
252N/A# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
252N/A# If applicable, add the following below this CDDL HEADER, with the
252N/A# fields enclosed by brackets "[]" replaced with your own identifying
252N/A# information: Portions Copyright [yyyy] [name of copyright owner]
252N/A#
252N/A# CDDL HEADER END
252N/A#
252N/A#
5865N/A# Copyright (c) 2009, 2016, Oracle and/or its affiliates. All rights reserved.
252N/A#
252N/A#
252N/A#pragma ident "@(#)run-tests 1.1 09/07/08 SMI"
252N/A#
252N/A# *
252N/A# * U.S. Government Rights - Commercial software. Government users are subject
252N/A# * to the Sun Microsystems, Inc. standard license agreement and applicable
252N/A# * provisions of the FAR and its supplements.
252N/A#
252N/A# Use is subject to license terms.
252N/A#
252N/A# This distribution may include materials developed by third parties. Sun,
252N/A# Sun Microsystems, the Sun logo and Solaris are trademarks or registered
252N/A# trademarks of Sun Microsystems, Inc. in the U.S. and other countries.
252N/A#
252N/A#
252N/A
252N/A# Run Net-SNMP testing kit
252N/A
252N/A# get the arch that we are building on
252N/Aarch=`uname -p`
252N/A
252N/ADIR=$1
252N/AMACH32=$2
252N/AMACH64=$3
252N/AIPRE=usr
252N/AIARCH=`arch`
252N/AIPROC=`uname -p | grep sparc > /dev/null && echo sparcv9 || echo amd64`
252N/AIROOTB=/${IPRE}/bin
252N/AIROOTS=/${IPRE}/sbin
252N/A
252N/AVER=${DIR}/${MACH32}
252N/AVER64=${DIR}/${MACH64}
252N/A
252N/Acd ${VER}/testing
252N/A
252N/Aif [ ${IPROC} == "amd64" ]; then
252N/APATH=${IROOT}/usr/sbin/i86:${IROOTB}:${IROOTS}:/usr/ccs/bin:/usr/bin:${SPRO_VROOT}/bin:/usr/sbin:/sbin:/usr/bin:/usr/etc:/usr/sbin:/etc:.:/usr/openwin/bin
252N/Aexport PATH
252N/A#./RUNTESTS -a > test.32.out 2>&1
2376N/A./RUNTESTS -a > ${VER}/test.32.out 2>&1
252N/Aif [ $? -ne 0 ]; then
252N/A echo ""
252N/A echo "=================================================================="
252N/A echo "======= Tests failed for i386 architecture ===================="
252N/A echo "======= see test.32.out in ================="
252N/A echo "=================================================================="
252N/A echo ""
252N/Afi
252N/A
252N/APATH=${IROOT}/usr/sbin/amd64:${IROOT}/usr/bin:/usr/ccs/bin:/usr/bin:${SPRO_VROOT}/bin:/usr/sbin:/sbin:/usr/bin:/usr/etc:/usr/sbin:/etc:.:/usr/openwin/bin
252N/Aexport PATH
252N/Acd ${VER64}/testing
2376N/A./RUNTESTS -a > ${VER64}/test.64.out 2>&1
252N/Aif [ $? -ne 0 ]; then
252N/A echo ""
252N/A echo "=================================================================="
252N/A echo "======= Tests failed for AMD architecture ===================="
252N/A echo "======= see test.64.out in $testdir ================="
252N/A echo "=================================================================="
252N/A echo ""
252N/Afi
252N/Afi
252N/A
252N/Aif [ ${IPROC} == "sparcv9" ]; then
252N/Acd ${VER64}/testing
252N/APATH=${IROOT}/usr/sbin:${IROOT}/usr/bin:/usr/ccs/bin:/usr/bin:${SPRO_VROOT}/bin:/usr/sbin:/sbin:/usr/bin:/usr/etc:/usr/sbin:/etc:.:/usr/openwin/bin
252N/Aexport PATH
2376N/A./RUNTESTS -a > ${VER64}/test.64.out 2>&1
252N/Aif [ $? -ne 0 ]; then
252N/A echo ""
252N/A echo "=================================================================="
252N/A echo "======= Tests failed for SPARC architecture ===================="
252N/A echo "======= see test.64.out in $testdir ================="
252N/A echo "=================================================================="
252N/A echo ""
252N/Afi
252N/Afi
252N/A