Something went wrong. Try again.
(I'm so sorry!) Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
Something went wrong. Try again.
781 B · 30 lines
Makefile
at master
12345678910111213141516171819202122232425262728293031# SPDX-License-Identifier: GPL-2.0# Makefile for bootconfig commandinclude ../scripts/Makefile.include
bindir ?= /usr/bin
ifeq ($(srctree),)srctree := $(patsubst %/,%,$(dir $(CURDIR)))srctree := $(patsubst %/,%,$(dir $(srctree)))endif
LIBSRC = $(srctree)/lib/bootconfig.c $(srctree)/include/linux/bootconfig.hoverride CFLAGS += -Wall -g -I$(CURDIR)/include
ALL_TARGETS := bootconfigALL_PROGRAMS := $(patsubst %,$(OUTPUT)%,$(ALL_TARGETS))
all: $(ALL_PROGRAMS)
$(OUTPUT)bootconfig: main.c include/linux/bootconfig.h $(LIBSRC) $(CC) $(filter %.c,$^) $(CFLAGS) $(LDFLAGS) -o $@
test: $(ALL_PROGRAMS) test-bootconfig.sh ./test-bootconfig.sh $(OUTPUT)
install: $(ALL_PROGRAMS) install $(OUTPUT)bootconfig $(DESTDIR)$(bindir)
clean: rm -f $(OUTPUT)*.o $(ALL_PROGRAMS)