[flext] Build error related to ld and __stack_chk_guard@@GLIBC_2.17

Luca Turchet tur at create.aau.dk
Fri Aug 12 17:00:42 UTC 2016



Dear list members,
I am experiencing an error related to ld and __stack_chk_guard@@GLIBC_2.17
while building the "simple1" example of the tutorial, on my embedded board
ODROID C2 (which is armv8-64 bit) running Ubuntu 16.04.1:


g++ -c  -ffast-math -DFLEXT_USE_CMEM -O3 -march=native   -I/usr/include/pd -pthread -fPIC -fvisibility-inlines-hidden -DNDEBUG -DFLEXT_SYS=2 -DPD -I/usr/local/src/pd/src -I/usr/local/src/pd/include -I/usr/local/src/pd/include/pd -I/usr/local/include/stk -I/usr/local/include/sndobj -I/usr/local/include/flext main.cpp -o pd-linux/release-single/main.opp
g++ -L/usr/lib -pthread -shared  -Wl,-S -L/usr/local/src/pd/bin -L/usr/local/lib -o pd-linux/release-single/simple1.pd_linux   pd-linux/release-single/main.opp  -lflext-pd_s
/usr/bin/ld: /usr/local/lib/libflext-pd_s.a(libflext_pd_s_la-flxlet.o): relocation R_AARCH64_ADR_PREL_PG_HI21 against external symbol `__stack_chk_guard@@GLIBC_2.17' can not be used when making a shared object; recompile with -fPIC
/usr/bin/ld: /usr/local/lib/libflext-pd_s.a(libflext_pd_s_la-flxlet.o)(.text+0x344): unresolvable R_AARCH64_ADR_PREL_PG_HI21 relocation against symbol `__stack_chk_guard@@GLIBC_2.17'
/usr/bin/ld: final link failed: Bad value
collect2: error: ld returned 1 exit status


I also tried to compile inserting the flag -fno-stack-protector as indicated for a related case
on this link http://stackoverflow.com/questions/15787684/lfs-glibc-compilation-ld-error
but I got the same result.

Any ideas? My version of g++ is 5.4.0.

I was also wondering whether the flags -ffast-math and -O3 are appropriate for armv8-64 platforms.



Best

Luca




______________________________________________

Luca Turchet, Ph.D.
Postdoctoral Research Fellow

Department of Architecture, Design & Media Technology
Aalborg University Copenhagen
A. C. Meyers Vænge 15
DK-2450 Copenhagen SV

E-mail: tur at create.aau.dk<mailto:tur at create.aau.dk>
Project Website: www.ahws-project.net<http://www.ahws-project.net>
Personal Website: www.lucaturchet.it<http://www.lucaturchet.it>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://grrrr.org/pipermail/flext/attachments/20160812/9ee6a6cb/attachment.html>


More information about the flext mailing list