Sorry, doesn't work. I tried changing the GCC=gcc-4.0 in the null.rules, but no avail.
On Sat, Nov 14, 2009 at 1:55 AM, Razvan Musaloiu-E. <[email protected]> wrote: > Hi! > > On Sat, 14 Nov 2009, Enzeneer wrote: > >> Hi, >> >> It occurs whenever I try to build a Java program and target=null is >> specified in the Makefile. For example in the Oscilloscope app. >> > > Can you give another try of the latest CVS? I just committed a fix for the > null too. :D > > All the best! > Razvan ME > >> Now I found that if I change the target=telosb or target=$(PLATFORM), >> then it builds without problem. >> >> The errors when target=null is specified are as below: >> >> make mig -target=null -java-classname=OscilloscopeMsg java >> ../Oscilloscope.h oscilloscope -o OscilloscopeMsg.java In file >> included from /usr/include/string.h:148, from >> /Users/abhay/Developer/Source/tinyos-2.x/tos/system/tos.h:13: >> /usr/include/secure/_string.h: In function `__inline_memcpy_chk': >> /usr/include/secure/_string.h:58: warning: return makes pointer from >> integer without a cast /usr/include/secure/_string.h: In function >> `__inline_memmove_chk': /usr/include/secure/_string.h:69: warning: >> return makes pointer from integer without a cast >> /usr/include/secure/_string.h: In function `__inline_memset_chk': >> /usr/include/secure/_string.h:80: warning: return makes pointer from >> integer without a cast /usr/include/secure/_string.h: In function >> `__inline_strcpy_chk': /usr/include/secure/_string.h:91: warning: >> return makes pointer from integer without a cast >> /usr/include/secure/_string.h: In function `__inline_stpcpy_chk': >> /usr/include/secure/_string.h:103: warning: return makes pointer from >> integer without a cast /usr/include/secure/_string.h: In function >> `__inline_strncpy_chk': /usr/include/secure/_string.h:116: warning: >> return makes pointer from integer without a cast >> /usr/include/secure/_string.h: In function `__inline_strcat_chk': >> /usr/include/secure/_string.h:127: warning: return makes pointer from >> integer without a cast /usr/include/secure/_string.h: In function >> `__inline_strncat_chk': /usr/include/secure/_string.h:139: warning: >> return makes pointer from integer without a cast In file included from >> /Users/abhay/Developer/Source/tinyos-2.x/tos/system/tos.h:14: >> /usr/include/stdlib.h: At top level: /usr/include/stdlib.h:272: syntax >> error before `^' /usr/include/stdlib.h:272: `type name' declared as >> function returning a function /usr/include/stdlib.h:274: syntax error >> before `^' /usr/include/stdlib.h:274: `type name' declared as function >> returning a function /usr/include/stdlib.h:301: syntax error before >> `^' /usr/include/stdlib.h:301: `type name' declared as function >> returning a function /usr/include/stdlib.h:307: syntax error before >> `^' /usr/include/stdlib.h:307: `type name' declared as function >> returning a function /usr/include/stdlib.h:313: syntax error before >> `^' /usr/include/stdlib.h:313: `type name' declared as function >> returning a function /usr/include/stdlib.h:319: syntax error before >> `^' /usr/include/stdlib.h:319: `type name' declared as function >> returning a function In file included from >> /Users/abhay/Developer/Source/tinyos-2.x/tos/system/SchedulerBasicP.nc:41, >> from >> /Users/abhay/Developer/Source/tinyos-2.x/tos/system/TinySchedulerC.nc:40: >> /Users/abhay/Developer/Source/tinyos-2.x/tos/platforms/null/hardware.h: >> In function `__nesc_ntoh_afloat': >> /Users/abhay/Developer/Source/tinyos-2.x/tos/platforms/null/hardware.h:22: >> warning: pointer/integer type mismatch in conditional expression >> /Users/abhay/Developer/Source/tinyos-2.x/tos/platforms/null/hardware.h: >> In function `__nesc_hton_afloat': >> /Users/abhay/Developer/Source/tinyos-2.x/tos/platforms/null/hardware.h:27: >> warning: pointer/integer type mismatch in conditional expression In >> file included from >> /Users/abhay/Developer/Source/tinyos-2.x/tos/system/TinySchedulerC.nc:40: >> In component `SchedulerBasicP': >> /Users/abhay/Developer/Source/tinyos-2.x/tos/system/SchedulerBasicP.nc: >> In function `Scheduler.init': >> >> /Users/abhay/Developer/Source/tinyos-2.x/tos/system/SchedulerBasicP.nc:117: >> warning: pointer/integer type mismatch in conditional expression >> failed to parse message file ../Oscilloscope.h make: *** >> [OscilloscopeMsg.java] Error 1 >> >> The same thing with target=telosb: >> >> make >> mig -target=telosb -java-classname=OscilloscopeMsg java >> ../Oscilloscope.h oscilloscope -o OscilloscopeMsg.java >> ncg -target=telosb -java-classname=Constants java ../Oscilloscope.h >> NREADINGS DEFAULT_INTERVAL -o Constants.java >> javac *.java >> jar cf oscilloscope.jar *.class >> >> Hope this helps. >> >> Abhay >> >> On Fri, Nov 13, 2009 at 11:52 PM, Razvan Musaloiu-E. <[email protected]> >> wrote: >>> >>> Hi! >>> >>> On Fri, 13 Nov 2009, Enzeneer wrote: >>> >>>> Cool! >>>> This works, but I still have problems compiling some of the other >>>> applications that reference stdlib.h. >>>> Can you point me to some information about mig? How does it select the >>>> gcc version? >>> >>> Can you indicate the steps to reproduce this problem? :P The stuff in >>> RadioCountToLeds worked fine for me. >>> >>> -- >>> Razvan ME >>> >>>> On Fri, Nov 13, 2009 at 9:24 PM, Razvan Musaloiu-E. <[email protected]> >>>> wrote: >>>>> >>>>> Hi! >>>>> >>>>> On Fri, 13 Nov 2009, Maciej Franecki wrote: >>>>> >>>>>> it seems that I (maybe partially..) solved it. >>>>>> >>>>>> >>>>>> That's what I've done: >>>>>> installed gcc 4.3.4 from macports >>>>>> changed gcc soft link (in /usr/bin) to point the new version >>>>>> >>>>>> and: >>>>>> *** Successfully built micaz TOSSIM library >>>>>> >>>>> >>>>> I committed some fixes that make it possible to use the gcc 4.0.1 that >>>>> comes with 10.6. If you update to the latest CVS and edit the GCC from >>>>> sim.extra should to point to gcc-4.0 it should work fine. >>>>> >>>>> The ugly details: 10.6 comes with something called C Blocks. The gcc >>>>> 4.2.1 >>>>> has them enable by default and disabling them is a little tricky >>>>> (passind >>>>> -D__BLOCKS__=0 generates a warning). The good news is that gcc 4.0.1 >>>>> does >>>>> not so it works fine. The only other thing I did was to add to the >>>>> flags >>>>> -D_FORTIFY_SOURCE=0 (to avoid another set of errors). >>>>> >>>>> [1] http://thirdcog.eu/pwcblocks/ >>>>> >>>>> All the best! >>>>> Razvan ME >>>>> >>>>>> >>>>>> did some basic tests in python and (as for now) it seems to be >>>>>> working. >>>>>> >>>>>> >>>>>> Cheers, >>>>>> Maciej >>>>> >>>>> _______________________________________________ >>>>> Tinyos-help mailing list >>>>> [email protected] >>>>> >>>>> https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help >>>>> >>>> >>> >> > _______________________________________________ Tinyos-help mailing list [email protected] https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help
