[Tinyos-devel] Re: [Tinyos-help] .platform question

Philip Levis pal at cs.stanford.edu
Mon Dec 17 10:01:02 PST 2007


On Dec 17, 2007, at 9:45 AM, Kevin Klues wrote:

> Why even have the %T then?  You can always use $TOSDIR or  
> explicitly write out the path each time you want to reference it.   
> Its there purely for convenience (its not in fact a 'parameter' to  
> the compiler in the sense of a command line parameter.  Look at how  
> ncc deals with the %T... it just looks up what TOSDIR is and  
> replaces it).

Well, %T is part of the TinyOS directory structure, and ncc is bound  
to that (it's in tools/).

> While I agree it might be a social construct that contrib is in a  
> separate tree in T2, that doesn't mean we can ignore this fact.   
> When someone checks out contrib from sourceforge they have the  
> freedom to place it anywhere in their directory heirarchy that they  
> like.  The only way we could have makerules 'derive' contrib from  
> TOSROOT is if we force users to place their contrib directory at  
> some location underneath the tinyos-2.x tree heirarchy.  I  
> personally, like to leave it outside......  To deal with this, I  
> simply set a new environment variable that points to my  
> TOSCONTRIBROOT and reference everything from there.  Adding the %C  
> to ncc would just allow %C to stand in place of $TOSCONTRIBROOT  
> just like %T stands in place of $TOSDIR.  I personally don't see  
> anything wrong with doing this.....

I'm against adding additional complexity/features/environment  
variables to save 10 characters.

Someone please correct me if I'm wrong, but one major motivation for % 
T was .platform, where you can't apply make variable substitution.

Phil


More information about the Tinyos-devel mailing list