|
|
|
![]() |
|
|||||||
|
||||||||
![]() |
|
|
Thread Tools |
Rating:
|
Display Modes |
|
|
|
#1
|
||||
|
||||
|
Re: Wind River build environment
Thank you for the pointer. That may be the document I am looking for. I will scan through it tonight to see if it contains information that will solve our issues.
|
|
#2
|
||||
|
||||
|
Re: Wind River build environment
I finally figured out what caused all the errors. Apparently, Wind River by default enabled multiple platforms (PPC32diab, PPC32gnu, PPC603diab and PPC603gnu). If I unchecked everything except for PPC603gnu. All the wierd errors are gone. BTW, is there a document showing me what to pick on the million configurations Project Properties offered me? I used to assume if no document tells me anything, it must be okay to take the default. But apparently not for this case.
After fixing some typos in the code. I was able to compile the project almost error free. However, I still got a few errors that got me scratching my head. For example, it complained about the line: START_ROBOT_CLASS(MyRobot); with the following errors. Code:
Logomotion_partialImage/Debug/Objects/main.o(.text+0x0): In function `FRC_userClassFactory()': C:/Documents and Settings/Administrator/Frc/2011/code/Logomotion/main.cpp:347: multiple definition of `FRC_userClassFactory()' Logomotion_partialImage/Debug/Objects/Logomotion/main.o(.text+0x0):C:/Documents and Settings/Administrator/Frc/2011/code/Logomotion/main.cpp:347: first defined here Logomotion_partialImage/Debug/Objects/main.o(.text+0x134): In function `FRC_UserProgram_StartupLibraryInit': C:/Documents and Settings/Administrator/Frc/2011/code/Logomotion/main.cpp:471: multiple definition of `FRC_UserProgram_StartupLibraryInit' Logomotion_partialImage/Debug/Objects/Logomotion/main.o(.text+0x134):C:/Documents and Settings/Administrator/Frc/2011/code/Logomotion/main.cpp:471: first defined here Logomotion_partialImage/Debug/Objects/main.o(.text+0x224): In function `global constructors keyed to FRC_userClassFactory()': C:/Documents and Settings/Administrator/Frc/2011/code/Logomotion/main.cpp:472: multiple definition of `global constructors keyed to FRC_userClassFactory()' Logomotion_partialImage/Debug/Objects/Logomotion/main.o(.text+0x224):C:/Documents and Settings/Administrator/Frc/2011/code/Logomotion/main.cpp:472: first defined here Logomotion_partialImage/Debug/Objects/main.o(.text+0x26c): In function `global destructors keyed to FRC_userClassFactory()': C:/Documents and Settings/Administrator/Frc/2011/code/Logomotion/main.cpp:473: multiple definition of `global destructors keyed to FRC_userClassFactory()' Logomotion_partialImage/Debug/Objects/Logomotion/main.o(.text+0x26c):C:/Documents and Settings/Administrator/Frc/2011/code/Logomotion/main.cpp:473: first defined here collect2: ld returned 256 exit status if [ ! -d "`dirname "Logomotion/Debug/Logomotion.out"`" ]; then mkdir -p "`dirname "Logomotion/Debug/Logomotion.out"`"; fi;echo "building Logomotion/Debug/Logomotion.out";rm -f "Logomotion/Debug/Logomotion.out";nmppc Logomotion_partialImage/Debug/Logomotion_partialImage.o | tclsh C:/WindRiver/vxworks-6.3/host/resource/hutils/tcl/munch.tcl -c ppc > Logomotion/Debug/ctdt.c; ccppc -g -mcpu=603 -mstrict-align -mno-implicit-fp -mlongcall -fdollars-in-identifiers -Wall -IC:/WindRiver/vxworks-6.3/target/h -IC:/WindRiver/vxworks-6.3/target/h/wrn/coreip -IC:/WindRiver/vxworks-6.3/target/h/WPIlib -DCPU=PPC603 -DTOOL_FAMILY=gnu -DTOOL=gnu -D_WRS_KERNEL -o Logomotion/Debug/ctdt.o -c Logomotion/Debug/ctdt.c;%l inkerprefix% ccppc -r -nostdlib -Wl,-X -T C:/WindRiver/vxworks-6.3/target/h/tool/gnu/ldscripts/link.OUT -o "Logomotion/Debug/Logomotion.out" Logomotion/Debug/ctdt.o Logomotion_partialImage/Debug/Logomotion_partialImage.o && if [ "0" = "1" ]; then plink "Logomotion/Debug/Logomotion.out";fi building Logomotion/Debug/Logomotion.out nmppc: 'Logomotion_partialImage/Debug/Logomotion_partialImage.o': No such file C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp\make209613.sh: %l: command not found C:\WindRiver\vxworks-6.3\host\x86-win32\bin\make.exe: *** [Logomotion/Debug/Logomotion.out] Error 127 Build Failed in Project 'Logomotion' (Process Exit Value was 2): 2011-01-20 22:28:32 (Elapsed Time: 00:04) Code:
Build Started in Project 'Logomotion': 2011-01-20 22:41:39 Generation of makefiles started. Generation of makefiles finished (Elapsed Time: 00:00). Platform: Wind River VxWorks 6.3 Command: make --no-print-directory BUILD_SPEC=PPC603gnu DEBUG_MODE=1 TRACE=1 Working Directory: C:/Documents and Settings/Administrator/Frc/2011/code/Logomotion/PPC603gnu if [ ! -d "`dirname "Logomotion_partialImage/Debug/Objects/Logomotion/main.o"`" ]; then mkdir -p "`dirname "Logomotion_partialImage/Debug/Objects/Logomotion/main.o"`"; fi;echo "building Logomotion_partialImage/Debug/Objects/Logomotion/main.o"; ccppc -g -mcpu=603 -mstrict-align -mno-implicit-fp -mlongcall -ansi -Wall -MD -MP -IC:/WindRiver/vxworks-6.3/target/h -IC:/WindRiver/vxworks-6.3/target/h/wrn/coreip -IC:/WindRiver/vxworks-6.3/target/h/WPIlib -DCPU=PPC603 -DTOOL_FAMILY=gnu -DTOOL=gnu -D_WRS_KERNEL -o "Logomotion_partialImage/Debug/Objects/Logomotion/main.o" -c "C:/Documents and Settings/Administrator/Frc/2011/code/Logomotion/main.cpp" building Logomotion_partialImage/Debug/Objects/Logomotion/main.o if [ ! -d "`dirname "Logomotion_partialImage/Debug/Objects/main.o"`" ]; then mkdir -p "`dirname "Logomotion_partialImage/Debug/Objects/main.o"`"; fi;echo "building Logomotion_partialImage/Debug/Objects/main.o"; ccppc -g -mcpu=603 -mstrict-align -mno-implicit-fp -mlongcall -ansi -Wall -MD -MP -IC:/WindRiver/vxworks-6.3/target/h -IC:/WindRiver/vxworks-6.3/target/h/wrn/coreip -IC:/WindRiver/vxworks-6.3/target/h/WPIlib -DCPU=PPC603 -DTOOL_FAMILY=gnu -DTOOL=gnu -D_WRS_KERNEL -o "Logomotion_partialImage/Debug/Objects/main.o" -c "C:/Documents and Settings/Administrator/Frc/2011/code/Logomotion/main.cpp" building Logomotion_partialImage/Debug/Objects/main.o if [ ! -d "`dirname "Logomotion_partialImage/Debug/Logomotion_partialImage.o"`" ]; then mkdir -p "`dirname "Logomotion_partialImage/Debug/Logomotion_partialImage.o"`"; fi;echo "building Logomotion_partialImage/Debug/Logomotion_partialImage.o"; ccppc -r -nostdlib -Wl,-X -o "Logomotion_partialImage/Debug/Logomotion_partialImage.o" Logomotion_partialImage/Debug/Objects/Logomotion/DashboardDataFormat.o Logomotion_partialImage/Debug/Objects/Logomotion/main.o Logomotion_partialImage/Debug/Objects/main.o && if [ "0" = "1" ]; then plink "Logomotion_partialImage/Debug/Logomotion_partialImage.o";fi building Logomotion_partialImage/Debug/Logomotion_partialImage.o if [ ! -d "`dirname "Logomotion/Debug/Logomotion.out"`" ]; then mkdir -p "`dirname "Logomotion/Debug/Logomotion.out"`"; fi;echo "building Logomotion/Debug/Logomotion.out";rm -f "Logomotion/Debug/Logomotion.out";nmppc Logomotion_partialImage/Debug/Logomotion_partialImage.o | tclsh C:/WindRiver/vxworks-6.3/host/resource/hutils/tcl/munch.tcl -c ppc > Logomotion/Debug/ctdt.c; ccppc -g -mcpu=603 -mstrict-align -mno-implicit-fp -mlongcall -fdollars-in-identifiers -Wall -IC:/WindRiver/vxworks-6.3/target/h -IC:/WindRiver/vxworks-6.3/target/h/wrn/coreip -IC:/WindRiver/vxworks-6.3/target/h/WPIlib -DCPU=PPC603 -DTOOL_FAMILY=gnu -DTOOL=gnu -D_WRS_KERNEL -o Logomotion/Debug/ctdt.o -c Logomotion/Debug/ctdt.c;%l inkerprefix% ccppc -r -nostdlib -Wl,-X -T C:/WindRiver/vxworks-6.3/target/h/tool/gnu/ldscripts/link.OUT -o "Logomotion/Debug/Logomotion.out" Logomotion/Debug/ctdt.o Logomotion_partialImage/Debug/Logomotion_partialImage.o && if [ "0" = "1" ]; then plink "Logomotion/Debug/Logomotion.out";fi building Logomotion/Debug/Logomotion.out C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp\make32928.sh: %l: command not found C:\WindRiver\vxworks-6.3\host\x86-win32\bin\make.exe: *** [Logomotion/Debug/Logomotion.out] Error 127 Build Failed in Project 'Logomotion' (Process Exit Value was 2): 2011-01-20 22:41:43 (Elapsed Time: 00:03) |
|
#3
|
||||
|
||||
|
Re: Wind River build environment
I made more progress. I finally got rid of the multiple definitions of FRC_userClassFactory() error. The way I got rid of it is that since I firmly believe it is the build environment that screwed me up, I created the Line Follower example project. It compiled perfectly. Then I compared the its .wrproject file with my own .wrproject file and did some minor fixes to make them as similar as possible. That works. But don't ask me which change fixed it. It's seems a black box to me. But now I still have one last error:
Code:
C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp\make21408.sh: %l: command not found C:\WindRiver\vxworks-6.3\host\x86-win32\bin\make.exe: *** [Logomotion/NonDebug/Logomotion.out] Error 127 Build Failed in Project 'Logomotion' (Process Exit Value was 2): 2011-01-20 23:41:19 (Elapsed Time: 00:03) |
|
#4
|
||||
|
||||
|
Re: Wind River build environment
Here's what I'm guessing happened. You copied over your 2010 code after installing the Workbench update. Therefore, all the header references in the code to the WPILib were still trying to point to the 2010 version of WPILib, where the Workbench update updated the WPILib to a newer, 2011 version. This is why the Line Follower example worked, it pointed to the correct WPILib.
If you're having to hack away at WPILib to get rid of errors, then something is going wrong. My suggestion is to delete the project you're on and start from scratch. It's a pain, but the day or so it takes to copy over the old code to the new project will save you loads of time and errors in the future. |
|
#5
|
||||
|
||||
|
Re: Wind River build environment
Thanks. It does work. Should have done this a lot earlier
Basically, I move the project directory to somewhere else. Did a "New->kernel downloadable module" and created the project. Copy only the source files back, added the WPIlib path and compiled. It worked! |
|
#6
|
||||
|
||||
|
Re: Wind River build environment
Quote:
Atta-boy! For future reference, when you have a project that just won't build, and you have another similar project that does (an unmodified example project), compare them with a directory/file compare tool. All the project files are just XML and plain text. Beyond Compare is, by far, the best tool I've found for things like that. Quote:
They're in the Workbench help facility, which nobody ever seems to look at. ;-) |
|
#7
|
||||
|
||||
|
Re: Wind River build environment
Quote:
Thank you for all your advices. |
|
#8
|
|||
|
|||
|
Re: Wind River build environment
While this is an old post, the answer is still useful. (And I had the same problem today.)
Answer: Set the build environment to PPC603gnu. All other build platforms need to be unchecked. |
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|