This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH 0/3] binutils: read from stdin if input file is -


Changes behavior of dlltool, nlmconv, nm, objcopy, objdump and size
to allow niftiness like:

    printf "\xCC" | objdump -D -bbinary -mi386 -

Affects the layout of struct bfd as well. Is this ok?
Decided against adding an .is_stdin bit, because the thought of
inadvertently deleting files due to mismatched libbfd was unpleasant

Copyright assignment is in place. `make -C binutils check` runs through.

--

bfd/
	* bfd.c (struct bfd): Add optional temp_filename field that points
	at file to be removed when closing bfd.
	* bfd-in2.h: Regenerate.
        * opencls.c (bfd_open): read stdin if filename == NULL
binutils/
	* nm.c:      const-qualify read-only string parameters
    * nm.c:      read from stdin if input file is -
    * dlltool.c: read from stdin if input file is -
    * nlmconv.c: read from stdin if input file is -
    * objcopy.c: read from stdin if input file is -
    * objdump.c: read from stdin if input file is -
    * size.c:    read from stdin if input file is -
 

Ahmad Fatoum (3):
  bfd_fopen: read from stdin if filename == NULL
  nm: const-qualify read-only string parameters
  binutils: read from stdin if input file is -

 bfd/bfd-in2.h      |  3 +++
 bfd/bfd.c          |  3 +++
 bfd/opncls.c       | 66 ++++++++++++++++++++++++++++++++++++++++++++++++------
 binutils/dlltool.c |  9 +++++++-
 binutils/nlmconv.c |  5 ++++-
 binutils/nm.c      | 56 +++++++++++++++++++++++++--------------------
 binutils/objcopy.c | 38 ++++++++++++++++++++++++-------
 binutils/objdump.c | 10 +++++++--
 binutils/size.c    | 10 +++++++--
 9 files changed, 155 insertions(+), 45 deletions(-)

-- 
2.16.1


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]