KBUILD: Allow generalization of "unifdef" utility.
PATCH 1/1 KBUILD: Allow generalization of "unifdef" utility.
Allow the user to override the selection of "unifdef" utility when generating user-space header files. This allows the user to select the more powerful "sunifdef" program, which is more stringent with respect to cleaning and syntax checking.
---
obviously, if a user chooses to not take advantage of this feature,
it should make no difference whatsoever. but "sunifdef" is more strict in terms of cleaning compound preprocessor directives, and it also flags questionable preprocessor directives like this:
UNIFDEF include/linux/netlink.h
sunifdef: /home/rpjday/k/git/include/linux/netlink.h: line 206:
warning 0x02070: Garbage following preprocessor directive in "#if PAGE_SIZE < 8192UL" (#if line 152 depth 2)
scripts/Makefile.headersinst +2 -1
@@ -7,7 +7,8 @@ # # ========================================================================== -UNIFDEF := scripts/unifdef -U__KERNEL__ +UNIFDEF_CMD ?= scripts/unifdef +UNIFDEF := $(UNIFDEF_CMD) -U__KERNEL__ # Eliminate the contents of (and inclusions of) compiler.h HDRSED := sed -e "s/ inline / __inline__ /g" \
========================================================================
Robert P. J. Day
Linux Consulting, Training and Annoying Kernel Pedantry:
Have classroom, will lecture.
http://crashcourse.ca Waterloo, Ontario, CANADA
========================================================================