Github #275 Generate versionned libraries

 * Improved parsing of the ArmNN's version at compile time
 * Reading the version directly from the Version.hpp file, to
   make sure not to break any build made with a different
   build system than CMake (or Ninja)
 * The version macro is set in the Version.hpp just like before,
   so setting it from the command line is no longer necessary

!android-nn-driver:2126

Signed-off-by: Guillaume Gardet <guillaume.gardet@arm.com>
Signed-off-by: Matteo Martincigh <matteo.martincigh@arm.com>
Change-Id: I0820094607734d283ded030e4ded0ae6f5889c86
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 3ad2eb3..e2712dd 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -96,6 +96,7 @@
 
     target_link_libraries(armnnCaffeParser armnn)
     target_link_libraries(armnnCaffeParser ${PROTOBUF_LIBRARIES})
+    set_target_properties(armnnCaffeParser PROPERTIES VERSION ${GENERIC_LIB_VERSION} SOVERSION ${GENERIC_LIB_SOVERSION})
 
 endif()
 
@@ -120,6 +121,7 @@
 
     # Protobuf
     target_link_libraries(armnnOnnxParser ${PROTOBUF_LIBRARIES})
+    set_target_properties(armnnOnnxParser PROPERTIES VERSION ${GENERIC_LIB_VERSION} SOVERSION ${GENERIC_LIB_SOVERSION})
 endif()
 
 if(BUILD_TF_PARSER)
@@ -143,6 +145,7 @@
 
     # Protobuf (use the specific version tensorflow wants)
     target_link_libraries(armnnTfParser ${PROTOBUF_LIBRARIES})
+    set_target_properties(armnnTfParser PROPERTIES VERSION ${GENERIC_LIB_VERSION} SOVERSION ${GENERIC_LIB_SOVERSION})
 endif()
 
 if(BUILD_ARMNN_QUANTIZER AND ARMNNREF)
@@ -201,6 +204,8 @@
         target_link_libraries(ArmnnQuantizer pthread)
     endif()
 
+    set_target_properties(ArmnnQuantizer PROPERTIES VERSION ${GENERIC_LIB_VERSION} SOVERSION ${GENERIC_LIB_SOVERSION})
+
 endif()
 
 
@@ -545,6 +550,8 @@
     target_link_libraries(armnn pthread)
 endif()
 
+set_target_properties(armnn PROPERTIES VERSION ${GENERIC_LIB_VERSION} SOVERSION ${GENERIC_LIB_SOVERSION})
+
 if(BUILD_UNIT_TESTS)
     set(unittest_sources)
     list(APPEND unittest_sources