Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ubuntu focal on arm 'mqtt' installation error: 'dangerous relocation: unsupported relocation' #233

Open
artembo opened this issue May 26, 2022 · 2 comments

Comments

@artembo
Copy link

artembo commented May 26, 2022

The error occurred when the 'mqtt' rock installation. It is disabled for the current tag 2.10.0-ubuntu-aarch64.

#6 1168.6 /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
#6 1168.6 /usr/lib/gcc/aarch64-linux-gnu/9/../../../aarch64-linux-gnu/libcrypto.a(sha1-armv8.o): in function `sha1_block_armv8':
#6 1168.6 (.text+0x1240): dangerous relocation: unsupported relocation
#6 1168.6 /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
#6 1168.6 /usr/lib/gcc/aarch64-linux-gnu/9/../../../aarch64-linux-gnu/libcrypto.a(chacha-armv8.o):(.text+0x20): dangerous relocation: unsupported relocation
#6 1168.6 /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
#6 1168.6 /usr/lib/gcc/aarch64-linux-gnu/9/../../../aarch64-linux-gnu/libcrypto.a(poly1305-armv8.o): in function `poly1305_init':
#6 1168.6 (.text+0x40): dangerous relocation: unsupported relocation
#6 1168.6 /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
#6 1168.6 (.text+0x48): dangerous relocation: unsupported relocation
#6 1168.6 /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
#6 1168.6 /usr/lib/gcc/aarch64-linux-gnu/9/../../../aarch64-linux-gnu/libcrypto.a(poly1305-armv8.o): in function `poly1305_emit_neon':
#6 1168.6 (.text+0x9a0): dangerous relocation: unsupported relocation
#6 1168.6 /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
#6 1168.6 /usr/lib/gcc/aarch64-linux-gnu/9/../../../aarch64-linux-gnu/libcrypto.a(sha256-armv8.o): in function `sha256_block_data_order':
#6 1168.6 (.text+0xf88): dangerous relocation: unsupported relocation
#6 1168.6 /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
#6 1168.6 /usr/lib/gcc/aarch64-linux-gnu/9/../../../aarch64-linux-gnu/libcrypto.a(sha512-armv8.o): in function `sha512_block_data_order':
#6 1168.6 (.text+0x1108): dangerous relocation: unsupported relocation
#6 1168.6 collect2: error: ld returned 1 exit status
@Totktonada
Copy link
Member

It seems, /usr/lib/aarch64-linux-gnu/libcrypto.a is built without -fPIC. From where the library comes? It is quite unusual to see a library built without -fPIC in a Linux distribution that is released somewhere in a last ten years at least, because it means that the library can't be used in any -fPIC (dynamic library) or -fPIE (executable) code. Linux distros also use -fPIE by default for years.

I mean, if it comes from distro's repositories, it can be considered as the problem in the package and worth a notice for its maintainers.

@ylobankov
Copy link
Member

Related to #259.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants