Makefile: add target for Include What You Use (iwyu)

Requires http://include-what-you-use.org/ and Clang to operate.
Doesn't quite work for the builtin_* collection; that has to be done by
hand.
This commit is contained in:
David Adam 2015-07-29 21:41:57 +08:00
parent 75515af537
commit 299a383d98
2 changed files with 11 additions and 0 deletions

View file

@ -828,6 +828,13 @@ depend:
./config.status
.PHONY: depend
# Include What You Use
iwyu:
# Requires the --keep-going flag as it always returns 1
# Can't set MAKEFLAGS on a target-specific basic
$(MAKE) -k _iwyu CXX=include-what-you-use
_iwyu: clean $(PROGRAMS)
.PHONY: iwyu _iwyu
#
# Cleanup targets

4
build_tools/iwyu.sh Executable file
View file

@ -0,0 +1,4 @@
#!/bin/sh
# Reminder of how to run Include What You Use
make iwyu