The build completed successfully with all the flags I posted above.
This must have been some error on my side. It might have been because of a conflict with a previous installation - which I removed before performing this build (but, I did not source those files from my bashrc and they were simply present in my system in /usr/ so I am not sure why this error occurred).
Anyhow it is working perfectly now and all is good
Thanks.