gpu: nvgpu: unit: update unit.h for target

The directory structure is every so slightly different on target, so
this handles the differences.

JIRA NVGPU-1042

Change-Id: I5a0566c7d371fcb5cd541c71841e8acedfaac6e2
Signed-off-by: Philip Elcan <pelcan@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1837443
Reviewed-by: svc-misra-checker <svc-misra-checker@nvidia.com>
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Alex Waterman <alexw@nvidia.com>
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
This commit is contained in:
Philip Elcan
2018-09-21 10:59:49 -04:00
committed by mobile promotions
parent 7970c80152
commit bf99dfdaf2

View File

@@ -1,14 +1,23 @@
#!/bin/bash
# Copyright (c) 2018, NVIDIA CORPORATION. All Rights Reserved.
#
# Execute the unit test. Args to this script are passed on to the unit test
# core. This just serves to set the LD_LIBRARY_PATH environment variable such
# that unit tests are found and nvgpu-drv is found.
#
LD_LIBRARY_PATH="build:build/units"
NVGPU_UNIT=build/nvgpu_unit
if [ -f nvgpu_unit ]; then
# if the executable is in the current directory, we are running on
# target, so use that dir structure
LD_LIBRARY_PATH=".:units"
NVGPU_UNIT="./nvgpu_unit -L units/"
else
# running on host
LD_LIBRARY_PATH="build:build/units"
NVGPU_UNIT=build/nvgpu_unit
fi
export LD_LIBRARY_PATH
echo "$ $NVGPU_UNIT $*"