Revert "Revert "Corrected the build issues""

This reverts commit 9a01b23b63e0275cc5159b0e9b33ec4d3c2ab8fd.