Назад | Перейти на главную страницу

pip3 install wsgi не может найти библиотеки openssl в QNAP

При попытке установить uwsgi через pip3, он не может найти некоторые openssl библиотеки, хотя я думаю, что они установлены. В аналогичных случаях рекомендуется установить libssl-dev, но менеджер пакетов, который я использую (entware) его нет.

Моя Linux-версия:

QTS 4.3 (embedded Linux)

Когда я бегу openssl help, отображаются все его команды, поэтому его необходимо установить. Хотя я смог найти только openssl.so в папке веб-сервера apache:

[/] # find . -name openssl.so* дает:

./mnt/ext/opt/apache/modules/openssl.so

Когда я бегу [/] # find . -name openssl.so*, он возвращает:

./mnt/ext/opt/apache/modules/openssl.so

libssl тоже вроде бы установлено:

[/] # find . -name libssl.so* дает:

./share/CACHEDEV2_DATA/.qpkg/Entware-ng/lib/libssl.so.1.1
./lib/libssl.so
./lib/libssl.so.0
./lib/libssl.so.1.0.0

Так же как libcrypto:

find . -name libcrypto.so* дает:

./usr/lib/libcrypto.so.0
./usr/lib/libcrypto.so.1.0.0
./usr/lib/libcrypto.so
./usr/lib/libcrypto.so.6
./share/CACHEDEV2_DATA/.qpkg/Entware-ng/lib/libcrypto.so.1.1
./share/CACHEDEV2_DATA/.qpkg/Entware-ng/lib/libcrypto.so.1.0.0
./lib/libcrypto.so.1.0.0

Ошибка следующая:

 ERROR: Command errored out with exit status 1:
     command: /opt/bin/python3 -u -c 'import sys, setuptools, tokenize; sys.argv                                                                                                                                                                             [0] = '"'"'/share/CACHEDEV2_DATA/.qpkg/Entware-ng/tmp/pip-install-bl1wxksm/uwsgi                                                                                                                                                                             /setup.py'"'"'; __file__='"'"'/share/CACHEDEV2_DATA/.qpkg/Entware-ng/tmp/pip-ins                                                                                                                                                                             tall-bl1wxksm/uwsgi/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__fi                                                                                                                                                                             le__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile                                                                                                                                                                             (code, __file__, '"'"'exec'"'"'))' install --record /share/CACHEDEV2_DATA/.qpkg/                                                                                                                                                                             Entware-ng/tmp/pip-record-__6aj81m/install-record.txt --single-version-externall                                                                                                                                                                             y-managed --compile --install-headers /opt/include/python3.8/uwsgi
         cwd: /share/CACHEDEV2_DATA/.qpkg/Entware-ng/tmp/pip-install-bl1wxksm/uw                                                                                                                                                                             sgi/
    Complete output (184 lines):
    /dist.py:274: UserWarning: Unknown distribution option: 'descriptions'
    running install
    using profile: buildconf/default.ini
    detected include path: ['/share/CACHEDEV2_DATA/.qpkg/Entware-ng/bin/../lib/g                                                                                                                                                                             cc/arm-openwrt-linux-gnueabi/7.4.0/include', '/share/CACHEDEV2_DATA/.qpkg/Entwar                                                                                                                                                                             e-ng/bin/../lib/gcc/arm-openwrt-linux-gnueabi/7.4.0/include-fixed', '/opt/includ                                                                                                                                                                             e']
    Patching "bin_name" to properly install_scripts dir
    detected CPU cores: 2
    configured CFLAGS: -O2 -I. -Wall -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64                                                                                                                                                                              -Wextra -Wno-unused-parameter -Wno-missing-field-initializers -DUWSGI_HAS_IFADDR                                                                                                                                                                             S -DUWSGI_ZLIB -DUWSGI_LOCK_USE_MUTEX -DUWSGI_EVENT_USE_EPOLL -DUWSGI_EVENT_TIME                                                                                                                                                                             R_USE_TIMERFD -DUWSGI_EVENT_FILEMONITOR_USE_INOTIFY -DUWSGI_CAP -DUWSGI_UUID -DU                                                                                                                                                                             WSGI_VERSION="\"2.0.18\"" -DUWSGI_VERSION_BASE="2" -DUWSGI_VERSION_MAJOR="0" -DU                                                                                                                                                                             WSGI_VERSION_MINOR="18" -DUWSGI_VERSION_REVISION="0" -DUWSGI_VERSION_CUSTOM="\"\                                                                                                                                                                             "" -DUWSGI_YAML -DUWSGI_JSON -DUWSGI_SSL -DUWSGI_XML -DUWSGI_XML_EXPAT -DUWSGI_P                                                                                                                                                                             LUGIN_DIR="\".\"" -DUWSGI_DECLARE_EMBEDDED_PLUGINS="UDEP(python);UDEP(gevent);UD                                                                                                                                                                             EP(ping);UDEP(cache);UDEP(nagios);UDEP(rrdtool);UDEP(carbon);UDEP(rpc);UDEP(core                                                                                                                                                                             router);UDEP(fastrouter);UDEP(http);UDEP(signal);UDEP(syslog);UDEP(rsyslog);UDEP                                                                                                                                                                             (logsocket);UDEP(router_uwsgi);UDEP(router_redirect);UDEP(router_basicauth);UDEP                                                                                                                                                                             (zergpool);UDEP(redislog);UDEP(mongodblog);UDEP(router_rewrite);UDEP(router_http                                                                                                                                                                             );UDEP(logfile);UDEP(router_cache);UDEP(rawrouter);UDEP(router_static);UDEP(sslr                                                                                                                                                                             outer);UDEP(spooler);UDEP(cheaper_busyness);UDEP(symcall);UDEP(transformation_to                                                                                                                                                                             file);UDEP(transformation_gzip);UDEP(transformation_chunked);UDEP(transformation                                                                                                                                                                             _offload);UDEP(router_memcached);UDEP(router_redis);UDEP(router_hash);UDEP(route                                                                                                                                                                             r_expires);UDEP(router_metrics);UDEP(transformation_template);UDEP(stats_pusher_                                                                                                                                                                             socket);" -DUWSGI_LOAD_EMBEDDED_PLUGINS="ULEP(python);ULEP(gevent);ULEP(ping);UL                                                                                                                                                                             EP(cache);ULEP(nagios);ULEP(rrdtool);ULEP(carbon);ULEP(rpc);ULEP(corerouter);ULE                                                                                                                                                                             P(fastrouter);ULEP(http);ULEP(signal);ULEP(syslog);ULEP(rsyslog);ULEP(logsocket)                                                                                                                                                                             ;ULEP(router_uwsgi);ULEP(router_redirect);ULEP(router_basicauth);ULEP(zergpool);                                                                                                                                                                             ULEP(redislog);ULEP(mongodblog);ULEP(router_rewrite);ULEP(router_http);ULEP(logf                                                                                                                                                                             ile);ULEP(router_cache);ULEP(rawrouter);ULEP(router_static);ULEP(sslrouter);ULEP                                                                                                                                                                             (spooler);ULEP(cheaper_busyness);ULEP(symcall);ULEP(transformation_tofile);ULEP(                                                                                                                                                                             transformation_gzip);ULEP(transformation_chunked);ULEP(transformation_offload);U                                                                                                                                                                             LEP(router_memcached);ULEP(router_redis);ULEP(router_hash);ULEP(router_expires);                                                                                                                                                                             ULEP(router_metrics);ULEP(transformation_template);ULEP(stats_pusher_socket);"
    *** uWSGI compiling server core ***
    [thread 1][arm-openwrt-linux-gnueabi-gcc] core/utils.o
    [thread 0][arm-openwrt-linux-gnueabi-gcc] core/protocol.o
    ... (could only use 30,000 characters for the post xD) ...
    [thread 0][arm-openwrt-linux-gnueabi-gcc] core/dot_h.o
    [thread 0][arm-openwrt-linux-gnueabi-gcc] core/config_py.o
    *** uWSGI compiling embedded plugins ***
    [thread 0][arm-openwrt-linux-gnueabi-gcc] plugins/python/python_plugin.o
    [thread 1][arm-openwrt-linux-gnueabi-gcc] plugins/python/pyutils.o
        ... (could only use 30,000 characters for the post xD) ...
    [thread 1][arm-openwrt-linux-gnueabi-gcc] plugins/syslog/syslog_plugin.o
    [thread 0][arm-openwrt-linux-gnueabi-gcc] plugins/redislog/redislog_plugin.o
    [thread 1][arm-openwrt-linux-gnueabi-gcc] plugins/mongodblog/mongodblog_plug                                                                                                                                                                             in.o
    plugins/redislog/redislog_plugin.c: In function 'uwsgi_redis_logger':
    plugins/redislog/redislog_plugin.c:162:62: warning: format '%lu' expects arg                                                                                                                                                                             ument of type 'long unsigned int', but argument 4 has type 'size_t {aka unsigned                                                                                                                                                                              int}' [-Wformat=]
           setup_buf, sizeof (setup_buf), "*2\r\n$4\r\nauth\r\n$%lu\r\n%*s\r\n",
                                                                ~~^
                                                                %u
           strlen(uredislog->password), (int)strlen(uredislog->password), uredis                                                                                                                                                                             log->password);
           ~~~~~~~~~~~~~~~~~~~~~~~~~~~
    plugins/redislog/redislog_plugin.c:175:64: warning: format '%lu' expects arg                                                                                                                                                                             ument of type 'long unsigned int', but argument 4 has type 'size_t {aka unsigned                                                                                                                                                                              int}' [-Wformat=]
           setup_buf, sizeof (setup_buf), "*2\r\n$6\r\nselect\r\n$%lu\r\n%*s\r\n                                                                                                                                                                             ",
                                                                  ~~^
                                                                  %u
                  strlen(uredislog->id), (int)strlen(uredislog->id), uredislog->                                                                                                                                                                             id);
                  ~~~~~~~~~~~~~~~~~~~~~
    [thread 0][arm-openwrt-linux-gnueabi-gcc] plugins/router_rewrite/router_rewr                                                                                                                                                                             ite.o
        ... (could only use 30,000 characters for the post xD) ...                                                                                                                                                                             .o
    [thread 0][arm-openwrt-linux-gnueabi-gcc] plugins/stats_pusher_socket/plugin                                                                                                                                                                             .o
    *** uWSGI linking ***
    arm-openwrt-linux-gnueabi-gcc -o /opt/bin/uwsgi -L/opt/lib -Wl,-rpath,/opt/l                                                                                                                                                                             ib core/utils.o core/protocol.o core/socket.o core/logging.o core/master.o core/                                                                                                                                                                             master_utils.o core/emperor.o core/notify.o core/mule.o core/subscription.o core                                                                                                                                                                             /stats.o core/sendfile.o core/async.o core/master_checks.o core/fifo.o core/offl                                                                                                                                                                             oad.o core/io.o core/static.o core/websockets.o core/spooler.o core/snmp.o core/                                                                                                                                                                             exceptions.o core/config.o core/setup_utils.o core/clock.o core/init.o core/buff                                                                                                                                                                             er.o core/reader.o core/writer.o core/alarm.o core/cron.o core/hooks.o core/plug                                                                                                                                                                             ins.o core/lock.o core/cache.o core/daemons.o core/errors.o core/hash.o core/mas                                                                                                                                                                             ter_events.o core/chunked.o core/queue.o core/event.o core/signal.o core/strings                                                                                                                                                                             .o core/progress.o core/timebomb.o core/ini.o core/fsmon.o core/mount.o core/met                                                                                                                                                                             rics.o core/plugins_builder.o core/sharedarea.o core/rpc.o core/gateway.o core/l                                                                                                                                                                             oop.o core/cookie.o core/querystring.o core/rb_timers.o core/transformations.o c                                                                                                                                                                             ore/uwsgi.o proto/base.o proto/uwsgi.o proto/http.o proto/fastcgi.o proto/scgi.o                                                                                                                                                                              proto/puwsgi.o lib/linux_ns.o core/zlib.o core/yaml.o core/json.o core/ssl.o co                                                                                                                                                                             re/legion.o core/xmlconf.o core/dot_h.o core/config_py.o plugins/python/python_p                                                                                                                                                                             lugin.o plugins/python/pyutils.o plugins/python/pyloader.o plugins/python/wsgi_h                                                                                                                                                                             andlers.o plugins/python/wsgi_headers.o plugins/python/wsgi_subhandler.o plugins                                                                                                                                                                             /python/web3_subhandler.o plugins/python/pump_subhandler.o plugins/python/gil.o                                                                                                                                                                              plugins/python/uwsgi_pymodule.o plugins/python/profiler.o plugins/python/symimpo                                                                                                                                                                             rter.o plugins/python/tracebacker.o plugins/python/raw.o plugins/gevent/gevent.o                                                                                                                                                                              plugins/gevent/hooks.o plugins/ping/ping_plugin.o plugins/cache/cache.o plugins                                                                                                                                                                             /nagios/nagios.o plugins/rrdtool/rrdtool.o plugins/carbon/carbon.o plugins/rpc/r                                                                                                                                                                             pc_plugin.o plugins/corerouter/cr_common.o plugins/corerouter/cr_map.o plugins/c                                                                                                                                                                             orerouter/corerouter.o plugins/fastrouter/fastrouter.o plugins/http/http.o plugi                                                                                                                                                                             ns/http/keepalive.o plugins/http/https.o plugins/http/spdy3.o plugins/signal/sig                                                                                                                                                                             nal_plugin.o plugins/syslog/syslog_plugin.o plugins/rsyslog/rsyslog_plugin.o plu                                                                                                                                                                             gins/logsocket/logsocket_plugin.o plugins/router_uwsgi/router_uwsgi.o plugins/ro                                                                                                                                                                             uter_redirect/router_redirect.o plugins/router_basicauth/router_basicauth.o plug                                                                                                                                                                             ins/zergpool/zergpool.o plugins/redislog/redislog_plugin.o plugins/mongodblog/mo                                                                                                                                                                             ngodblog_plugin.o plugins/router_rewrite/router_rewrite.o plugins/router_http/ro                                                                                                                                                                             uter_http.o plugins/logfile/logfile.o plugins/router_cache/router_cache.o plugin                                                                                                                                                                             s/rawrouter/rawrouter.o plugins/router_static/router_static.o plugins/sslrouter/                                                                                                                                                                             sslrouter.o plugins/spooler/spooler_plugin.o plugins/cheaper_busyness/cheaper_bu                                                                                                                                                                             syness.o plugins/symcall/symcall_plugin.o plugins/transformation_tofile/tofile.o                                                                                                                                                                              plugins/transformation_gzip/gzip.o plugins/transformation_chunked/chunked.o plu                                                                                                                                                                             gins/transformation_offload/offload.o plugins/router_memcached/router_memcached.                                                                                                                                                                             o plugins/router_redis/router_redis.o plugins/router_hash/router_hash.o plugins/                                                                                                                                                                             router_expires/expires.o plugins/router_metrics/plugin.o plugins/transformation_                                                                                                                                                                             template/tt.o plugins/stats_pusher_socket/plugin.o -lpthread -lm -rdynamic -ldl                                                                                                                                                                              -lz -lcap -luuid -ljansson -lssl -lcrypto -lexpat -lcrypt -ldl -lpthread -lutil                                                                                                                                                                              -lm -lm -lpython3.8 -lcrypt
    core/subscription.o: In function `uwsgi_remove_subscribe_node':
    subscription.c:(.text+0x928): undefined reference to `EVP_MD_CTX_free'
    subscription.c:(.text+0x9a0): undefined reference to `EVP_MD_CTX_free'
    core/subscription.o: In function `subscription_new_sign_ctx':
    subscription.c:(.text+0x1398): undefined reference to `EVP_MD_CTX_new'
    subscription.c:(.text+0x13c8): undefined reference to `EVP_MD_CTX_free'
    core/ssl.o: In function `uwsgi_ssl_init':
    ssl.c:(.text+0xa4): undefined reference to `OPENSSL_init_ssl'
    ssl.c:(.text+0xb4): undefined reference to `OPENSSL_init_ssl'
    ssl.c:(.text+0xc4): undefined reference to `OPENSSL_init_crypto'
    core/ssl.o: In function `uwsgi_ssl_new_server_context':
    ssl.c:(.text+0x214): undefined reference to `TLS_server_method'
    ssl.c:(.text+0x2ec): undefined reference to `SSL_CTX_set_options'
    ssl.c:(.text+0x324): undefined reference to `SSL_CTX_set_options'
    ssl.c:(.text+0x61c): undefined reference to `SSL_CTX_set_options'
    core/ssl.o: In function `uwsgi_rsa_sign':
    ssl.c:(.text+0x850): undefined reference to `EVP_MD_CTX_new'
    ssl.c:(.text+0x8c8): undefined reference to `EVP_MD_CTX_free'
    ssl.c:(.text+0x9e4): undefined reference to `EVP_MD_CTX_free'
    core/ssl.o: In function `uwsgi_sni_cb':
    ssl.c:(.text+0xe78): undefined reference to `SSL_CTX_get_options'
    ssl.c:(.text+0xe84): undefined reference to `SSL_set_options'
    collect2: error: ld returned 1 exit status
    *** error linking uWSGI ***
    ----------------------------------------
ERROR: Command errored out with exit status 1: /opt/bin/python3 -u -c 'import sy                                                                                                                                                                             s, setuptools, tokenize; sys.argv[0] = '"'"'/share/CACHEDEV2_DATA/.qpkg/Entware-                                                                                                                                                                             ng/tmp/pip-install-bl1wxksm/uwsgi/setup.py'"'"'; __file__='"'"'/share/CACHEDEV2_                                                                                                                                                                             DATA/.qpkg/Entware-ng/tmp/pip-install-bl1wxksm/uwsgi/setup.py'"'"';f=getattr(tok                                                                                                                                                                             enize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'                                                                                                                                                                             "'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --re                                                                                                                                                                             cord /share/CACHEDEV2_DATA/.qpkg/Entware-ng/tmp/pip-record-__6aj81m/install-reco                                                                                                                                                                             rd.txt --single-version-externally-managed --compile --install-headers /opt/incl                                                                                                                                                                             ude/python3.8/uwsgi Check the logs for full command output.