Re: sorting through xlibs-dev dependencies?
On Sun, 2004-12-19 at 00:04, Bartosz Fenski aka fEnIo wrote:
> On Sat, Dec 18, 2004 at 10:39:37PM +0000, Helen Faulkner wrote:
> > Hi,
> > I hope this isn't a too dumb question!
> > I'm the maintainer for xwrits, and partway through the NM process. My
> > application manager (Frank Lichtenheld) has sent me a review of my
> > packages, and I am confused about one of the things he suggested I do.
> > xwrits currently depends on xlibs-dev. Frank suggests that I replace that
> > with only the needed dependencies.
> > What I am confused about is how to tell what it really needs and what it
> > doesn't really need. I don't know that much about X, in general.
> > xlibs-dev seems to be a package that does nothing but depend on a
> > collection of many different X libraries. But I don't know what all those
> > libraries do (and no, I don't want to read the code for all of them!).
> > So, the only thing I thought to do is
> > a) look at every header file that is #included in the xwrits code
> > b) use dlocate or similar to see which packages all those headers are in.
> > c) make xwrits build-depend on those packages.
> > But this will take me quite a long time. I wondered if I am missing
> > something obvious and there is a better way to do it. Or am I on the right
> > track after all.
> > Now, obviously, I don't want someone to actually tell me which things I
> > should be build-depending on. I want to know how to work out such things
> > for myself in the future :) (It would also defy the point of my AM asking
> > me this.) But I would appreciate a hint...
> Well I would do it this way:
> (fenio@domek)~$ldd /usr/bin/xwrits | grep X11R6
> libSM.so.6 => /usr/X11R6/lib/libSM.so.6 (0x40025000)
> libICE.so.6 => /usr/X11R6/lib/libICE.so.6 (0x4002e000)
> libX11.so.6 => /usr/X11R6/lib/libX11.so.6 (0x40045000)
> libXext.so.6 => /usr/X11R6/lib/libXext.so.6 (0x4010d000)
> Then I would do `dpkg -S libSM.so.6` and similar for every other library.
> Then just take -dev version of every package.
> This should be enough. You can always ensure using pbuilder.
For another approach, somewhat more automated, have a look at
dpkg-depcheck(1) from the devscripts package. Not that I disagree with
fenio's method - there's just more than one way to do it :-)