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

Guix: Cross compile for linux fails unless -fPIC is passed to cxxflags #166

Open
vertiond opened this issue Dec 16, 2021 · 0 comments
Open

Comments

@vertiond
Copy link
Member

Cross compiling for x86_64-linux-gnu using contrib/guix-build.sh fails unless -fPIC is passed to cxxflags.

  CXXLD    vertcoin-cli
  CXXLD    vertcoin-tx
  CXXLD    vertcoin-wallet
  CXX      qt/vertcoin_qt-main.o
  CXX      qt/libbitcoinqt_a-bantablemodel.o
  CXX      qt/libbitcoinqt_a-bitcoin.o
x86_64-linux-gnu-ld: crypto/libbitcoin_crypto_base.a(libbitcoin_crypto_base_a-Sponge.o): relocation R_X86_64_32 against `.rodata.str1.1' can not be used when making a PIE object; recompile with -fPIC
x86_64-linux-gnu-ld: crypto/libbitcoin_crypto_base.a(libbitcoin_crypto_base_a-blake.o): relocation R_X86_64_32 against `.rodata' can not be used when making a PIE object; recompile with -fPIC
x86_64-linux-gnu-ld: crypto/libbitcoin_crypto_base.a(libbitcoin_crypto_base_a-groestl.o): relocation R_X86_64_32S against `.rodata' can not be used when making a PIE object; recompile with -fPIC
x86_64-linux-gnu-ld: crypto/libbitcoin_crypto_base.a(libbitcoin_crypto_base_a-keccak.o): relocation R_X86_64_32S against `.rodata' can not be used when making a PIE object; recompile with -fPIC
x86_64-linux-gnu-ld: crypto/libbitcoin_crypto_base.a(libbitcoin_crypto_base_a-bmw.o): relocation R_X86_64_32 against `.rodata' can not be used when making a PIE object; recompile with -fPIC
x86_64-linux-gnu-ld: final link failed: nonrepresentable section on output
collect2: error: ld returned 1 exit status
make[2]: *** [Makefile:9739: vertcoin-tx] Error 1
make[2]: *** Waiting for unfinished jobs....
x86_64-linux-gnu-ld: crypto/libbitcoin_crypto_base.a(libbitcoin_crypto_base_a-Sponge.o): relocation R_X86_64_32 against `.rodata.str1.1' can not be used when making a PIE object; recompile with -fPIC
x86_64-linux-gnu-ld: crypto/libbitcoin_crypto_base.a(libbitcoin_crypto_base_a-blake.o): relocation R_X86_64_32 against `.rodata' can not be used when making a PIE object; recompile with -fPIC
x86_64-linux-gnu-ld: crypto/libbitcoin_crypto_base.a(libbitcoin_crypto_base_a-groestl.o): relocation R_X86_64_32S against `.rodata' can not be used when making a PIE object; recompile with -fPIC
x86_64-linux-gnu-ld: crypto/libbitcoin_crypto_base.a(libbitcoin_crypto_base_a-keccak.o): relocation R_X86_64_32S against `.rodata' can not be used when making a PIE object; recompile with -fPIC
x86_64-linux-gnu-ld: crypto/libbitcoin_crypto_base.a(libbitcoin_crypto_base_a-bmw.o): relocation R_X86_64_32 against `.rodata' can not be used when making a PIE object; recompile with -fPIC
x86_64-linux-gnu-ld: final link failed: nonrepresentable section on output
collect2: error: ld returned 1 exit status
make[2]: *** [Makefile:9743: vertcoin-wallet] Error 1
make[2]: Leaving directory '/vertcoin/distsrc-x86_64-linux-gnu/src'
make[1]: *** [Makefile:19948: all-recursive] Error 1
make[1]: Leaving directory '/vertcoin/distsrc-x86_64-linux-gnu/src'
make: *** [Makefile:803: all-recursive] Error 1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant