List Info

Thread: Re: Automatic creation of target directories




Re: Automatic creation of target directories
country flaguser name
Croatia
2007-05-10 05:02:07
Craig wrote:
> What's the advantage Alen? Are you struggling for an
optimization? ;)

Yeah... optimization of my time writing a matching MkDir for
each target
file created, and tracking down the instances where I forgot
it. 

Anyway, I did the change here:

==== make1.c#18 (text) ====

            if( t->actions )
            {
+         /* Prepare its dir first. */
+         if ( ! (t->flags&T_FLAG_NOTFILE) ) {
+           makefiledir(t->boundname);
+         }
+ 
                ++counts->total;
  
                if( DEBUG_MAKE && !(
counts->total % 100 ) )
-----------------

And it works well. Btw, makefiledir() is a function I added
previously, for some other changes I made. I can provide the
source
for it if someone wants it.

Cheers,
Alen

_______________________________________________
jamming mailing list  -  jammingperforce.com
http://maillist.perforce.com/mailman/listinfo/jamming

Re: Automatic creation of target directories
country flaguser name
Germany
2007-05-10 05:46:20
On 2007-05-10 at 12:02:07 [+0200], Alen Ladavac
<alenl-mlcroteam.com> 
wrote:
> Craig wrote:
> > What's the advantage Alen? Are you struggling for
an optimization? ;)
> 
> Yeah... optimization of my time writing a matching
MkDir for each target
> file created, and tracking down the instances where I
forgot it. 

Since you have to locate your targets anyway, why don't you
use MakeLocate, 
which also invokes MkDir?

CU, Ingo
_______________________________________________
jamming mailing list  -  jammingperforce.com
http://maillist.perforce.com/mailman/listinfo/jamming

[1-2]

about | contact  Other archives ( Real Estate discussion Medical topics )