message: Check for LLVM 4.0 specifically - don't compile against 5.0
diff: @@ -357,9 +357,15 @@ endif()
  find_package(LLVM CONFIG)
  +set(HAVE_INTERCEPTOR_LIB OFF)
  +
  # on Android, pull in interceptor-lib only if we have LLVM available
  if(ANDROID AND LLVM_FOUND)
  - message(STATUS "LLVM found - android hooking using interceptor-lib.")
  + if(${LLVM_PACKAGE_VERSION} VERSION_LESS "4.0.0" OR ${LLVM_PACKAGE_VERSION} VERSION_GREATER "4.0.1")
  + message(STATUS "LLVM ${LLVM_PACKAGE_VERSION} found - we require precisely 4.0.")
  + else()
  + message(STATUS "LLVM ${LLVM_PACKAGE_VERSION} found - enabling android hooking using interceptor-lib.")
  + set(HAVE_INTERCEPTOR_LIB ON)
  add_subdirectory(3rdparty/interceptor-lib)
  list(APPEND renderdoc_objects $<TARGET_OBJECTS:interceptor_lib>)
  link_directories(${LLVM_DIR}/../..)
  @@ -369,8 +375,9 @@ if(ANDROID AND LLVM_FOUND)
  list(APPEND RDOC_LIBRARIES PRIVATE -l${lib})
  endforeach()
  endif()
  +endif()
  -if(ANDROID AND NOT LLVM_FOUND)
  +if(ANDROID AND NOT HAVE_INTERCEPTOR_LIB)
  message(STATUS "LLVM not found - android hooking will use sometimes less reliable PLT-interception method.")
  endif()
  