let header_file be what's inside the <> of a #include
let search_paths be the header search paths build setting
plus come search paths compiled into gcc (eg /usr/include)
loop for each path in search_paths
let candidate_path be path + "/" + header_file
if candidate_path exists
replace the #include <> with the contents of candidate_path
while recursively applying this procedure to any #include
in the replacement content
exit the procedure
end if
end loop
report that the header file was not found