diff options
Diffstat (limited to 'userspace/Makefile')
-rw-r--r-- | userspace/Makefile | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/userspace/Makefile b/userspace/Makefile index 1483aa24..7ce5179d 100644 --- a/userspace/Makefile +++ b/userspace/Makefile | |||
@@ -39,14 +39,18 @@ CORE_OUT=$(OUT)/nvgpu_unit_core | |||
39 | # Nvgpu driver code. | 39 | # Nvgpu driver code. |
40 | NVGPU_SRC=$(TWD)/../drivers/gpu/nvgpu | 40 | NVGPU_SRC=$(TWD)/../drivers/gpu/nvgpu |
41 | NVGPU_OUT=$(OUT)/libnvgpu | 41 | NVGPU_OUT=$(OUT)/libnvgpu |
42 | # Nvgpu_next driver code. | ||
43 | NVGPU_NEXT_SRC=$(TWD)/../../nvgpu-next/drivers/gpu/nvgpu | ||
42 | 44 | ||
43 | # Unit tests themselves. | 45 | # Unit tests themselves. |
44 | UNIT_SRC=$(TWD)/units | 46 | UNIT_SRC=$(TWD)/units |
45 | UNIT_OUT=$(OUT)/units | 47 | UNIT_OUT=$(OUT)/units |
46 | 48 | ||
47 | INCLUDES= \ | 49 | INCLUDES= \ |
48 | -I$(NVGPU_SRC) \ | 50 | -I$(NVGPU_SRC) \ |
49 | -I$(NVGPU_SRC)/include \ | 51 | -I$(NVGPU_SRC)/include \ |
52 | -I$(NVGPU_NEXT_SRC) \ | ||
53 | -I$(NVGPU_NEXT_SRC)/include \ | ||
50 | -I$(TWD)/../include \ | 54 | -I$(TWD)/../include \ |
51 | -I$(TWD)/../include/uapi \ | 55 | -I$(TWD)/../include/uapi \ |
52 | -I$(TWD)/include | 56 | -I$(TWD)/include |
@@ -107,6 +111,14 @@ $(NVGPU_OUT)/%.o : $(NVGPU_SRC)/%.c $(HEADERS) | |||
107 | fi | 111 | fi |
108 | $(CC) --coverage $(CFLAGS) $(configs) -c -o $@ $< | 112 | $(CC) --coverage $(CFLAGS) $(configs) -c -o $@ $< |
109 | 113 | ||
114 | # Default build target for all the nvgpu-next driver object files we want to | ||
115 | # build in userspace. These too get bundled into libnvgpu-drv.so. | ||
116 | $(NVGPU_OUT)/%.o : $(NVGPU_NEXT_SRC)/%.c $(HEADERS) $(HEADERS_NEXT) | ||
117 | @if [ ! -d $(dir $@) ] ; then \ | ||
118 | mkdir -p $(dir $@) ; \ | ||
119 | fi | ||
120 | $(CC) --coverage $(CFLAGS) $(configs) -c -o $@ $< | ||
121 | |||
110 | # Build target for unit test files. These are not part of the libnvgpu-drv.so. | 122 | # Build target for unit test files. These are not part of the libnvgpu-drv.so. |
111 | # These comprise the unit test framework. | 123 | # These comprise the unit test framework. |
112 | $(CORE_OUT)/%.o : $(CORE_SRC)/%.c $(CORE_HEADERS) | 124 | $(CORE_OUT)/%.o : $(CORE_SRC)/%.c $(CORE_HEADERS) |