find can do what you want when used with the
exec action.
If the GNU documentation is on your system you can get even more details and examples with:
As an example, I chose not to move any files because I don't know anything about your system. Instead, I'll show one way to find all C source files from the current directory down which use the SDL libraries.
Code:
find -iname '*.c' -exec grep -q SDL '{}' ';' -print
Note that even though the above command should be quite harmless, there may be security concerns connected with the
exec action as explained in the GNU
find documentation.