Fixed compiling issues for the targets