Re: unknown error after dwarf_cfi_addrframe()
Does it work at all if you use the standard RH installed version of elfutils? -ben > On Feb 12, 2019, at 9:57 AM, Sasha Da Rocha Pinheiro > wrote: > > Not working even after adding the directory to libebl_*.so to > LD_LIBRARY_PATH. > default_abi_cfi is still called returning -1. > > Sasha > > > > From: Mark Wielaard > Sent: Tuesday, February 12, 2019 2:09 AM > To: Sasha Da Rocha Pinheiro > Cc: elfutils-devel@sourceware.org; Ben Woodard > Subject: Re: unknown error after dwarf_cfi_addrframe() > > On Tue, Feb 12, 2019 at 07:25:28AM +, Sasha Da Rocha Pinheiro wrote: >> Oh this is a whole new thing. How have this worked before without those .so? >> After downloading and compiling elfutils we only copy libdw and libelf. > > The backends are only used for architecture specific ELF things. > Most of DWARF can be understood in an architecture independent way. > But CFI does have some arch specific things. > > You should really use make install to get a proper installation, > not just copy some files. Otherwise you might indeed miss the > backends, or translations, etc. > > Cheers, > > Mark
[PATCH] Begin adding some docs to elfutils
- Added doc/README - Updated doc/ChangeLog - Added a eu-readelf manpage based on the one from binutils. - Added a brand new manpage for eu-elfclassify the new utility added in 0.177 - Add some new files in the doc directory and sync makefile with upstream. - Reenable the compilation of doc directory. - Disable sgml file building - Build man pages the automake way --- Makefile.am | 3 +- configure.ac | 3 +- doc/ChangeLog| 17 ++ doc/Makefile.am | 4 +- doc/README | 20 ++ doc/elf_begin.3 | 37 +++ doc/elf_clone.3 | 14 + doc/elf_getdata.3| 28 ++ doc/elf_update.3 | 14 + doc/eu-elfclassify.1 | 197 doc/eu-readelf.1 | 693 +++ 11 files changed, 1025 insertions(+), 5 deletions(-) create mode 100644 doc/README create mode 100644 doc/elf_begin.3 create mode 100644 doc/elf_clone.3 create mode 100644 doc/elf_getdata.3 create mode 100644 doc/elf_update.3 create mode 100644 doc/eu-elfclassify.1 create mode 100644 doc/eu-readelf.1 diff --git a/Makefile.am b/Makefile.am index 2ff444e7..9f2ece49 100644 --- a/Makefile.am +++ b/Makefile.am @@ -26,9 +26,8 @@ AM_MAKEFLAGS = --no-print-directory pkginclude_HEADERS = version.h -# Add doc back when we have some real content. SUBDIRS = config m4 lib libelf libebl libdwelf libdwfl libdw libcpu libasm \ - backends src po tests + backends src po doc tests EXTRA_DIST = elfutils.spec GPG-KEY NOTES CONTRIBUTING \ COPYING COPYING-GPLV2 COPYING-LGPLV3 diff --git a/configure.ac b/configure.ac index c443fa3b..30429e29 100644 --- a/configure.ac +++ b/configure.ac @@ -497,8 +497,7 @@ AC_SUBST([argp_LDADD]) dnl The directories with content. dnl Documentation. -dnl Commented out for now. -dnl AC_CONFIG_FILES([doc/Makefile]) +AC_CONFIG_FILES([doc/Makefile]) dnl Support library. AC_CONFIG_FILES([lib/Makefile]) diff --git a/doc/ChangeLog b/doc/ChangeLog index 380a0cd7..7d2affce 100644 --- a/doc/ChangeLog +++ b/doc/ChangeLog @@ -1,3 +1,20 @@ +2019-08-21 Ben Woodard + + * Updated Changelog + * Added README + +2019-08-20 Ben Woodard + + * Added eu-elfclassify.1 man page based upon --help + * Forked binutils readelf page to make eu-readelf.1 man page + * Modified eu-readelf.1 to add -n:: option. + * Disabled sgml file building per mjw. + * Added man pages to Makefile.am + +2019-06-20 Ben Woodard + + * Added the beginnings of some man pages + 2005-04-29 Ulrich Drepper * elfutils.sgml: Some typo fixes and a few extensions. diff --git a/doc/Makefile.am b/doc/Makefile.am index 44f0c11a..e8a0a189 100644 --- a/doc/Makefile.am +++ b/doc/Makefile.am @@ -16,7 +16,9 @@ ## ## You should have received a copy of the GNU General Public License ## along with this program. If not, see <http://www.gnu.org/licenses/>. -EXTRA_DIST = elfutils.sgml +# EXTRA_DIST = elfutils.sgml +man3_MANS=eu-readelf.1 eu-elfclassify.1 elf_update.3 elf_getdata.3 \ +elf_clone.3 elf_begin.3 CLEANFILES = elfutils.dvi diff --git a/doc/README b/doc/README new file mode 100644 index ..3231b394 --- /dev/null +++ b/doc/README @@ -0,0 +1,20 @@ +The elfutils documentation is very much a work in +progress. Contributions are welcome. +Please reports bugs at https://sourceware.org/bugzilla/ +Please send additions and patches to: elfutils-devel@sourceware.org + +Currently, the elfutils utilities are a new implementation of many of +the utilities found in binutils and consequently, the documentation +for most of the tools has been the the man pages for binutils. For +example you could refer to readelf's man page for instructions on +eu-readelf. This has been fine up until this point but as tools gain +new capabilities, they will need to have their own individual man +page. Forking the man pages from binutils is acceptable and the +current plan of action. + +New utilities that do not have an analog in binutils can have their +initial man pages generated using a tool like help2man. + +The C language interfaces for libelf, libdw, and libdwfl are in +particular need of documentation. The aspirational goal is write these +in sphinx. \ No newline at end of file diff --git a/doc/elf_begin.3 b/doc/elf_begin.3 new file mode 100644 index ..e00b60bf --- /dev/null +++ b/doc/elf_begin.3 @@ -0,0 +1,37 @@ +.\" Modified Thu Sep 5 2017 by Ben Woodard +.\" +.TH ELF_BEGIN 3 2017-09-05 "Libelf" "Libelf Programmer's Manual" +.SH NAME +elf_begin \— Return descriptor for ELF file. +.nf +.SH SYNOPSIS +.B #include +.sp +.BI "Elf *elf_begin (int " filedes ", Elf_Cmd " cmd ", Elf *" ref ");" +.BI "Elf *elf_clone (int " filedes ", Elf_Cmd " cmd ");" +.BI "int elf_end (Elf *" elf ");" +.fi +.SH DESCRIPTION +The +.BR elf_begin () +.SH RETURN VALUE +.SH ERRORS +elf_begin ELF_
[PATCH] V2 Begin adding some docs to elfutils
- Added doc/README - Updated doc/ChangeLog - Added a eu-readelf manpage based on the one from binutils. - Added a brand new manpage for eu-elfclassify the new utility added in 0.177 - Add some new files in the doc directory and sync makefile with upstream. - Reenable the compilation of doc directory. - Disable sgml file building - Build man pages the automake way Since V1 - Put man pages in the proper directories. - Added copy of Gnu Free Documentation License - Modified eu-readelf.1 man page to match the supported options. Signed-off-by: Ben Woodard --- Makefile.am | 3 +- configure.ac | 3 +- doc/COPYING | 455 ++ doc/ChangeLog| 41 +++ doc/Makefile.am | 4 +- doc/README | 20 ++ doc/elf_begin.3 | 37 +++ doc/elf_clone.3 | 14 + doc/elf_getdata.3| 28 ++ doc/elf_update.3 | 14 + doc/eu-elfclassify.1 | 197 + doc/eu-readelf.1 | 638 +++ 12 files changed, 1449 insertions(+), 5 deletions(-) create mode 100644 doc/COPYING create mode 100644 doc/README create mode 100644 doc/elf_begin.3 create mode 100644 doc/elf_clone.3 create mode 100644 doc/elf_getdata.3 create mode 100644 doc/elf_update.3 create mode 100644 doc/eu-elfclassify.1 create mode 100644 doc/eu-readelf.1 diff --git a/Makefile.am b/Makefile.am index 2ff444e7..9f2ece49 100644 --- a/Makefile.am +++ b/Makefile.am @@ -26,9 +26,8 @@ AM_MAKEFLAGS = --no-print-directory pkginclude_HEADERS = version.h -# Add doc back when we have some real content. SUBDIRS = config m4 lib libelf libebl libdwelf libdwfl libdw libcpu libasm \ - backends src po tests + backends src po doc tests EXTRA_DIST = elfutils.spec GPG-KEY NOTES CONTRIBUTING \ COPYING COPYING-GPLV2 COPYING-LGPLV3 diff --git a/configure.ac b/configure.ac index c443fa3b..30429e29 100644 --- a/configure.ac +++ b/configure.ac @@ -497,8 +497,7 @@ AC_SUBST([argp_LDADD]) dnl The directories with content. dnl Documentation. -dnl Commented out for now. -dnl AC_CONFIG_FILES([doc/Makefile]) +AC_CONFIG_FILES([doc/Makefile]) dnl Support library. AC_CONFIG_FILES([lib/Makefile]) diff --git a/doc/COPYING b/doc/COPYING new file mode 100644 index ..98310abe --- /dev/null +++ b/doc/COPYING @@ -0,0 +1,455 @@ +This license applies to the eu-readelf.1 man page which was forked +from the binutils readelf version of the man page. The rest of the +documentation is provided under the license found in the top level +directory. + +GNU Free Documentation License + Version 1.3, 3 November 2008 + + + Copyright (C) 2000, 2001, 2002, 2007, 2008 Free Software Foundation, Inc. + <https://fsf.org/> + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + +0. PREAMBLE + +The purpose of this License is to make a manual, textbook, or other +functional and useful document "free" in the sense of freedom: to +assure everyone the effective freedom to copy and redistribute it, +with or without modifying it, either commercially or noncommercially. +Secondarily, this License preserves for the author and publisher a way +to get credit for their work, while not being considered responsible +for modifications made by others. + +This License is a kind of "copyleft", which means that derivative +works of the document must themselves be free in the same sense. It +complements the GNU General Public License, which is a copyleft +license designed for free software. + +We have designed this License in order to use it for manuals for free +software, because free software needs free documentation: a free +program should come with manuals providing the same freedoms that the +software does. But this License is not limited to software manuals; +it can be used for any textual work, regardless of subject matter or +whether it is published as a printed book. We recommend this License +principally for works whose purpose is instruction or reference. + + +1. APPLICABILITY AND DEFINITIONS + +This License applies to any manual or other work, in any medium, that +contains a notice placed by the copyright holder saying it can be +distributed under the terms of this License. Such a notice grants a +world-wide, royalty-free license, unlimited in duration, to use that +work under the conditions stated herein. The "Document", below, +refers to any such manual or work. Any member of the public is a +licensee, and is addressed as "you". You accept the license if you +copy, modify or distribute the work in a way requiring permission +under copyright law. + +A "Modified Version" of the Document means any work containing the +Document or a portion of it, either copied verbatim, or with +modifications and/or translated into another language. + +A "Secondary Section" is a na