Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 376196 Details for
Bug 470884
dev-libs/elfutils: build fails on uclibc
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Check if argp is provided by libc or is standalone (0.158)
elfutils-0.158-check-standalone-argp.patch (text/plain), 7.63 KB, created by
Alex Guzman
on 2014-05-02 11:10:26 UTC
(
hide
)
Description:
Check if argp is provided by libc or is standalone (0.158)
Filename:
MIME Type:
Creator:
Alex Guzman
Created:
2014-05-02 11:10:26 UTC
Size:
7.63 KB
patch
obsolete
>commit fddd5c8af3d7d0d01a36d5bc271a967f4efeb5ea >Author: Daniel Guzman <daniel@guzman.io> >Date: Fri May 2 01:41:20 2014 +0000 > > [PATCH] Updated argp link patch > > Updated Anthony Basile's patch to 0.158 > > Original message: > > argp is not part of POSIX standards and not provided by uClibc or > some other standard C libraries. However, it is possible to link > against a breakout argp library. One is provided at > > http://www.lysator.liu.se/~nisse/misc/ > > This patch tests if libc provides argp otherwise it adds the linker > flag -largp where needed in the build system. > > Signed-off-by: Daniel Guzman <daniel@guzman.io> >--- > configure.ac | 26 ++++++++++++++++++++++++++ > libdw/Makefile.am | 2 +- > src/Makefile.am | 30 +++++++++++++++--------------- > tests/Makefile.am | 20 ++++++++++---------- > 4 files changed, 52 insertions(+), 26 deletions(-) > >diff --git a/configure.ac b/configure.ac >index 661d28d..b0877dc 100644 >--- a/configure.ac >+++ b/configure.ac >@@ -298,6 +298,32 @@ AC_CHECK_LIB([stdc++], [__cxa_demangle], [dnl > AC_DEFINE([USE_DEMANGLE], [1], [Defined if demangling is enabled])]) > AM_CONDITIONAL(DEMANGLE, test "$ac_cv_lib_stdcpp___cxa_demangle" = yes) > >+dnl Check if we have argp available from our libc >+AC_LINK_IFELSE( >+ [AC_LANG_PROGRAM( >+ [#include <argp.h>], >+ [int argc=1; char *argv[]={"test"}; argp_parse(0,argc,argv,0,0,0); return 0;] >+ )], >+ [libc_has_argp="true"], >+ [libc_has_argp="false"] >+) >+ >+dnl If our libc doesn't provide argp, then test for libargp >+if test "$libc_has_argp" = "false" ; then >+ AC_MSG_WARN("libc does not have argp") >+ AC_CHECK_LIB([argp], [argp_parse], [have_argp="true"], [have_argp="false"]) >+ >+ if test "$have_argp" = "false"; then >+ AC_MSG_ERROR("no libargp found") >+ else >+ argp_LDADD="-largp" >+ fi >+else >+ argp_LDADD="" >+fi >+AC_SUBST([argp_LDADD]) >+ >+ > dnl Check for __mempcpy > AC_CHECK_FUNCS_ONCE([__mempcpy]) > >diff --git a/libdw/Makefile.am b/libdw/Makefile.am >index cd9e314..b452c7d 100644 >--- a/libdw/Makefile.am >+++ b/libdw/Makefile.am >@@ -111,7 +111,7 @@ libdw.so: $(srcdir)/libdw.map libdw_pic.a \ > -Wl,--enable-new-dtags,-rpath,$(pkglibdir) \ > -Wl,--version-script,$<,--no-undefined \ > -Wl,--whole-archive $(filter-out $<,$^) -Wl,--no-whole-archive\ >- -ldl $(zip_LIBS) >+ -ldl $(argp_LDADD) $(zip_LIBS) > if $(READELF) -d $@ | fgrep -q TEXTREL; then exit 1; fi > ln -fs $@ $@.$(VERSION) > >diff --git a/src/Makefile.am b/src/Makefile.am >index 650a1c0..40fa528 100644 >--- a/src/Makefile.am >+++ b/src/Makefile.am >@@ -98,27 +98,27 @@ ldgeneric_no_Wunused = yes > # Buggy old compilers. > readelf_no_Werror = yes > >-readelf_LDADD = $(libdw) $(libebl) $(libelf) $(libeu) $(libmudflap) -ldl >-nm_LDADD = $(libdw) $(libebl) $(libelf) $(libeu) $(libmudflap) -ldl \ >+readelf_LDADD = $(libdw) $(libebl) $(libelf) $(libeu) $(libmudflap) $(argp_LDADD) -ldl >+nm_LDADD = $(libdw) $(libebl) $(libelf) $(libeu) $(libmudflap) $(argp_LDADD) -ldl \ > $(demanglelib) >-size_LDADD = $(libelf) $(libeu) $(libmudflap) >-strip_LDADD = $(libebl) $(libelf) $(libeu) $(libmudflap) -ldl >-ld_LDADD = $(libebl) $(libelf) $(libeu) $(libmudflap) -ldl >+size_LDADD = $(libelf) $(libeu) $(libmudflap) $(argp_LDADD) >+strip_LDADD = $(libebl) $(libelf) $(libeu) $(libmudflap) $(argp_LDADD) -ldl >+ld_LDADD = $(libebl) $(libelf) $(libeu) $(libmudflap) $(argp_LDADD) -ldl > if NATIVE_LD > # -ldl is always needed for libebl. > ld_LDADD += libld_elf.a > endif > ld_LDFLAGS = -rdynamic >-elflint_LDADD = $(libebl) $(libelf) $(libeu) $(libmudflap) -ldl >-findtextrel_LDADD = $(libdw) $(libelf) $(libmudflap) >-addr2line_LDADD = $(libdw) $(libelf) $(libmudflap) >-elfcmp_LDADD = $(libebl) $(libelf) $(libmudflap) -ldl >-objdump_LDADD = $(libasm) $(libebl) $(libelf) $(libeu) $(libmudflap) -ldl >-ranlib_LDADD = libar.a $(libelf) $(libeu) $(libmudflap) >-strings_LDADD = $(libelf) $(libeu) $(libmudflap) >-ar_LDADD = libar.a $(libelf) $(libeu) $(libmudflap) >-unstrip_LDADD = $(libebl) $(libelf) $(libdw) $(libeu) $(libmudflap) -ldl >-stack_LDADD = $(libebl) $(libelf) $(libdw) $(libeu) $(libmudflap) -ldl \ >+elflint_LDADD = $(libebl) $(libelf) $(libeu) $(libmudflap) $(argp_LDADD) -ldl >+findtextrel_LDADD = $(libdw) $(libelf) $(libmudflap) $(argp_LDADD) >+addr2line_LDADD = $(libdw) $(libelf) $(libmudflap) $(argp_LDADD) >+elfcmp_LDADD = $(libebl) $(libelf) $(libmudflap) $(argp_LDADD) -ldl >+objdump_LDADD = $(libasm) $(libebl) $(libelf) $(libeu) $(libmudflap) $(argp_LDADD) -ldl >+ranlib_LDADD = libar.a $(libelf) $(libeu) $(libmudflap) $(argp_LDADD) >+strings_LDADD = $(libelf) $(libeu) $(libmudflap) $(argp_LDADD) >+ar_LDADD = libar.a $(libelf) $(libeu) $(libmudflap) $(argp_LDADD) >+unstrip_LDADD = $(libebl) $(libelf) $(libdw) $(libeu) $(libmudflap) $(argp_LDADD) -ldl >+stack_LDADD = $(libebl) $(libelf) $(libdw) $(libeu) $(libmudflap) $(argp_LDADD) -ldl \ > $(demanglelib) > > ldlex.o: ldscript.c >diff --git a/tests/Makefile.am b/tests/Makefile.am >index eae64a8..1688e8a 100644 >--- a/tests/Makefile.am >+++ b/tests/Makefile.am >@@ -346,12 +346,12 @@ get_files_LDADD = $(libdw) $(libelf) $(libmudflap) > get_aranges_LDADD = $(libdw) $(libelf) $(libmudflap) > allfcts_LDADD = $(libdw) $(libelf) $(libmudflap) > line2addr_no_Wformat = yes >-line2addr_LDADD = $(libdw) $(libmudflap) >-addrscopes_LDADD = $(libdw) $(libmudflap) >-funcscopes_LDADD = $(libdw) $(libmudflap) >-funcretval_LDADD = $(libdw) $(libmudflap) >-allregs_LDADD = $(libdw) $(libmudflap) >-find_prologues_LDADD = $(libdw) $(libmudflap) >+line2addr_LDADD = $(libdw) $(libmudflap) $(argp_LDADD) >+addrscopes_LDADD = $(libdw) $(libmudflap) $(argp_LDADD) >+funcscopes_LDADD = $(libdw) $(libmudflap) $(argp_LDADD) >+funcretval_LDADD = $(libdw) $(libmudflap) $(argp_LDADD) >+allregs_LDADD = $(libdw) $(libmudflap) $(argp_LDADD) >+find_prologues_LDADD = $(libdw) $(libmudflap) $(argp_LDADD) > #show_ciefde_LDADD = ../libdwarf/libdwarf.so $(libelf) $(libmudflap) > asm_tst1_LDADD = $(libasm) $(libebl) $(libelf) $(libmudflap) -ldl > asm_tst2_LDADD = $(libasm) $(libebl) $(libelf) $(libmudflap) -ldl >@@ -362,24 +362,24 @@ asm_tst6_LDADD = $(libasm) $(libebl) $(libelf) $(libmudflap) -ldl > asm_tst7_LDADD = $(libasm) $(libebl) $(libelf) $(libmudflap) -ldl > asm_tst8_LDADD = $(libasm) $(libebl) $(libelf) $(libmudflap) -ldl > asm_tst9_LDADD = $(libasm) $(libebl) $(libelf) $(libmudflap) -ldl >-dwflmodtest_LDADD = $(libdw) $(libebl) $(libelf) $(libmudflap) -ldl >+dwflmodtest_LDADD = $(libdw) $(libebl) $(libelf) $(libmudflap) $(argp_LDADD) -ldl > rdwrmmap_LDADD = $(libelf) $(libmudflap) > dwfl_bug_addr_overflow_LDADD = $(libdw) $(libebl) $(libelf) $(libmudflap) -ldl > arls_LDADD = $(libelf) $(libmudflap) > dwfl_bug_fd_leak_LDADD = $(libdw) $(libebl) $(libelf) $(libmudflap) -ldl > dwfl_bug_report_LDADD = $(libdw) $(libebl) $(libelf) $(libmudflap) -ldl > dwfl_bug_getmodules_LDADD = $(libdw) $(libebl) $(libelf) $(libmudflap) -ldl >-dwfl_addr_sect_LDADD = $(libdw) $(libebl) $(libelf) $(libmudflap) -ldl >+dwfl_addr_sect_LDADD = $(libdw) $(libebl) $(libelf) $(libmudflap) $(argp_LDADD) -ldl > dwarf_getmacros_LDADD = $(libdw) $(libmudflap) > dwarf_getstring_LDADD = $(libdw) $(libmudflap) >-addrcfi_LDADD = $(libdw) $(libebl) $(libelf) $(libmudflap) -ldl >+addrcfi_LDADD = $(libdw) $(libebl) $(libelf) $(libmudflap) $(argp_LDADD) -ldl > test_flag_nobits_LDADD = $(libelf) $(libmudflap) > rerequest_tag_LDADD = $(libdw) $(libmudflap) > alldts_LDADD = $(libebl) $(libelf) $(libmudflap) > md5_sha1_test_LDADD = $(libeu) > typeiter_LDADD = $(libdw) $(libelf) $(libmudflap) > typeiter2_LDADD = $(libdw) $(libelf) $(libmudflap) >-low_high_pc_LDADD = $(libdw) $(libelf) $(libmudflap) >+low_high_pc_LDADD = $(libdw) $(libelf) $(libmudflap) $(argp_LDADD) > test_elf_cntl_gelf_getshdr_LDADD = $(libelf) $(libmudflap) > dwflsyms_LDADD = $(libdw) $(libelf) $(libmudflap) > dwfllines_LDADD = $(libdw) $(libelf) $(libmudflap)
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 470884
:
348828
|
348830
|
348832
|
348908
|
349604
|
349608
|
350476
|
350478
|
350480
|
350482
|
350484
|
350486
|
376194
| 376196 |
376198
|
459426
|
459428
|
459430
|
459432
|
459434