Though this question has an answer, I resolved it differently when I had the same issue. I had this issue when I copied folders with the option Create Folder references
; then the above solution of adding the folder to the build_path worked.
But when the folder was added using the Create groups for any added folder
option, the headers were picked up automatically.