mirror of
https://github.com/chipsec/chipsec
synced 2026-06-08 13:31:00 +00:00
643306766e
Since Linux 5.15 (commit https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=e1f86d7b4b2a5213b012c2b4fe3e5b6ad537686e ), `make` now warns about missing `FORCE` prerequisite: /var/lib/dkms/chipsec/1.8.1/build/Makefile:39: FORCE prerequisite is missing Fix this issue by adding the required prerequisite. Signed-off-by: Nicolas Iooss <nicolas.iooss_git@polytechnique.org>
40 lines
871 B
Makefile
40 lines
871 B
Makefile
DESTDIR =
|
|
MODDIR = $(DESTDIR)/lib/modules
|
|
KVERS = $(shell uname -r)
|
|
KVER = $(KVERS)
|
|
VMODDIR = $(MODDIR)/$(KVER)
|
|
KSRC ?= $(VMODDIR)/build
|
|
|
|
obj-m += chipsec.o
|
|
chipsec-objs-y := chipsec_km.o
|
|
chipsec-objs-$(CONFIG_X86_32) += i386/cpu.o
|
|
chipsec-objs-$(CONFIG_X86_64) += amd64/cpu.o
|
|
chipsec-objs := $(chipsec-objs-y)
|
|
|
|
quiet_cmd_nasm32 = NASM_32 $@
|
|
cmd_nasm32 = nasm -f elf32 -o $@ $<
|
|
|
|
quiet_cmd_nasm64 = NASM_64 $@
|
|
cmd_nasm64 = nasm -f elf64 -o $@ $<
|
|
|
|
|
|
all: chipsec
|
|
|
|
check_kernel_dir:
|
|
@if [ ! -d $(KSRC) ]; then \
|
|
echo "Unable to find the Linux source tree."; \
|
|
exit 1; \
|
|
fi
|
|
|
|
chipsec: check_kernel_dir clean
|
|
make -C $(KSRC) M=$(CURDIR) modules
|
|
|
|
clean: check_kernel_dir
|
|
make -C $(KSRC) M=$(CURDIR) clean
|
|
|
|
$(obj)/i386/cpu.o: $(src)/i386/cpu.asm FORCE
|
|
$(call if_changed,nasm32)
|
|
|
|
$(obj)/amd64/cpu.o: $(src)/amd64/cpu.asm FORCE
|
|
$(call if_changed,nasm64)
|