This is the mail archive of the mailing list for the Cygwin 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]

Re: mknetrel: sub-package splitting, 2nd try

Charles Wilson <> writes:

> libpng12:
>    mkdir -p $inst-libpng12/usr/bin
>    mv $inst/usr/bin/cygpng-12.dll $inst-libpng12/usr/bin/
>    cd $inst-libpng12
>    tar cvjf libpng12.tar.bz2 *
> vs.
>    cd $inst
>    tar cvjf libpng12.tar.bz2 usr/bin/cyg*.dll

Hmm.  Less code good.  However, you'll need a list to specify what
goes into the main package too, which is not needed in my example.
That may cost more code, and be unnecessarily specific for every

Otoh, you could have tar remove the files you already packaged

    tar --remove-files -cvjf libguile14.tar.bz2 usr/bin/cyg*.dll usr/share/guile
but you'll have to find and remove empty dirs too, if you go that way.

> You're assuming -- and it may be a safe assumption -- that all
> splitting will be done via one of two methods:
>    1) separate make install-* targets
>    2) whole subtrees

No, I think that most splitting can be handled generically, by

    1) separate make install-* targets
    2) whole subtrees
    3) shell globbing (eg, /usr/bin/cyg*.dll)

and that for most cases that need special attention, 1 2 and 3 will be
a useful preparation, and only need

    4) custom stuff.

and that 'all the rest' (ie, stuff that's not a special kind of doc,
library or include file), mostly goes into the main package: no
specification needed.

> actual archive.  Kinda silly, BUT, having said all of that:
> I think your assumptions are probably safe, in general, and lead to a
> nice understandable structure in mknetrel's code.  I can double tar if
> I need to.

Indeed, I don't care so much *what* method we choose, but I would like
to avoid stupid code duplication, if we can do that without trying too
hard to be too generic.


Jan Nieuwenhuizen <> | GNU LilyPond - The music typesetter       |

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