I'm sorry but my knowledge of makefile construction stopped accreting
around 1990 so the TOS inner make workings are pretty much opaque to me.
try: man make in the bash shell to see some more modern instructions.
However the general makefile structure is:
tagname: things it is dependent on
instructions for making tagname
more instruction...
<new tagname>
where each of "things" "it" "is" "dependent" "on" should exist as
other "tagname:" type definitions (or as some expansion of possibly
headslappingly obscure internal rules, usually having to do with
extensions like .c->.o, etal).
I'm not sure what you mean with your first question on "main_struct
and sub_struct". If they are nested structures, I don't know if MIG
is smart enough to handle it. If what you want is to make two different
TOS_Msg structures, they you should be able to do that with two separate
struct header files and just copy and modify whatever lines work in the
makefile.
I also don't know where you're going with
BUILD_EXTRA_DEPS: MainMsg.class;BeaconMsg.class -
but a semi-colon ';' is probably no thing to use at the time, try
a space instead ' '. And I'm not sure if the dash '-' is significant
to something or not.
As a wild guess after writing all this, perhaps you are trying to make
two TOS_Msg structs and BUILD_EXTRA_DEPS is called someplace in your
makefile to do one already, so maybe all you really wanted to do is:
BUILD_EXTRA_DEPS: MainMsg.class BeaconMsg.class
But (assuming that MainMsg.class was the thing that worked already) I think
you may find some more instructions for it in the makefile which you will
need to replicate for your BeaconMsg.class....
If you still have trouble you should post the whole makefile and the output.
MS
Muhammad Azhar wrote:
Hi Michael, thanks for showing me how to modify data received, it really
helped.
For now, I'm really wondering if it's possible to show more than one
structure in the mig Java output. 'Coz in the tutorial, we were only
taught how to show messages from one structure. Supposing I have more
than one structure, call them main_struct and sub_struct, instead of
just outputting main_struct, is there a way for me to output sub_struct
as well as main_struct in a single Makefile? Which part of the Makefile
command do I need to modify?
Out of curiosity, I tried to modify my Makefile BUILD_EXTRA_DEPS:
MainMsg.class;BeaconMsg.class - but this doesn't work (and did the same
mig java for Beacon as how I did my Main, but well....) :(
error msg:
mkdir -p build/telosb
BeaconMsg.class FORCE
make: BeaconMsg.class: Command not found
make: *** [exe0] Error 127
Thanks.
Regards,
Azhar
_______________________________________________
Tinyos-help mailing list
[email protected]
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help