程式語言 - GNU - Makefile EXTRA_CFLAGS



用法如下:

obj-m:= main.o
KERNEL_DIR = xxx

all:
    make EXTRA_CFLAGS=-DDEMO -C $(KERNEL_DIR) M=$(PWD) modules

clean:
    make EXTRA_CFLAGS=-DDEMO -C $(KERNEL_DIR) M=$(PWD) clean