diff --git a/src/templates/c/kernel_module/Makefile.tmpl b/src/templates/c/kernel_module/Makefile.tmpl index 4cb6f3d..0508f10 100644 --- a/src/templates/c/kernel_module/Makefile.tmpl +++ b/src/templates/c/kernel_module/Makefile.tmpl @@ -8,7 +8,7 @@ else DEBFLAGS = -O2 endif -CFLAGS += $(DEBFLAGS) -I$(LDDINCDIR) +EXTRA_CFLAGS += $(DEBFLAGS) -I$(LDDINCDIR) ifneq ($(KERNELRELEASE),) # call from kernel build system @@ -31,7 +31,7 @@ clean: rm -rf *.o *~ core .depend .*.cmd *.ko *.mod.c .tmp_versions depend .depend dep: - $(CC) $(CFLAGS) -M *.c > .depend + $(CC) $(CFLAGS) $(EXTRA_CFLAGS) -M *.c > .depend ifeq (.depend,$(wildcard .depend)) diff --git a/src/templates/c/kernel_module/__project__.c.tmpl b/src/templates/c/kernel_module/__project__.c.tmpl index edb476f..950b676 100644 --- a/src/templates/c/kernel_module/__project__.c.tmpl +++ b/src/templates/c/kernel_module/__project__.c.tmpl @@ -10,17 +10,17 @@ MODULE_AUTHOR("::author:: <::email::>"); MODULE_DESCRIPTION("::desc::"); -static int __init module_init(void) +static int __init module_initial(void) { printk(KERN_ALERT "Hello, world\n"); return 0; } -static void module_exit(void) +static void module_cleanup(void) { printk(KERN_ALERT "Goodbye, cruel world\n"); } -module_init(module_init); -module_exit(module_exit); +module_init(module_initial); +module_exit(module_cleanup);