diff --git a/core/tests/gateway_e2e/dependencies.cmake b/core/tests/gateway_e2e/dependencies.cmake index 46805baf..ed776331 100644 --- a/core/tests/gateway_e2e/dependencies.cmake +++ b/core/tests/gateway_e2e/dependencies.cmake @@ -6,12 +6,12 @@ include("../../../gatewayFunctions.cmake") ############################################################################### ###########################Find/Install/Build uamqp############################ ############################################################################### -findAndInstall(uamqp ${PROJECT_SOURCE_DIR}/deps/uamqp ${PROJECT_SOURCE_DIR}/deps/uamqp -Duse_installed_dependencies=ON -G "${CMAKE_GENERATOR}") +findAndInstall(uamqp 1.0.25 ${PROJECT_SOURCE_DIR}/deps/uamqp ${PROJECT_SOURCE_DIR}/deps/uamqp -Duse_installed_dependencies=ON -G "${CMAKE_GENERATOR}") ############################################################################### ###########################Find/Install/Build umqtt############################ ############################################################################### -findAndInstall(umqtt ${PROJECT_SOURCE_DIR}/deps/umqtt ${PROJECT_SOURCE_DIR}/deps/umqtt -Duse_installed_dependencies=ON -G "${CMAKE_GENERATOR}") +findAndInstall(umqtt 1.0.25 ${PROJECT_SOURCE_DIR}/deps/umqtt ${PROJECT_SOURCE_DIR}/deps/umqtt -Duse_installed_dependencies=ON -G "${CMAKE_GENERATOR}") ############################################################################### #######################Find/Install/Build azure_iot_sdks####################### @@ -36,4 +36,4 @@ if(NOT EXISTS ${PROJECT_SOURCE_DIR}/deps/iot-sdk-c/parson/README.md) message(FATAL_ERROR "Error pulling parson submodule: ${res}") endif() endif() -findAndInstall(azure_iot_sdks ${PROJECT_SOURCE_DIR}/deps/iot-sdk-c ${PROJECT_SOURCE_DIR}/deps/iot-sdk-c -Duse_installed_dependencies=ON -Dbuild_as_dynamic=ON -Drun_e2e_tests=ON -Duse_openssl=OFF -G "${CMAKE_GENERATOR}") +findAndInstall(azure_iot_sdks 1.1.5 ${PROJECT_SOURCE_DIR}/deps/iot-sdk-c ${PROJECT_SOURCE_DIR}/deps/iot-sdk-c -Duse_installed_dependencies=ON -Dbuild_as_dynamic=ON -Drun_e2e_tests=ON -Duse_openssl=OFF -G "${CMAKE_GENERATOR}") diff --git a/dependencies-test.cmake b/dependencies-test.cmake index 6b16d4dc..c2c0663d 100644 --- a/dependencies-test.cmake +++ b/dependencies-test.cmake @@ -6,14 +6,14 @@ include("gatewayFunctions.cmake") ############################################################################### ############################Find/Install/Build ctest########################### ############################################################################### -findAndInstall(ctest ${PROJECT_SOURCE_DIR}/deps/ctest ${PROJECT_SOURCE_DIR}/deps/ctest -G "${CMAKE_GENERATOR}") +findAndInstall(ctest 1.1.0 ${PROJECT_SOURCE_DIR}/deps/ctest ${PROJECT_SOURCE_DIR}/deps/ctest -G "${CMAKE_GENERATOR}") ############################################################################### #########################Find/Install/Build testrunner######################### ############################################################################### -findAndInstall(testrunnerswitcher ${PROJECT_SOURCE_DIR}/deps/testrunner ${PROJECT_SOURCE_DIR}/deps/testrunner -G "${CMAKE_GENERATOR}") +findAndInstall(testrunnerswitcher 1.1.0 ${PROJECT_SOURCE_DIR}/deps/testrunner ${PROJECT_SOURCE_DIR}/deps/testrunner -G "${CMAKE_GENERATOR}") ############################################################################### ###########################Find/Install/Build umock############################ ############################################################################### -findAndInstall(umock_c ${PROJECT_SOURCE_DIR}/deps/umock-c ${PROJECT_SOURCE_DIR}/deps/umock-c -Duse_installed_dependencies=ON -G "${CMAKE_GENERATOR}") \ No newline at end of file +findAndInstall(umock_c 1.1.0 ${PROJECT_SOURCE_DIR}/deps/umock-c ${PROJECT_SOURCE_DIR}/deps/umock-c -Duse_installed_dependencies=ON -G "${CMAKE_GENERATOR}") \ No newline at end of file diff --git a/dependencies.cmake b/dependencies.cmake index 7b85541e..d6da14cb 100644 --- a/dependencies.cmake +++ b/dependencies.cmake @@ -10,7 +10,7 @@ include("gatewayFunctions.cmake") ############################################################################### ###################Find/Install/Build azure_c_shared_utility################### ############################################################################### -findAndInstall(azure_c_shared_utility ${PROJECT_SOURCE_DIR}/deps/c-utility ${PROJECT_SOURCE_DIR}/deps/c-utility -Duse_installed_dependencies=ON -Drun_unittests=${run_unittests} -Dbuild_as_dynamic=ON -G "${CMAKE_GENERATOR}") +findAndInstall(azure_c_shared_utility 1.0.25 ${PROJECT_SOURCE_DIR}/deps/c-utility ${PROJECT_SOURCE_DIR}/deps/c-utility -Duse_installed_dependencies=ON -Drun_unittests=${run_unittests} -Dbuild_as_dynamic=ON -G "${CMAKE_GENERATOR}") set(SHARED_UTIL_INC_FOLDER ${AZURE_C_SHARED_UTILITY_INCLUDE_DIR} CACHE INTERNAL "this is what needs to be included if using sharedLib lib" FORCE) set(SHARED_UTIL_LIB_FOLDER ${AZURE_C_SHARED_LIBRARY_DIR} CACHE INTERNAL "this is what needs to be included if using sharedLib lib" FORCE) set(SHARED_UTIL_LIB aziotsharedutil CACHE INTERNAL "this is what needs to be included if using sharedLib lib" FORCE) diff --git a/gatewayFunctions.cmake b/gatewayFunctions.cmake index aea1fbf4..ca33f6ac 100644 --- a/gatewayFunctions.cmake +++ b/gatewayFunctions.cmake @@ -65,10 +65,10 @@ function(findAndInstallNonFindPkg libraryName submoduleRootDirectory cmakeRootDi endfunction() #Additional arguments to the specific projects cmake command may be specified after specifying the cmakeRootDirectory -function(findAndInstall libraryName submoduleRootDirectory cmakeRootDirectory) +function(findAndInstall libraryName version submoduleRootDirectory cmakeRootDirectory) if(NOT ${libraryName}_FOUND) - find_package(${libraryName} QUIET CONFIG HINTS ${dependency_install_prefix}) + find_package(${libraryName} ${version} QUIET CONFIG HINTS ${dependency_install_prefix}) if(NOT ${libraryName}_FOUND) message(STATUS "${libraryName} not found...") message(STATUS "Building ${libraryName}...") @@ -124,7 +124,7 @@ function(findAndInstall libraryName submoduleRootDirectory cmakeRootDirectory) endif() #Attempt to find library with the REQUIRED option - find_package(${libraryName} REQUIRED CONFIG HINTS ${dependency_install_prefix}) + find_package(${libraryName} ${version} REQUIRED CONFIG HINTS ${dependency_install_prefix}) endif() endif() diff --git a/modules/dependencies.cmake b/modules/dependencies.cmake index b7aae45f..df5affd2 100644 --- a/modules/dependencies.cmake +++ b/modules/dependencies.cmake @@ -6,12 +6,12 @@ include("../gatewayFunctions.cmake") ############################################################################### ###########################Find/Install/Build uamqp############################ ############################################################################### -findAndInstall(uamqp ${PROJECT_SOURCE_DIR}/deps/uamqp ${PROJECT_SOURCE_DIR}/deps/uamqp -Duse_installed_dependencies=ON -G "${CMAKE_GENERATOR}") +findAndInstall(uamqp 1.0.25 ${PROJECT_SOURCE_DIR}/deps/uamqp ${PROJECT_SOURCE_DIR}/deps/uamqp -Duse_installed_dependencies=ON -G "${CMAKE_GENERATOR}") ############################################################################### ###########################Find/Install/Build umqtt############################ ############################################################################### -findAndInstall(umqtt ${PROJECT_SOURCE_DIR}/deps/umqtt ${PROJECT_SOURCE_DIR}/deps/umqtt -Duse_installed_dependencies=ON -G "${CMAKE_GENERATOR}") +findAndInstall(umqtt 1.0.25 ${PROJECT_SOURCE_DIR}/deps/umqtt ${PROJECT_SOURCE_DIR}/deps/umqtt -Duse_installed_dependencies=ON -G "${CMAKE_GENERATOR}") ############################################################################### #######################Find/Install/Build azure_iot_sdks####################### @@ -36,4 +36,4 @@ if(NOT EXISTS ${PROJECT_SOURCE_DIR}/deps/iot-sdk-c/parson/README.md) message(FATAL_ERROR "Error pulling parson submodule: ${res}") endif() endif() -findAndInstall(azure_iot_sdks ${PROJECT_SOURCE_DIR}/deps/iot-sdk-c ${PROJECT_SOURCE_DIR}/deps/iot-sdk-c -Duse_installed_dependencies=ON -Duse_openssl=OFF -Dbuild_as_dynamic=ON -Drun_e2e_tests=ON -G "${CMAKE_GENERATOR}") +findAndInstall(azure_iot_sdks 1.1.5 ${PROJECT_SOURCE_DIR}/deps/iot-sdk-c ${PROJECT_SOURCE_DIR}/deps/iot-sdk-c -Duse_installed_dependencies=ON -Duse_openssl=OFF -Dbuild_as_dynamic=ON -Drun_e2e_tests=ON -G "${CMAKE_GENERATOR}")