-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathKbuild
More file actions
32 lines (27 loc) · 852 Bytes
/
Kbuild
File metadata and controls
32 lines (27 loc) · 852 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
#
# Copyright (c) 2021 Nicholas Fraser
#
# This program is dual licensed under the terms of the MIT license OR the GNU
# General Public License version 2, your choice.
#
# This program is distributed WITHOUT ANY WARRANTY; without even the implied
# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# attached licenses for details.
#
ifeq ($(wildcard $(src)/mpack/src/mpack/mpack.h),)
$(error "You must checkout mpack/ here (or symlink the mpack repository.)")
endif
obj-m = mpack-tests.o
SRCS := $(shell cd $(src) && ls mpack/src/mpack/*.c)
SRCS += $(shell cd $(src) && ls mpack/test/unit/src/*.c)
SRCS += mpack-shim.c
mpack-tests-y := \
$(patsubst %.c, %.o, $(SRCS))
ccflags-y := \
-Os \
-Werror \
-I$(src) \
-I$(src)/mpack/src \
-I$(src)/mpack/test/unit/src \
-include mpack-tests-kernel.h \
-DMPACK_HAS_CONFIG=1