discostuboogaloo / optiboot

Automatically exported from code.google.com/p/optiboot
0 stars 0 forks source link

Arduino included ld crashes trying to link optiboot. #18

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
ld crashes when trying to compile optiboot using the C compiler distributed 
with Arduino-0021 (gcc 4.3.2, binutils 2.19)  It works fine with a separate 
install of of 4.5.1/2.20

Any ideas?

Process:         ld [2769]
Path:            
/Applications/arduino/arduino-0021/Arduino-0021.app/Contents/Resources/Java/hard
ware/tools/avr/bin/../lib/gcc/avr/4.3.2/../../../../avr/bin/ld
Identifier:      ld
Version:         ??? (???)
Code Type:       X86 (Native)
Parent Process:  gcc [2764]

Date/Time:       2010-10-04 22:49:24.416 -0700
OS Version:      Mac OS X 10.5.8 (9L31a)
Report Version:  6
Anonymous UUID:  F6E49CD9-22B3-40F2-B60E-E817863A4B4D

Exception Type:  EXC_BAD_ACCESS (SIGBUS)
Exception Codes: KERN_PROTECTION_FAILURE at 0x0000000000000010
Crashed Thread:  0

Thread 0 Crashed:
0   ld                              0x00066c03 0x1000 + 416771
1   ld                              0x000685c9 0x1000 + 423369
2   ld                              0x0000f7b0 0x1000 + 59312
3   ld                              0x0000f75f 0x1000 + 59231
4   ld                              0x0000fb40 0x1000 + 60224
5   ld                              0x00010379 0x1000 + 62329
6   ld                              0x000105dc 0x1000 + 62940
7   ld                              0x00013d5c 0x1000 + 77148
8   ld                              0x00016086 0x1000 + 86150
9   ld                              0x00001922 0x1000 + 2338
10  ld                              0x00001849 0x1000 + 2121

Thread 0 crashed with X86 Thread State (32-bit):
  eax: 0x00000001  ebx: 0x0006696b  ecx: 0x00000016  edx: 0x00000000
  edi: 0x00000000  esi: 0x000001b8  ebp: 0xbfffd5f8  esp: 0xbfffd590
   ss: 0x0000001f  efl: 0x00010297  eip: 0x00066c03   cs: 0x00000017
   ds: 0x0000001f   es: 0x0000001f   fs: 0x00000000   gs: 0x00000037
  cr2: 0x00000010

Binary Images:
    0x1000 -    0xd5fe7 +ld ??? (???) <834f53ee5bd64a4f9d5007021a3b80ed> /Applications/arduino/arduino-0021/Arduino-0021.app/Contents/Resources/Java/hardware/tools/avr/avr/bin/ld
0x8fe00000 - 0x8fe2db43  dyld 97.1 (???) <458eed38a009e5658a79579e7bc26603> 
/usr/lib/dyld
0x91465000 - 0x9146cfe9  libgcc_s.1.dylib ??? (???) 
<28a7cbc3a5ca2982d124668306f422d9> /usr/lib/libgcc_s.1.dylib
0x91b04000 - 0x91c6bff3  libSystem.B.dylib ??? (???) 
<c8f52e158bf540cc000146ca8a705958> /usr/lib/libSystem.B.dylib
0x933e1000 - 0x933efffd  libz.1.dylib ??? (???) 
<545ca09467025f77131cfac09d8b9375> /usr/lib/libz.1.dylib
0x96cc1000 - 0x96cc5fff  libmathCommon.A.dylib ??? (???) 
/usr/lib/system/libmathCommon.A.dylib
0xffff0000 - 0xffff1780  libSystem.B.dylib ??? (???) /usr/lib/libSystem.B.dylib

Original issue reported on code.google.com by wes...@gmail.com on 5 Oct 2010 at 6:03

GoogleCodeExporter commented 8 years ago
This is apparently http://sourceware.org/bugzilla/show_bug.cgi?id=6019
Consider adding "-Wl,--gc-sections" to LDFLAGS, which will fix the problem...

Original comment by wes...@gmail.com on 5 Oct 2010 at 6:12

GoogleCodeExporter commented 8 years ago
[deleted comment]
GoogleCodeExporter commented 8 years ago
--gc-sections added to version in source repo.

Original comment by cathed...@gmail.com on 12 Oct 2010 at 8:21