[Tinyos-help] .platform question

Philip Levis pal at cs.stanford.edu
Mon Dec 17 08:34:04 PST 2007


On Dec 15, 2007, at 4:26 PM, Kevin Klues wrote:

>
> I like the idea of using a %C directive as a shorthand for finding  
> the contrib directory.  Given that contrib is starting in its  
> number of users, having such a feature would be nice.  To make this  
> happen, we first need to decide on a standard environment variable  
> that users of contrib must define.  How about TOSCONTRIBROOT?  Then  
> just a few changes need to me made to ncc to allow %C to be  
> recognized.
>
> Does anyone have any objections to adding this?  If not, I'll go  
> ahead and do it sometime this week.

I do. Why should contrib -- a social construction that happens to be  
the way it is mostly due to sourceforge licensing and CVS checkout  
structure -- determine parameters to the compiler? If contrib were in  
tinyos-2.x (as it is in 1.x), then this would not be necessary. It's  
not very hard in a Makefile to

RCHIPS=/opt/tinyos-2.x/contrib/rincon/tos/chips

CFLAGS +=$(RCHIPS)/cc2420 $(RCHIPS)/at45db

It might make more sense to define a variable in Makerules that  
derives contrib from TOSDIR/TOSROOT. Application makefiles can  
override it, etc.

Phil


More information about the Tinyos-help mailing list