Re: Create a shar file

Gary Oberbrunner <[email protected]> Thu, 19 Sep 2002 09:23:03 -0400
Newsgroups gmane.comp.gnu.cons.general
Message-ID <[email protected]>
If all your fooN files exist at the beginning of the cons run, it's 
easy: just do something like
   $e->Command('foo.shar', glob('foo_dir/foo*'), 'shar %< > %>');
You may have to fiddle with the glob to, for instance, set the current 
directory before globbing and/or prepend '#' to the filenames so cons 
sees them as top-relative.  But it's just perl.

If they *don't* exist before the cons run, it's trickier.  You'll have 
to use AfterBuild to run after the command which creates the fooN files 
to add them to the dependency list of the foo.shar target.

I hear scons can handle directories as dependencies, but I don't know if 
it will handle this particular case well or not.

BUFFERNE,VINCENT (HP-France,ex1) wrote:
> I would like to shar the foo files during the compilation without having 
> to specify the name of the foo files (I have hundreds of them so I do 
> not want to maintain such a huge list of file names) .
> I have tried to use "Command", but it needs files in parameter and not 
> directories....

-- 
. . . . . . . . . . . . . . . . . . . . . . . . .
Gary Oberbrunner                [email protected]
GenArts, Inc.                   Tel: 617-492-2888
8 Clinton Street                Fax: 617-492-2852
Cambridge, MA 02139 USA         http://web.genarts.com




_______________________________________________
[email protected]
http://mail.gnu.org/mailman/listinfo/cons-discuss
Cons URL: http://www.dsmit.com/cons/