Build: Some enhancements
Kudos to VanirAOSP

Change-Id: Ie8ef9a5e757156381bc072268e9749c0b5ce7d5f