BUILD: tools: unbreak resolve_sym_name() on non-GNU platforms
authorWilly Tarreau <w@1wt.eu>
Wed, 4 Mar 2020 09:19:36 +0000 (10:19 +0100)
committerWilly Tarreau <w@1wt.eu>
Fri, 1 May 2020 15:09:20 +0000 (17:09 +0200)
commitca91dea2d016185cf1059e8aaa0a1bcf8c58c3e2
treeaabaa47580fc5d62c501032d3c0c84d2e33ffeff
parent61341b422a3793fc2527ba5a553738a8524b16a8
BUILD: tools: unbreak resolve_sym_name() on non-GNU platforms

resolve_sym_name() doesn't build when USE_DL is set on non-GNU platforms
because "Elf(W)" isn't defined. Since it's only used for dladdr1(), let's
refactor all this so that we can completely ifdef out that part on other
platforms. Now we have a separate function to perform the call depending
on the platform and it only returns the size when available.

(cherry picked from commit 9133e48f2a6fa9deccfe02798dcb2f2abd26ed9e)
Signed-off-by: Willy Tarreau <w@1wt.eu>
src/standard.c