Android:CMake: Add argument to bundle OpenSSL libs for internal tests
The new argument would allow bundling the prebuilt OpenSSL libs into the test apk so that SSL can actually run. It expects the CMake argument OPENSSL_ROOT_DIR to be set ( we set that in Coin configs). Task-number: QTBUG-110025 Pick-to: 6.6 6.5 Change-Id: I4c82796635ca89f5511255ae26182f41a504b026 Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>bb10
parent
937751f427
commit
9d5a8162a5
|
|
@ -214,6 +214,7 @@ function(qt_internal_get_test_arg_definitions optional_args single_value_args mu
|
|||
MANUAL
|
||||
NO_BATCH
|
||||
NO_INSTALL
|
||||
BUNDLE_ANDROID_OPENSSL_LIBS
|
||||
PARENT_SCOPE
|
||||
)
|
||||
set(${single_value_args}
|
||||
|
|
@ -579,6 +580,15 @@ function(qt_internal_add_test name)
|
|||
endif()
|
||||
|
||||
if (ANDROID)
|
||||
if(arg_BUNDLE_ANDROID_OPENSSL_LIBS)
|
||||
if(NOT OPENSSL_ROOT_DIR)
|
||||
message(FATAL_ERROR "The argument BUNDLE_ANDROID_OPENSSL_LIBS is set "
|
||||
"but OPENSSL_ROOT_DIR parameter is not set.")
|
||||
endif()
|
||||
set_property(TARGET ${name} APPEND PROPERTY QT_ANDROID_EXTRA_LIBS
|
||||
"${OPENSSL_ROOT_DIR}/${CMAKE_ANDROID_ARCH_ABI}/libcrypto_3.so"
|
||||
"${OPENSSL_ROOT_DIR}/${CMAKE_ANDROID_ARCH_ABI}/libssl_3.so")
|
||||
endif()
|
||||
qt_internal_android_test_arguments("${name}" test_executable extra_test_args)
|
||||
set(test_working_dir "${CMAKE_CURRENT_BINARY_DIR}")
|
||||
elseif(QNX)
|
||||
|
|
|
|||
Loading…
Reference in New Issue