Fix overaly build issues

Re-picked after Slim rebase

Change-Id: I23f39dd33ad61281e73b1c1f5169a094b8a715db
Merge "Fix overaly build issues" into lp5.0