Bug 27595 - dwz -o outfile with implicit file argument
Summary: dwz -o outfile with implicit file argument
Status: NEW
Alias: None
Product: dwz
Classification: Unclassified
Component: default (show other bugs)
Version: unspecified
: P2 normal
Target Milestone: ---
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-03-17 13:26 UTC by Tom de Vries
Modified: 2021-03-22 05:43 UTC (History)
1 user (show)

See Also:
Host:
Target:
Build:
Last reconfirmed:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Tom de Vries 2021-03-17 13:26:13 UTC
Consider this session:
...
$ rm -f a.out b.out
$ gcc ~/hello.c -g
$ ls a.out
a.out
$ dwz -o b.out
$ ls b.out
b.out
$
...

The advertised usage looks like this:
...
$ ./dwz -?
Usage:
  ./dwz [common options] [-h] [-m COMMONFILE] [-M NAME | -r] [FILES]
  ./dwz [common options] -o OUTFILE FILE
  ./dwz [ -v | -? ]
...

But the actual dwz use we did above suggests instead:
...
  ./dwz [common options] -o OUTFILE [ FILE ]
...

So, we should either update the advertised usage, or require an explicit file when using -o.
Comment 1 Tom de Vries 2021-03-22 05:43:57 UTC
Posted patch: https://sourceware.org/pipermail/dwz/2021q1/001156.html