Closed yunhaoling closed 1 year ago
Hey, I have problem installing azure-servicebus due to error with uamqp and openssl. do you have any timeline for a fix?
@andrea-cassioli-maersk thank you for reaching, can you outline the error message that you are seeing ? are you able to install using source pip install uamqp --no-binary :all
I am installing azure-servicebus
in a linux alpine docker image and I get (with and without no-binary
)
[ 51%] Building C object deps/azure-c-shared-utility/CMakeFiles/aziotsharedutil.dir/adapters/tlsio_openssl.c.o
#9 34.09 /tmp/pip-req-build-db97a2wi/src/vendor/azure-uamqp-c/deps/azure-c-shared-utility/adapters/tlsio_openssl.c: In function 'engine_destroy':
#9 34.09 /tmp/pip-req-build-db97a2wi/src/vendor/azure-uamqp-c/deps/azure-c-shared-utility/adapters/tlsio_openssl.c:762:9: error: 'ENGINE_free' is deprecated: Since OpenSSL 3.0 [-Werror=deprecated-declarations]
#9 34.09 762 | ENGINE_free(tls->engine); // Release structural reference.
#9 34.09 | ^~~~~~~~~~~
#9 34.09 In file included from /tmp/pip-req-build-db97a2wi/src/vendor/azure-uamqp-c/deps/azure-c-shared-utility/adapters/tlsio_openssl.c:9:
#9 34.09 /usr/include/openssl/engine.h:493:27: note: declared here
#9 34.09 493 | OSSL_DEPRECATEDIN_3_0 int ENGINE_free(ENGINE *e);
#9 34.09 | ^~~~~~~~~~~
#9 34.09 /tmp/pip-req-build-db97a2wi/src/vendor/azure-uamqp-c/deps/azure-c-shared-utility/adapters/tlsio_openssl.c: In function 'engine_load':
#9 34.09 /tmp/pip-req-build-db97a2wi/src/vendor/azure-uamqp-c/deps/azure-c-shared-utility/adapters/tlsio_openssl.c:772:5: error: 'ENGINE_by_id' is deprecated: Since OpenSSL 3.0 [-Werror=deprecated-declarations]
#9 34.09 772 | tls->engine = ENGINE_by_id(tls->engine_id);
#9 34.09 | ^~~
#9 34.09 /usr/include/openssl/engine.h:336:31: note: declared here
#9 34.09 336 | OSSL_DEPRECATEDIN_3_0 ENGINE *ENGINE_by_id(const char *id);
#9 34.09 | ^~~~~~~~~~~~
#9 34.09 /tmp/pip-req-build-db97a2wi/src/vendor/azure-uamqp-c/deps/azure-c-shared-utility/adapters/tlsio_openssl.c: In function 'add_certificate_to_store':
#9 34.09 /tmp/pip-req-build-db97a2wi/src/vendor/azure-uamqp-c/deps/azure-c-shared-utility/adapters/tlsio_openssl.c:961:24: error: assignment discards 'const' qualifier from pointer target type [-Werror=discarded-qualifiers]
#9 34.09 961 | bio_method = BIO_s_mem();
#9 34.09 | ^
#9 34.09 /tmp/pip-req-build-db97a2wi/src/vendor/azure-uamqp-c/deps/azure-c-shared-utility/adapters/tlsio_openssl.c: In function 'create_openssl_instance':
#9 34.09 /tmp/pip-req-build-db97a2wi/src/vendor/azure-uamqp-c/deps/azure-c-shared-utility/adapters/tlsio_openssl.c:1058:9: error: 'TLSv1_2_method' is deprecated: Since OpenSSL 1.1.0 [-Werror=deprecated-declarations]
#9 34.09 1058 | method = TLSv1_2_method();
#9 34.09 | ^~~~~~
#9 34.09 In file included from /tmp/pip-req-build-db97a2wi/src/vendor/azure-uamqp-c/deps/azure-c-shared-utility/adapters/tlsio_openssl.c:5:
#9 34.09 /usr/include/openssl/ssl.h:2031:50: note: declared here
#9 34.09 2031 | OSSL_DEPRECATEDIN_1_1_0 __owur const SSL_METHOD *TLSv1_2_method(void); /* TLSv1.2 */
#9 34.09 | ^~~~~~~~~~~~~~
#9 34.09 /tmp/pip-req-build-db97a2wi/src/vendor/azure-uamqp-c/deps/azure-c-shared-utility/adapters/tlsio_openssl.c:1062:9: error: 'TLSv1_1_method' is deprecated: Since OpenSSL 1.1.0 [-Werror=deprecated-declarations]
#9 34.09 1062 | method = TLSv1_1_method();
#9 34.09 | ^~~~~~
#9 34.09 /usr/include/openssl/ssl.h:2023:50: note: declared here
#9 34.09 2023 | OSSL_DEPRECATEDIN_1_1_0 __owur const SSL_METHOD *TLSv1_1_method(void); /* TLSv1.1 */
#9 34.09 | ^~~~~~~~~~~~~~
#9 34.09 /tmp/pip-req-build-db97a2wi/src/vendor/azure-uamqp-c/deps/azure-c-shared-utility/adapters/tlsio_openssl.c:1066:9: error: 'TLSv1_method' is deprecated: Since OpenSSL 1.1.0 [-Werror=deprecated-declarations]
#9 34.09 1066 | method = TLSv1_method();
#9 34.09 | ^~~~~~
#9 34.09 /usr/include/openssl/ssl.h:2015:50: note: declared here
#9 34.09 2015 | OSSL_DEPRECATEDIN_1_1_0 __owur const SSL_METHOD *TLSv1_method(void); /* TLSv1.0 */
#9 34.09 | ^~~~~~~~~~~~
#9 34.09 /tmp/pip-req-build-db97a2wi/src/vendor/azure-uamqp-c/deps/azure-c-shared-utility/adapters/tlsio_openssl.c: In function 'tlsio_openssl_init':
#9 34.09 /tmp/pip-req-build-db97a2wi/src/vendor/azure-uamqp-c/deps/azure-c-shared-utility/adapters/tlsio_openssl.c:1224:5: error: 'ERR_load_BIO_strings' is deprecated: Since OpenSSL 3.0 [-Werror=deprecated-declarations]
#9 34.09 1224 | ERR_load_BIO_strings();
#9 34.09 | ^~~~~~~~~~~~~~~~~~~~
#9 34.09 In file included from /usr/include/openssl/cryptoerr.h:17,
#9 34.09 from /usr/include/openssl/crypto.h:38,
#9 34.09 from /usr/include/openssl/bio.h:30,
#9 34.09 from /usr/include/openssl/ssl.h:29:
#9 34.09 /usr/include/openssl/cryptoerr_legacy.h:31:27: note: declared here
#9 34.09 31 | OSSL_DEPRECATEDIN_3_0 int ERR_load_BIO_strings(void);
#9 34.09 | ^~~~~~~~~~~~~~~~~~~~
#9 34.09 /tmp/pip-req-build-db97a2wi/src/vendor/azure-uamqp-c/deps/azure-c-shared-utility/adapters/tlsio_openssl.c: In function 'tlsio_openssl_deinit':
#9 34.09 /tmp/pip-req-build-db97a2wi/src/vendor/azure-uamqp-c/deps/azure-c-shared-utility/adapters/tlsio_openssl.c:1252:5: error: 'ERR_remove_thread_state' is deprecated: Since OpenSSL 1.1.0 [-Werror=deprecated-declarations]
#9 34.09 1252 | ERR_remove_thread_state(NULL);
#9 34.09 | ^~~~~~~~~~~~~~~~~~~~~~~
#9 34.09 In file included from /tmp/pip-req-build-db97a2wi/src/vendor/azure-uamqp-c/deps/azure-c-shared-utility/adapters/tlsio_openssl.c:6:
#9 34.09 /usr/include/openssl/err.h:485:30: note: declared here
#9 34.09 485 | OSSL_DEPRECATEDIN_1_1_0 void ERR_remove_thread_state(void *);
#9 34.09 | ^~~~~~~~~~~~~~~~~~~~~~~
#9 34.09 /tmp/pip-req-build-db97a2wi/src/vendor/azure-uamqp-c/deps/azure-c-shared-utility/adapters/tlsio_openssl.c: In function 'tlsio_openssl_setoption':
#9 34.09 /tmp/pip-req-build-db97a2wi/src/vendor/azure-uamqp-c/deps/azure-c-shared-utility/adapters/tlsio_openssl.c:1724:13: error: 'ENGINE_load_builtin_engines' is deprecated: Since OpenSSL 3.0 [-Werror=deprecated-declarations]
#9 34.09 1724 | ENGINE_load_builtin_engines();
#9 34.09 | ^~~~~~~~~~~~~~~~~~~~~~~~~~~
#9 34.09 /usr/include/openssl/engine.h:358:28: note: declared here
#9 34.09 358 | OSSL_DEPRECATEDIN_3_0 void ENGINE_load_builtin_engines(void);
#9 34.09 | ^~~~~~~~~~~~~~~~~~~~~~~~~~~
#9 34.09 cc1: all warnings being treated as errors
#9 34.09 make[2]: *** [deps/azure-c-shared-utility/CMakeFiles/aziotsharedutil.dir/build.make:790: deps/azure-c-shared-utility/CMakeFiles/aziotsharedutil.dir/adapters/tlsio_openssl.c.o] Error 1
#9 34.09 make[1]: *** [CMakeFiles/Makefile2:943: deps/azure-c-shared-utility/CMakeFiles/aziotsharedutil.dir/all] Error 2
#9 34.09 make: *** [Makefile:146: all] Error 2
I can build successfully if I switch to open-ssl1.1. But it is a bit of a bummer.
@andrea-cassioli-maersk just wanted to provide an update that this week we will be releasing a new version of the service bus client that uses the pure python AMQP library. Its backwards compatible and will work on Alpine etc.
Thanks @kashifkhan much appreciated!
@andrea-cassioli-maersk its published now
This is a reminder to:
uamqp uses openssl for wheels of macos/manylinux (windows uses schannel)