bruce.dubbs at gmail.com
Fri Feb 5 19:48:42 PST 2010
Simon Geard wrote:
> On Fri, 2010-02-05 at 10:43 -0600, Mike McCarty wrote:
>> Simon Geard wrote:
>>> But in practice, writing your own tool to do it is entirely unnecessary,
>>> since that's exactly what 'make' does. Just write a Makefile expressing
>>> dependencies, and let it do the job for you. For example:
>> The tool I had in mind would be the thing that wrote the
>> Makefile, so make isn't up to that. make would process
>> the output of the program.
> Right. One program to extract the dependencies from the book, and Make
> to turn those dependencies into an ordered list. The latter isn't
> exactly hard to write yourself, but there's little point when LFS comes
> with a standard tool for the purpose.
The program I pointed to earlier in the thread does this for BLFS. The
output (blfs.dot) looks like:
k3b -> kdelibs [label="Required"];
k3b -> cdrtools [label="Required"];
k3b -> dvd_rw_tools [label="Required"];
k3b -> cdrdao [label="Required"];
Writing something to parse it and write out something like:
k3b: kdelibs cdrtools dvd_rw_tools cdrdao
Wouldn't be hard.
You'd have to add the few packages without dependencies in another way.
For extra credit, add indentation to the printout.
More information about the blfs-support