On Sat, 2012-11-03 at 20:38 -0600, reg(a)dwf.com wrote:
How do I find the definition of a string in /usr/include?
OK, there has got to be a better way to do this than with find and
grep (which isnt working).
What do you mean they aren't working?
BUT how does one find the definition
of a string in /usr/include ???
In particular, I KNOW that month is defined SOMEWHERE, but Im
not finding in in the obvious (to me) places.
So how do I find 'Mo' or perhaps better yet 'Mo[' in /usr incude?
So which is it? month? MO? Mo[?
This finds definitions that include "month" (case-independently),
provided that the word is on the same line as the #define:
find /usr/include -type f|xargs grep -i "#[[:space:]]*define.*month"
poc