tarantool / mqtt

Tarantool MQTT client
tarantool.org
BSD 2-Clause "Simplified" License
38 stars 10 forks source link

Cannot install (build) rock on Ubuntu 20.04 aarch64 #46

Open ylobankov opened 1 year ago

ylobankov commented 1 year ago

Environment:

$ cat /etc/lsb-release
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=20.04
DISTRIB_CODENAME=focal
DISTRIB_DESCRIPTION="Ubuntu 20.04.5 LTS"

$ uname -m
aarch64

Tarantool:

$ tarantool --version
Tarantool 2.10.5-0-g87d07d15e
Target: Linux-aarch64-RelWithDebInfo
Build options: cmake . -DCMAKE_INSTALL_PREFIX=/usr -DENABLE_BACKTRACE=ON
Compiler: GNU-9.3.0
C_FLAGS:-g -O2 -fdebug-prefix-map=/build/tarantool-2.10.5=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fexceptions -funwind-tables -fno-common -fopenmp  -fmacro-prefix-map=/build/tarantool-2.10.5=. -std=c11 -Wall -Wextra -Wno-strict-aliasing -Wno-char-subscripts -Wno-format-truncation -Wno-gnu-alignof-expression -fno-gnu89-inline -Wno-cast-function-type
CXX_FLAGS:-g -O2 -fdebug-prefix-map=/build/tarantool-2.10.5=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fexceptions -funwind-tables -fno-common -fopenmp  -fmacro-prefix-map=/build/tarantool-2.10.5=. -std=c++11 -Wall -Wextra -Wno-strict-aliasing -Wno-char-subscripts -Wno-format-truncation -Wno-invalid-offsetof -Wno-gnu-alignof-expression -Wno-cast-function-type

Steps to reproduce:

$ tarantoolctl rocks install mqtt 1.5.1
Installing http://rocks.tarantool.org/mqtt-1.5.1-1.rockspec

Cloning into 'mqtt'...
remote: Enumerating objects: 394, done.
remote: Counting objects: 100% (12/12), done.
remote: Compressing objects: 100% (10/10), done.
remote: Total 394 (delta 3), reused 6 (delta 2), pack-reused 382
Receiving objects: 100% (394/394), 106.49 KiB | 1.72 MiB/s, done.
Resolving deltas: 100% (199/199), done.
Note: switching to 'db283743f4fc96dccf1e4c77afa6e5d54f660d4c'.

You are in 'detached HEAD' state. You can look around, make experimental
changes and commit them, and you can discard any commits you make in this
state without impacting any branches by switching back to a branch.

If you want to create a new branch to retain commits you create, you may
do so (now or later) by using -c with the switch command. Example:

  git switch -c <new-branch-name>

Or undo this operation with:

  git switch -

Turn off this advice by setting config variable advice.detachedHead to false

Submodule 'third_party/mosquitto' (https://github.com/eclipse/mosquitto) registered for path 'third_party/mosquitto'
Cloning into '/tmp/luarocks_mqtt-1.5.1-1-Xdw39o/mqtt/third_party/mosquitto'...
remote: Enumerating objects: 33838, done.
remote: Counting objects: 100% (2117/2117), done.
remote: Compressing objects: 100% (675/675), done.
remote: Total 33838 (delta 1493), reused 2015 (delta 1427), pack-reused 31721
Receiving objects: 100% (33838/33838), 13.24 MiB | 4.31 MiB/s, done.
Resolving deltas: 100% (26211/26211), done.
Submodule path 'third_party/mosquitto': checked out '9470cd8c686b0d584d8c18549d48bf3229dd78ab'
-- The C compiler identification is GNU 9.4.0
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Found TARANTOOL: /usr/include (found version "2.10.5-0-g87d07d15e")
-- Tarantool LUADIR is /.rocks/share/tarantool/rocks/mqtt/1.5.1-1/lua
-- Tarantool LIBDIR is /.rocks/share/tarantool/rocks/mqtt/1.5.1-1/lib
-- tarantool: /usr/include;/usr/include/tarantool
-- The CXX compiler identification is GNU 9.4.0
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Looking for pthread.h
-- Looking for pthread.h - found
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD - Failed
-- Looking for pthread_create in pthreads
-- Looking for pthread_create in pthreads - not found
-- Looking for pthread_create in pthread
-- Looking for pthread_create in pthread - found
-- Found Threads: TRUE
-- Found OpenSSL: /usr/lib/aarch64-linux-gnu/libcrypto.a (found version "1.1.1f")
-- WITH_DLT = OFF
-- Looking for getaddrinfo_a in anl
-- Looking for getaddrinfo_a in anl - found
-- Configuring done
-- Generating done
-- Build files have been written to: /tmp/luarocks_mqtt-1.5.1-1-Xdw39o/mqtt/build.luarocks
Scanning dependencies of target libmosquitto_static
[  3%] Building C object third_party/mosquitto/build/lib/CMakeFiles/libmosquitto_static.dir/actions.c.o
[  7%] Building C object third_party/mosquitto/build/lib/CMakeFiles/libmosquitto_static.dir/callbacks.c.o
[  7%] Building C object third_party/mosquitto/build/lib/CMakeFiles/libmosquitto_static.dir/connect.c.o
[ 11%] Building C object third_party/mosquitto/build/lib/CMakeFiles/libmosquitto_static.dir/handle_auth.c.o
[ 11%] Building C object third_party/mosquitto/build/lib/CMakeFiles/libmosquitto_static.dir/handle_connack.c.o
[ 15%] Building C object third_party/mosquitto/build/lib/CMakeFiles/libmosquitto_static.dir/handle_disconnect.c.o
[ 19%] Building C object third_party/mosquitto/build/lib/CMakeFiles/libmosquitto_static.dir/handle_ping.c.o
[ 19%] Building C object third_party/mosquitto/build/lib/CMakeFiles/libmosquitto_static.dir/handle_pubackcomp.c.o
[ 23%] Building C object third_party/mosquitto/build/lib/CMakeFiles/libmosquitto_static.dir/handle_publish.c.o
[ 23%] Building C object third_party/mosquitto/build/lib/CMakeFiles/libmosquitto_static.dir/handle_pubrec.c.o
[ 26%] Building C object third_party/mosquitto/build/lib/CMakeFiles/libmosquitto_static.dir/handle_pubrel.c.o
[ 26%] Building C object third_party/mosquitto/build/lib/CMakeFiles/libmosquitto_static.dir/handle_suback.c.o
[ 30%] Building C object third_party/mosquitto/build/lib/CMakeFiles/libmosquitto_static.dir/handle_unsuback.c.o
[ 34%] Building C object third_party/mosquitto/build/lib/CMakeFiles/libmosquitto_static.dir/helpers.c.o
[ 34%] Building C object third_party/mosquitto/build/lib/CMakeFiles/libmosquitto_static.dir/logging_mosq.c.o
[ 38%] Building C object third_party/mosquitto/build/lib/CMakeFiles/libmosquitto_static.dir/loop.c.o
[ 38%] Building C object third_party/mosquitto/build/lib/CMakeFiles/libmosquitto_static.dir/memory_mosq.c.o
[ 42%] Building C object third_party/mosquitto/build/lib/CMakeFiles/libmosquitto_static.dir/messages_mosq.c.o
[ 46%] Building C object third_party/mosquitto/build/lib/CMakeFiles/libmosquitto_static.dir/mosquitto.c.o
[ 46%] Building C object third_party/mosquitto/build/lib/CMakeFiles/libmosquitto_static.dir/net_mosq_ocsp.c.o
[ 50%] Building C object third_party/mosquitto/build/lib/CMakeFiles/libmosquitto_static.dir/net_mosq.c.o
[ 50%] Building C object third_party/mosquitto/build/lib/CMakeFiles/libmosquitto_static.dir/options.c.o
[ 53%] Building C object third_party/mosquitto/build/lib/CMakeFiles/libmosquitto_static.dir/packet_datatypes.c.o
[ 57%] Building C object third_party/mosquitto/build/lib/CMakeFiles/libmosquitto_static.dir/packet_mosq.c.o
[ 57%] Building C object third_party/mosquitto/build/lib/CMakeFiles/libmosquitto_static.dir/property_mosq.c.o
[ 61%] Building C object third_party/mosquitto/build/lib/CMakeFiles/libmosquitto_static.dir/read_handle.c.o
[ 61%] Building C object third_party/mosquitto/build/lib/CMakeFiles/libmosquitto_static.dir/send_connect.c.o
[ 65%] Building C object third_party/mosquitto/build/lib/CMakeFiles/libmosquitto_static.dir/send_disconnect.c.o
[ 65%] Building C object third_party/mosquitto/build/lib/CMakeFiles/libmosquitto_static.dir/send_mosq.c.o
[ 69%] Building C object third_party/mosquitto/build/lib/CMakeFiles/libmosquitto_static.dir/send_publish.c.o
[ 73%] Building C object third_party/mosquitto/build/lib/CMakeFiles/libmosquitto_static.dir/send_subscribe.c.o
[ 73%] Building C object third_party/mosquitto/build/lib/CMakeFiles/libmosquitto_static.dir/send_unsubscribe.c.o
[ 76%] Building C object third_party/mosquitto/build/lib/CMakeFiles/libmosquitto_static.dir/socks_mosq.c.o
[ 76%] Building C object third_party/mosquitto/build/lib/CMakeFiles/libmosquitto_static.dir/srv_mosq.c.o
[ 80%] Building C object third_party/mosquitto/build/lib/CMakeFiles/libmosquitto_static.dir/thread_mosq.c.o
[ 84%] Building C object third_party/mosquitto/build/lib/CMakeFiles/libmosquitto_static.dir/time_mosq.c.o
[ 84%] Building C object third_party/mosquitto/build/lib/CMakeFiles/libmosquitto_static.dir/tls_mosq.c.o
[ 88%] Building C object third_party/mosquitto/build/lib/CMakeFiles/libmosquitto_static.dir/utf8_mosq.c.o
[ 88%] Building C object third_party/mosquitto/build/lib/CMakeFiles/libmosquitto_static.dir/util_mosq.c.o
[ 92%] Building C object third_party/mosquitto/build/lib/CMakeFiles/libmosquitto_static.dir/util_topic.c.o
[ 96%] Building C object third_party/mosquitto/build/lib/CMakeFiles/libmosquitto_static.dir/will_mosq.c.o
[ 96%] Linking C static library libmosquitto.a
[ 96%] Built target libmosquitto_static
Scanning dependencies of target driver
[ 96%] Building C object mqtt/CMakeFiles/driver.dir/driver.c.o
[100%] Linking C shared library driver.so
/usr/bin/ld: /usr/lib/gcc/aarch64-linux-gnu/9/../../../aarch64-linux-gnu/libcrypto.a(sha1-armv8.o): relocation R_AARCH64_PREL64 against symbol `OPENSSL_armcap_P' which may bind externally can not be used when making a shared object; recompile with -fPIC
/usr/lib/gcc/aarch64-linux-gnu/9/../../../aarch64-linux-gnu/libcrypto.a(sha1-armv8.o): in function `sha1_block_armv8':
(.text+0x1240): dangerous relocation: unsupported relocation
/usr/bin/ld: /usr/lib/gcc/aarch64-linux-gnu/9/../../../aarch64-linux-gnu/libcrypto.a(chacha-armv8.o): relocation R_AARCH64_PREL64 against symbol `OPENSSL_armcap_P' which may bind externally can not be used when making a shared object; recompile with -fPIC
/usr/lib/gcc/aarch64-linux-gnu/9/../../../aarch64-linux-gnu/libcrypto.a(chacha-armv8.o):(.text+0x20): dangerous relocation: unsupported relocation
/usr/bin/ld: /usr/lib/gcc/aarch64-linux-gnu/9/../../../aarch64-linux-gnu/libcrypto.a(poly1305-armv8.o): relocation R_AARCH64_ADR_PREL_LO21 against symbol `poly1305_blocks' which may bind externally can not be used when making a shared object; recompile with -fPIC
/usr/lib/gcc/aarch64-linux-gnu/9/../../../aarch64-linux-gnu/libcrypto.a(poly1305-armv8.o): in function `poly1305_init':
(.text+0x40): dangerous relocation: unsupported relocation
/usr/bin/ld: /usr/lib/gcc/aarch64-linux-gnu/9/../../../aarch64-linux-gnu/libcrypto.a(poly1305-armv8.o): relocation R_AARCH64_ADR_PREL_LO21 against symbol `poly1305_emit' which may bind externally can not be used when making a shared object; recompile with -fPIC
(.text+0x48): dangerous relocation: unsupported relocation
/usr/bin/ld: /usr/lib/gcc/aarch64-linux-gnu/9/../../../aarch64-linux-gnu/libcrypto.a(poly1305-armv8.o): relocation R_AARCH64_PREL64 against symbol `OPENSSL_armcap_P' which may bind externally can not be used when making a shared object; recompile with -fPIC
/usr/lib/gcc/aarch64-linux-gnu/9/../../../aarch64-linux-gnu/libcrypto.a(poly1305-armv8.o): in function `poly1305_emit_neon':
(.text+0x9a0): dangerous relocation: unsupported relocation
/usr/bin/ld: /usr/lib/gcc/aarch64-linux-gnu/9/../../../aarch64-linux-gnu/libcrypto.a(sha256-armv8.o): relocation R_AARCH64_PREL64 against symbol `OPENSSL_armcap_P' which may bind externally can not be used when making a shared object; recompile with -fPIC
/usr/lib/gcc/aarch64-linux-gnu/9/../../../aarch64-linux-gnu/libcrypto.a(sha256-armv8.o): in function `sha256_block_data_order':
(.text+0xf88): dangerous relocation: unsupported relocation
/usr/bin/ld: /usr/lib/gcc/aarch64-linux-gnu/9/../../../aarch64-linux-gnu/libcrypto.a(sha512-armv8.o): relocation R_AARCH64_PREL64 against symbol `OPENSSL_armcap_P' which may bind externally can not be used when making a shared object; recompile with -fPIC
/usr/lib/gcc/aarch64-linux-gnu/9/../../../aarch64-linux-gnu/libcrypto.a(sha512-armv8.o): in function `sha512_block_data_order':
(.text+0x1108): dangerous relocation: unsupported relocation
collect2: error: ld returned 1 exit status
make[2]: *** [mqtt/CMakeFiles/driver.dir/build.make:87: mqtt/driver.so] Error 1
make[1]: *** [CMakeFiles/Makefile2:231: mqtt/CMakeFiles/driver.dir/all] Error 2
make: *** [Makefile:130: all] Error 2

Error: Build error: Failed building.

Actual result: Instalatation failed. See logs above.

Expected result: Installation is successful.