Skip to content

Use the Homebrew package manager to easily install include-what-you-use

License

Notifications You must be signed in to change notification settings

timo0/homebrew-iwyu

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

60 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Homebrew IWYU

Build Status Release License

This formula makes it easy to install include-what-you-use on any modern OS X system.

Just brew tap jasonmp85/iwyu and then brew install iwyu.

Using iwyu

The project's page goes into more detail, but there are three basic ways to use iwyu

Directly

Invoke it on a single file, as you would a compiler: iwyu hello_world.c. Messages about what includes to add or remove will be printed to standard output.

From make

Tell make to use it as the C compiler: make -k CC=iwyu. It's necessary to use the -k flag to continue after errors (iwyu always errors to signal that no compilation has actually taken place).

Using fix_include

include-what-you-use bundles a Python script capable of parsing its output in order to automatically fix any include problems, in-place if you desire. It's not perfect, but something like fix_include hello_world.c < iwyu hello_world.c should work to update a file named hello_world.c with the suggestions made by iwyu.

Copyright

Copyright © 2014–2016 Jason Petersen

Code released under the MIT License.

About

Use the Homebrew package manager to easily install include-what-you-use

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Ruby 100.0%