Forums | developer.brewmp.com Forums | developer.brewmp.com

Developer

Forums

Forums:

Hi,

I have just started working on getting my app to build using Winarm.

I am getting an odd compiler error from AEESource.h

C:\PROGRA~1\BREWSD~1.3\inc/AEEWebOpts.h:419:27: warning: no newline at end of file
C:\PROGRA~1\BREWSD~1.3\inc/AEESource.h:190: error: declaration of 'int32 (* IGetLineVtbl::GetLine)(IGetLine*, GetLine*, int32)'
C:\PROGRA~1\BREWSD~1.3\inc/AEESource.h:176: error: changes meaning of 'GetLine' from 'typedef struct GetLine GetLine'
NMAKE : fatal error U1077: 'C:\WinArm\bin\arm-elf-g++.EXE' : return code '0x1'
Stop.

Does anyone know what this means? - I am really new to command line compiling.

My path info is as follows.

Source Path = C:\Program Files\BREW SDK v2.1.3\src
Include Path = C:\Program Files\BREW SDK v2.1.3\inc
Arm Bin Path = C:\WinArm\bin
Arm inc path = C:\WinArm\include
Arm lib path = C:\WinArm\lib
Arm C compiler path = C:\WinArm\bin\arm-elf-gcc
Arm c++ compiler path = C:\WinArm\bin\arm-elf-g++
ARM ADS linker = C:\WinArm\bin\arm-elf-ld

Compiler options:

C:\WinArm\bin\arm-elf-g++ -c -DDYNAMIC_APP -mcpu=arm7tdmi -mlittle-endian -mapcs-frame -fno-builtin -ffunction-sections -fno-exceptions -I. -IC:\Program Files\BREW SDK v2.1.3\inc -I C:\PROGRA~1\BREWSD~1.3\inc -o ApplicationFile.o ApplicationFile.cpp

Any help would be greatly appreciated, I am completely stuck.

Thanks

Adrian

Search the forums. You have to edit the header file in the SDK.

Search the forums. You have to edit the header file in the SDK.

Hi,
Thanks for your reply.
Do you know id WinArm Supports Uint64?
Or if not is it possible to let it by some tricks?
My app needs dates and times
Thanks
Adrian

Hi,
Thanks for your reply.
Do you know id WinArm Supports Uint64?
Or if not is it possible to let it by some tricks?
My app needs dates and times
Thanks
Adrian

Hi rabidcow :o
Thanks for your reply.
I got my code compiling now :o (yipee!) thanks to everyone on the forum!
I have now run into some linker errors though?
has anyone come across these before and know how to get around them, or even know what I am doing wrong?
undefined reference to `abort'
undefined reference to `_sbrk_r'
undefined reference to `_write_r'
undefined reference to `_fstat_r'
undefined reference to `isatty'
undefined reference to `_close_r'
undefined reference to `_lseek_r'
undefined reference to `_read_r'
Thanks for your continued patience.
I am compiling with WINARM 4.1.1
Adrian

Hi rabidcow :o
Thanks for your reply.
I got my code compiling now :o (yipee!) thanks to everyone on the forum!
I have now run into some linker errors though?
has anyone come across these before and know how to get around them, or even know what I am doing wrong?
undefined reference to `abort'
undefined reference to `_sbrk_r'
undefined reference to `_write_r'
undefined reference to `_fstat_r'
undefined reference to `isatty'
undefined reference to `_close_r'
undefined reference to `_lseek_r'
undefined reference to `_read_r'
Thanks for your continued patience.
I am compiling with WINARM 4.1.1
Adrian

You have a bit of pain ahead of you... You're apparently including . Instead of things like fstat, which don't exist on the BREW platform (unless you implement them yourself, a possible solution), you should be using the IFILE interface.
You should not be including any standard libraries that you have not implemented yourself. So that means stdio, stdlib, ctypes, are all out. stdargs is okay.
The easiest way to find out exactly what you are including is to move everything in /inc into /noinc (or whatever the include dir is called on winarm, can't remember off-hand, and typing on a machine without it installed).
Ben

You have a bit of pain ahead of you... You're apparently including . Instead of things like fstat, which don't exist on the BREW platform (unless you implement them yourself, a possible solution), you should be using the IFILE interface.
You should not be including any standard libraries that you have not implemented yourself. So that means stdio, stdlib, ctypes, are all out. stdargs is okay.
The easiest way to find out exactly what you are including is to move everything in /inc into /noinc (or whatever the include dir is called on winarm, can't remember off-hand, and typing on a machine without it installed).
Ben

Hi Ben,
Thanks for your reply.
My app doesnt use any file operations, and I have taken great care to use the BREW stdLib functions in my code.
I am linking however to -lsupc++, -lc, -lm, -lgcc
could the problem lie here?
Thanks
Adrian

Hi Ben,
Thanks for your reply.
My app doesnt use any file operations, and I have taken great care to use the BREW stdLib functions in my code.
I am linking however to -lsupc++, -lc, -lm, -lgcc
could the problem lie here?
Thanks
Adrian

I have another question too,
Do I need the support files for the GNU Compiler to build with winARM?
Thanks
Adrian

I have another question too,
Do I need the support files for the GNU Compiler to build with winARM?
Thanks
Adrian

Hi every one,
Does anyone have any ideas about this.
I have reduced the Linker errors to:
c:\winarm\bin\../arm-elf/lib\libstdc++.a(vterminate.o): In function `__gnu_cxx::__verbose_terminate_handler()':
../../../../../gcc-4.1.1/libstdc++-v3/libsupc++/vterminate.cc:89: undefined reference to `_impure_ptr'
c:\winarm\bin\../arm-elf/lib\libstdc++.a(cp-demangle.o): In function `d_expression':
c:\winarms\arm-elf\gcc\arm-elf\libstdc++-v3\libsupc++/cp-demangle.c:2233: undefined reference to `strcmp'
c:\winarm\bin\../arm-elf/lib\libstdc++.a(cp-demangle.o): In function `d_print_resize':
c:\winarms\arm-elf\gcc\arm-elf\libstdc++-v3\libsupc++/cp-demangle.c:2567: undefined reference to `realloc'
c:\winarm\bin\../arm-elf/lib\libstdc++.a(cp-demangle.o): In function `d_demangle':
c:\winarms\arm-elf\gcc\arm-elf\libstdc++-v3\libsupc++/cp-demangle.c:3774: undefined reference to `strlen'
c:\winarms\arm-elf\gcc\arm-elf\libstdc++-v3\libsupc++/cp-demangle.c:3778: undefined reference to `strncmp'
c:\winarms\arm-elf\gcc\arm-elf\libstdc++-v3\libsupc++/cp-demangle.c:3794: undefined reference to `strcat'
c:\winarm\bin\../arm-elf/lib\libstdc++.a(cp-demangle.o): In function `__cxa_demangle':
c:\winarms\arm-elf\gcc\arm-elf\libstdc++-v3\libsupc++/cp-demangle.c:3957: undefined reference to `strlen'
c:\winarms\arm-elf\gcc\arm-elf\libstdc++-v3\libsupc++/cp-demangle.c:3959: undefined reference to `strcpy'
NMAKE : fatal error U1077: 'C:\WinArm\bin\arm-elf-ld.exe' : return code '0x1'
Stop.
By supplying these methods in GCCResolver.c
void free(void *p) {
FREE(p);

void abort() {

void fwrite()
{

void fputs()
{
}
void fputc()
{

Be fore I go on and implement strcmp, and realloc, etc, Is my approach a safe one? - empty implementations seem a bit wrong to me.
My app does not use File Access any way.
Does anyone know what _impure_ptr() is/does?
Thanks for your pateince and help.
Adrian

Hi every one,
Does anyone have any ideas about this.
I have reduced the Linker errors to:
c:\winarm\bin\../arm-elf/lib\libstdc++.a(vterminate.o): In function `__gnu_cxx::__verbose_terminate_handler()':
../../../../../gcc-4.1.1/libstdc++-v3/libsupc++/vterminate.cc:89: undefined reference to `_impure_ptr'
c:\winarm\bin\../arm-elf/lib\libstdc++.a(cp-demangle.o): In function `d_expression':
c:\winarms\arm-elf\gcc\arm-elf\libstdc++-v3\libsupc++/cp-demangle.c:2233: undefined reference to `strcmp'
c:\winarm\bin\../arm-elf/lib\libstdc++.a(cp-demangle.o): In function `d_print_resize':
c:\winarms\arm-elf\gcc\arm-elf\libstdc++-v3\libsupc++/cp-demangle.c:2567: undefined reference to `realloc'
c:\winarm\bin\../arm-elf/lib\libstdc++.a(cp-demangle.o): In function `d_demangle':
c:\winarms\arm-elf\gcc\arm-elf\libstdc++-v3\libsupc++/cp-demangle.c:3774: undefined reference to `strlen'
c:\winarms\arm-elf\gcc\arm-elf\libstdc++-v3\libsupc++/cp-demangle.c:3778: undefined reference to `strncmp'
c:\winarms\arm-elf\gcc\arm-elf\libstdc++-v3\libsupc++/cp-demangle.c:3794: undefined reference to `strcat'
c:\winarm\bin\../arm-elf/lib\libstdc++.a(cp-demangle.o): In function `__cxa_demangle':
c:\winarms\arm-elf\gcc\arm-elf\libstdc++-v3\libsupc++/cp-demangle.c:3957: undefined reference to `strlen'
c:\winarms\arm-elf\gcc\arm-elf\libstdc++-v3\libsupc++/cp-demangle.c:3959: undefined reference to `strcpy'
NMAKE : fatal error U1077: 'C:\WinArm\bin\arm-elf-ld.exe' : return code '0x1'
Stop.
By supplying these methods in GCCResolver.c
void free(void *p) {
FREE(p);

void abort() {

void fwrite()
{

void fputs()
{
}
void fputc()
{

Be fore I go on and implement strcmp, and realloc, etc, Is my approach a safe one? - empty implementations seem a bit wrong to me.
My app does not use File Access any way.
Does anyone know what _impure_ptr() is/does?
Thanks for your pateince and help.
Adrian

I am getting these linker errors as well, but also not using the standard library:
Quote:
undefined reference to `abort'
undefined reference to `_sbrk_r'
undefined reference to `_write_r'
undefined reference to `_fstat_r'
undefined reference to `isatty'
undefined reference to `_close_r'
undefined reference to `_lseek_r'
undefined reference to `_read_r'
adrian_roney, are you still around here? How did you end up fixing these?
-Thanks

I am getting these linker errors as well, but also not using the standard library:
Quote:
undefined reference to `abort'
undefined reference to `_sbrk_r'
undefined reference to `_write_r'
undefined reference to `_fstat_r'
undefined reference to `isatty'
undefined reference to `_close_r'
undefined reference to `_lseek_r'
undefined reference to `_read_r'
adrian_roney, are you still around here? How did you end up fixing these?
-Thanks

Nevermind, I worked my errors out. I was using new and delete operators, and had globally defined them to use MALLOC and FREE instead, but forgot to put that dependency in my makefile.

Nevermind, I worked my errors out. I was using new and delete operators, and had globally defined them to use MALLOC and FREE instead, but forgot to put that dependency in my makefile.