1 From 67817281c4346832356febca89373742a0cde8b1 Mon Sep 17 00:00:00 2001
2 From: Jan Palus <atler@pld-linux.org>
3 Date: Sat, 31 Oct 2020 00:04:11 +0100
4 Subject: [PATCH] create symbolic link for dynamic lib as well
6 both tndb and vfile in poldek link against libtrurl and due to the way
7 linking is configured it is always linked with static libtrurl (only
8 libtrurl.a link provided). this causes two issues:
10 - mixes dynamically linked libraries with statically linked libtrurl
11 and since nothing enforces -fPIC in the latter it results in error:
13 libtool: warning: relinking 'libtndb.la'
14 libtool: install: ... -o .libs/libtndb.so.0.2.0
15 /usr/bin/ld: ./../trurlib/libtrurl.a(ndie.o): relocation R_AARCH64_ADR_PREL_PG_HI21 against symbol `__stack_chk_guard@@GLIBC_2.17' which may bind externally can not be used when making a shared object; recompile with -fPIC
16 /usr/bin/ld: ./../trurlib/libtrurl.a(ndie.o)(.text+0x8): unresolvable R_AARCH64_ADR_PREL_PG_HI21 relocation against symbol `__stack_chk_guard@@GLIBC_2.17'
17 /usr/bin/ld: final link failed: bad value
19 - includes copy of libtrurl in dynamic libraries even though poldek
20 provides dynamic libtrurl
23 1 file changed, 1 insertion(+)
25 diff --git a/Makefile.am b/Makefile.am
26 index 7c41374..0d13380 100644
29 @@ -146,5 +146,6 @@ tests: $(EXTRA_PROGRAMS)
32 @ln -sf .libs/libtrurl.a libtrurl.a
33 + @ln -sf .libs/libtrurl.so libtrurl.so
35 include Makefile.extra