在 WinARM4.1x 下鏈接 BREW 對象時出現問題 (Trouble linking BREW objects under WinARM4.1x)


問題描述

在 WinARM4.1x 下鏈接 BREW 對象時出現問題 (Trouble linking BREW objects under WinARM4.1x)

I'm trying to use WinARM 4.1.1 to compile and link object files for a BREW project. I got started using this page: http://brew.wardco.com/.

First thing to note is that I have this successfully working under the GNUDE tool chain. When I switched over to WinARM, I initially got it to work till I noticed that I had ‑Lc:/gnude/arm‑elf/lib instead of ‑Lc:/WinARM/arm‑elf/lib in my linker library path. I obviously don't want to have both systems in place in my environment. Using the WinARM library path causes me to get the following linker errors:

c:/WinARM/arm‑elf/lib\libsupc++.a(eh_personality.o): In function `read_encoded_value_with_base':
c:/winarms/gcc‑4.1.1/gcc/unwind‑pe.h:259: undefined reference to `abort'
c:/WinARM/arm‑elf/lib\libsupc++.a(eh_personality.o): In function `base_of_encoded_value':
c:/winarms/gcc‑4.1.1/gcc/unwind‑pe.h:122: undefined reference to `abort'
c:/winarms/gcc‑4.1.1/gcc/unwind‑pe.h:122: undefined reference to `abort'
c:/WinARM/arm‑elf/lib\libsupc++.a(eh_personality.o): In function `size_of_encoded_value':
c:/winarms/gcc‑4.1.1/gcc/unwind‑pe.h:90: undefined reference to `abort'
c:/WinARM/arm‑elf/lib\libsupc++.a(eh_terminate.o): In function `__cxxabiv1::__terminate(void (*)())':
../../../../../gcc‑4.1.1/libstdc++‑v3/libsupc++/eh_terminate.cc:44: undefined reference to `abort'
c:/WinARM/arm‑elf/lib\libsupc++.a(eh_terminate.o):../../../../../gcc‑4.1.1/libstdc++‑v3/libsupc++/eh_terminate.cc:46: more undefined references to `abort' follow
c:/WinARM/arm‑elf/lib\libc.a(fopen.o): In function `_fopen_r':
fopen.c:(.text+0x48): undefined reference to `_open_r'
c:/WinARM/arm‑elf/lib\libc.a(freer.o): In function `_malloc_trim_r':
mallocr.c:(.text+0x48): undefined reference to `_sbrk_r'
mallocr.c:(.text+0x64): undefined reference to `_sbrk_r'
mallocr.c:(.text+0x84): undefined reference to `_sbrk_r'
c:/WinARM/arm‑elf/lib\libc.a(fseek.o): In function `_fseek_r':
fseek.c:(.text+0x158): undefined reference to `_fstat_r'
fseek.c:(.text+0x1b0): undefined reference to `_fstat_r'
c:/WinARM/arm‑elf/lib\libc.a(makebuf.o): In function `__smakebuf':
makebuf.c:(.text+0x3c): undefined reference to `_fstat_r'
makebuf.c:(.text+0x110): undefined reference to `isatty'
c:/WinARM/arm‑elf/lib\libc.a(mallocr.o): In function `_malloc_r':
mallocr.c:(.text+0x424): undefined reference to `_sbrk_r'
mallocr.c:(.text+0x4cc): undefined reference to `_sbrk_r'
c:/WinARM/arm‑elf/lib\libc.a(stdio.o): In function `__sclose':
stdio.c:(.text+0xc): undefined reference to `_close_r'
c:/WinARM/arm‑elf/lib\libc.a(stdio.o): In function `__sseek':
stdio.c:(.text+0x30): undefined reference to `_lseek_r'
c:/WinARM/arm‑elf/lib\libc.a(stdio.o): In function `__swrite':
stdio.c:(.text+0x84): undefined reference to `_lseek_r'
stdio.c:(.text+0xac): undefined reference to `_write_r'
c:/WinARM/arm‑elf/lib\libc.a(stdio.o): In function `__sread':
stdio.c:(.text+0xd0): undefined reference to `_read_r'
c:/WinARM/arm‑elf/lib\libc.a(syswrite.o): In function `write':
syswrite.c:(.text+0x24): undefined reference to `_write_r'
C:\WinARM/lib/gcc/arm‑elf/4.1.1/\libgcc.a(unwind‑sjlj.o): In function `_Unwind_RaiseException_Phase2':
../../../gcc‑4.1.1/gcc/unwind.inc:75: undefined reference to `abort'
C:\WinARM/lib/gcc/arm‑elf/4.1.1/\libgcc.a(unwind‑sjlj.o): In function `_Unwind_SjLj_Resume':
../../../gcc‑4.1.1/gcc/unwind.inc:238: undefined reference to `abort'
C:\WinARM/lib/gcc/arm‑elf/4.1.1/\libgcc.a(unwind‑sjlj.o): In function `_Unwind_SjLj_Resume_or_Rethrow':
../../../gcc‑4.1.1/gcc/unwind.inc:263: undefined reference to `abort'
NMAKE : fatal error U1077: 'C:\WinARM\bin\arm‑elf‑ld.EXE' : return code '0x1'
Stop.

I am not sure how to approach solving this; it appears that I am simply missing a path somewhere, but which path? I notice there are "c:\winarms\gcc‑4.1.1..." 'paths' listed... this not a location on my computer. Is it a library reference? 

Any insight would be appreciated.

‑‑‑‑‑

參考解法

方法 1:

Have you tried c:\WinARM\lib\gcc\arm‑elf\4.1.1 ?  Your lib path could also depend on what kind of instruction set you are using.  I use something like c:\blahblah\WinARM\lib\gcc\arm‑elf\4.1.1\thumb because I build most of my sources into the thumb instruction set.

(by Adamtlbrack)

參考文件

  1. Trouble linking BREW objects under WinARM4.1x (CC BY‑SA 3.0/4.0)

#brew-framework #arm #brewmp #linker






相關問題

嘗試在 BREW MP 上開發應用程序 (Trying to develop an App on BREW MP)

有沒有辦法在 BREW 3.0 平台上使用 Lua? (Is there a way to use Lua on BREW 3.0 platform?)

為多個移動設備構建單一應用程序 (Single application build for multiple mobile devices)

在 BREW 中安排應用程序 (Schedule app in BREW)

BREW:跟踪 BPOINT 錯誤消息的方法 (BREW: Methods to trace BPOINT error messages)

如何在 Brew 上檢測手機品牌和型號信息? (How to detect phone handset brand and model info on Brew?)

在 Brew MP 手機上激活虛擬鍵盤? (Activate virtual keyboard on Brew MP phone?)

為什麼在 HTC Smart 上無法檢測手機品牌和型號? (Why does not detecting phone make and model work on HTC Smart?)

檢測/指紋手機品牌和型號的替代方法? (Alternative way to detect/fingerprint phone make and model?)

在 WinARM4.1x 下鏈接 BREW 對象時出現問題 (Trouble linking BREW objects under WinARM4.1x)

禁用被視為錯誤的警告(cc1.exe) (Disable warnings being treated as errors(cc1.exe))







留言討論