From 6cc4d5078e348fba2a3984cb41a1913b2874c466 Mon Sep 17 00:00:00 2001 From: Christian Geddes Date: Thu, 28 Feb 2019 12:40:19 -0600 Subject: Again try to fix checkpoint issue with fips930 simics Previously we tried to fix the issue where checkpoints were failing because environment variables were not set. We thought by using the printenv command it would just return "" if no variable was defined but we still saw errors. Now we will explicitly set the local variable to "" then check if the environment variable exists, if it does then we will set it to the local variable we are using. Change-Id: Iff5ffc9d9a05b1dd8ee85dbc8299884c26d4c892 CQ: SW458604 Reviewed-on: http://rchgit01.rchland.ibm.com/gerrit1/72649 Tested-by: Jenkins Server Tested-by: Jenkins OP Build CI Tested-by: Jenkins OP HW Reviewed-by: CALEB SCHLOSSIN Tested-by: FSP CI Jenkins Reviewed-by: William G. Hoffa --- src/build/simics/startup.simics | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) (limited to 'src/build') diff --git a/src/build/simics/startup.simics b/src/build/simics/startup.simics index 884fd0e27..a6534be01 100755 --- a/src/build/simics/startup.simics +++ b/src/build/simics/startup.simics @@ -26,8 +26,17 @@ python "os.environ['HB_TOOLPATH'] = \""+$hb_script_location+"\"" # TODO RTC: 204842 Revist once we get way to read CEC_TYPE from simics if ($hb_mode == 1) { - $model = (shell "printenv CEC_TYPE") - $machine_name = (shell "printenv MACHINE") + + $model="" + if(env -x CEC_TYPE) { + $model = (env CEC_TYPE) + } + + $machine_name="" + if(env -x MACHINE) { + $machine_name = (env MACHINE) + } + $hb_machine = "unknown" if ($model == "p9_zztop") {$hb_machine = "zztop"} if ($model == "p9_zeppelin") {$hb_machine = "zeppelin"} -- cgit v1.2.1