Add possibility to build with or without CLI features

Export library
USE_CLI ON by default

Build all the dependencies only if USE_CLI is ON