gpu: nvgpu: unit: extend unit test build system

Added NV_COMPONENT_INCLUDES and
NV_COMPONENT_NEEDED_INTERFACE_DIRS support as we need
them for building QNX nvgpu_rmos/ files with the test
library

JIRA NVGPU-1352

Change-Id: If1944396dac2ac84fadd5cbb487fa700c829523a
Signed-off-by: asah <asah@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1994355
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Philip Elcan <pelcan@nvidia.com>
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:
asah
2019-01-10 12:29:19 +05:30
committed by mobile promotions
parent 7e503d619d
commit 35ea60fe80

View File

@@ -1,6 +1,6 @@
################################### tell Emacs this is a -*- makefile-gmake -*-
#
# Copyright (c) 2018 NVIDIA CORPORATION. All Rights Reserved.
# Copyright (c) 2018-2019 NVIDIA CORPORATION. All Rights Reserved.
#
# NVIDIA CORPORATION and its licensors retain all intellectual property
# and proprietary rights in and to this software, related documentation
@@ -29,12 +29,22 @@ NV_COMPONENT_SOURCES := \
$(NVGPU_UNIT_NAME).c
endif
ifdef NVGPU_UNIT_INCLUDES
NV_COMPONENT_INCLUDES := \
$(NVGPU_UNIT_INCLUDES)
endif
NV_COMPONENT_CFLAGS += -D__NVGPU_POSIX__
NV_COMPONENT_NEEDED_INTERFACE_DIRS += \
$(NV_SOURCE)/kernel/nvgpu/drivers/gpu/nvgpu \
$(NV_SOURCE)/kernel/nvgpu/userspace
ifdef NVGPU_UNIT_INTERFACE_DIRS
NV_COMPONENT_NEEDED_INTERFACE_DIRS += \
$(NVGPU_UNIT_INTERFACE_DIRS)
endif
NV_COMPONENT_SYSTEMIMAGE_DIR := $(NV_SYSTEMIMAGE_TEST_EXECUTABLE_DIR)/nvgpu_unit/units
systemimage:: $(NV_COMPONENT_SYSTEMIMAGE_DIR)
$(NV_COMPONENT_SYSTEMIMAGE_DIR) : $(NV_SYSTEMIMAGE_TEST_EXECUTABLE_DIR)