#------------------------------------------------------------------------------
# Usage:
#
# cd <YourHMSWorkspaceRoot>/dev/p4/common/hms/test
# source ./env.sh
#------------------------------------------------------------------------------

# These settings assume that an SDP development workspace is mapped to a root
# directory parallel to the root diretory of the HMS workspace, with 'sdp' in
# place of 'hms'.

# In a runtime environment, HMS is overlayed and blended into the SDP in the
# "as-deployed" /p4/common structure. For example, HMS and SDP libs appear
# in /p4/common/lib. These settings allow testing of files in the
# development code tree without a runtime environment. 

export HMS_TEST_HOME=$PWD
export HMS_HOME="${HMS_TEST_HOME%/*}"
export HMS_BIN="${HMS_HOME%/*}/bin"
export HMS_LIB="${HMS_TEST_HOME%/hms/test}/lib"
export HMS_SCRIPTS="${HMS_HOME}/scripts"
export SDP_HOME="${HMS_HOME%/p4/common/hms}"
export SDP_HOME="${SDP_HOME/hms/sdp}"
export P4U_LIB="${SDP_HOME}/Server/Unix/p4/common/lib"
export P4U_ENV="${P4U_LIB}/p4u_env.sh"
export P4CBIN="${SDP_HOME}/Server/Unix/p4/common/bin"
export P4CCFG="${SDP_HOME}/Server/Unix/p4/common/config"
export SDP_ENV="$P4CCFG/p4_vars.template"

export PATH="$HMS_BIN:$HMS_SCRIPTS:$PATH"
export P4BROKERBIN=p4broker_test_hms
unset P4CONFIG
export P4ENVIRO=/dev/null/.p4enviro
