From eda88f56abbfeacb2c6bc46af4535ef96ae5c7d8 Mon Sep 17 00:00:00 2001 From: Philip Elcan Date: Tue, 26 Feb 2019 16:33:51 -0500 Subject: [PATCH] gpu: nvgpu: unit: allow units to link against libraries Allow unit tests to define NVGPU_UNIT_SHARED_LIBRARIES in their tmake files for linking if necessary. For example, pthreads. JIRA NVGPU-2251 Change-Id: Ieeae10fe981d82e2caa0fbde041b72b0887b6ca6 Signed-off-by: Philip Elcan Reviewed-on: https://git-master.nvidia.com/r/2034425 GVS: Gerrit_Virtual_Submit Reviewed-by: Alex Waterman Reviewed-by: mobile promotions Tested-by: mobile promotions --- userspace/units/Makefile.units.common.tmk | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/userspace/units/Makefile.units.common.tmk b/userspace/units/Makefile.units.common.tmk index 25337c2f9..a1948d058 100644 --- a/userspace/units/Makefile.units.common.tmk +++ b/userspace/units/Makefile.units.common.tmk @@ -58,10 +58,13 @@ NV_COMPONENT_CFLAGS += \ -DCONFIG_SUPPORT_PMU_PSTATE \ -DCONFIG_TEGRA_NVLINK - NV_COMPONENT_NEEDED_INTERFACE_DIRS := \ $(NV_SOURCE)/kernel/nvgpu/userspace +ifdef NVGPU_UNIT_SHARED_LIBRARIES +NV_COMPONENT_SYSTEM_SHARED_LIBRARIES += $(NVGPU_UNIT_SHARED_LIBRARIES) +endif + ifdef NVGPU_UNIT_INTERFACE_DIRS NV_COMPONENT_NEEDED_INTERFACE_DIRS += \ $(NVGPU_UNIT_INTERFACE_DIRS)