Fix requirements mentioned in Readme.

Refactor CMakeLists.txt to have additional packaging options.
Moved all packaging options to package/CMakeLists.txt
Fix build system error when trying to create a package and documentation
was disabled.
Fix sphinx build error in API section.