Gentoo Archives: gentoo-user

From: Alan McKinnon <alan.mckinnon@×××××.com>
To: gentoo-user@l.g.o
Cc: Grant <emailgrant@×××××.com>
Subject: Re: [gentoo-user] Can you rewrite this 1996 qfile command?
Date: Mon, 18 Jan 2010 18:10:16
Message-Id: 201001182008.00804.alan.mckinnon@gmail.com
In Reply to: Re: [gentoo-user] Can you rewrite this 1996 qfile command? by Grant
1 On Monday 18 January 2010 17:12:41 Grant wrote:
2
3 > > # qlist -o $(qlist -ICv) | scanelf -Bs__guard -qf - -F%F#s | xargs qfile
4 > > Usage: qfile <opts> <filename> : list all pkgs owning files
5 > >
6 > > Options: -[ef:m:oRx:vqChV]
7 > > -e, --exact * Exact match
8 > > -f, --from <arg> * Read arguments from file <arg> ("-" for stdin)
9 > > -m, --max-args <arg> * Treat from file arguments by groups of <arg>
10 > > (defaults to 5000)
11 > > -o, --orphans * List orphan files
12 > > -R, --root-prefix * Assume arguments are already prefixed by $ROOT
13 > > -x, --exclude <arg> * Don't look in package <arg>
14 > > -v, --verbose * Make a lot of noise
15 > > -q, --quiet * Tighter output; suppress warnings
16 > > -C, --nocolor * Don't output color
17 > > -h, --help * Print this help and exit
18 > > -V, --version * Print version and exit
19 > >
20 > > Does anyone know what might be wrong?
21 > >
22 > > - Grant
23 >
24 > I think the problem above is that -I isn't a current option of qfile,
25 > but removing it produces the error I originally posted about:
26 >
27 > qlist: invalid option -- '['
28 >
29 > - Grant
30
31 It does look like your qlist is out of date and giving you a --help summary
32 which the outer qlist tries to interpret, and fails.
33
34 If you can't update the package qlist comes from, you might get by with
35 replacing the inner qlist with equery. It gives output like this:
36
37 $ equery --quiet list '*'
38 app-admin/apache-tools-2.2.14
39 app-admin/apg-2.3.0b-r4
40 app-admin/empower-9999
41
42
43 which looks the same as the output from qlist -ICv:
44
45 $ qlist -ICv | head -n3
46 app-admin/apache-tools-2.2.14
47 app-admin/apg-2.3.0b-r4
48 app-admin/empower-9999
49
50 This requires gentoolkit-0.3* which is ~
51
52
53 --
54 alan dot mckinnon at gmail dot com