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

Developer

Forums

Hi
I need help. I am new to BREW and come from j2me world. I have c/c++ development exp many years ago. I am finding some simple and stupid erros when compiling sample helloworld app with gcc to create dll. I would really, really appreciate if you can help me out.

I do
$gcc -c -Ic:/brewsdk_v2.0.1/inc helloworld.c

it creates object file. but next step
$gcc -shared -o helloworld.dll helloworld.o

gives me this error
helloworld.o(.text+0x43):helloworld.c: undefined reference to `_AEEApplet_New'
collect2: ld returned 1 exit status

thanks in advance

Any BREW application requires you to compile AEEAppGen.c and AEEModGen.c located in SDK\src folder. Refer makefile comes with SDK examples for further info.
ruben

Any BREW application requires you to compile AEEAppGen.c and AEEModGen.c located in SDK\src folder. Refer makefile comes with SDK examples for further info.
ruben

it worked. THanks a Lot for your help. I would like to use makefile to do these compilations on gcc. All the sample makefiles descibe making .mod files for device with arm-gcc. Can you post a sample makefile/code snippet for compiling dlls. As I said I am not a make expert and I would really appreciate your help.
thanks in advance

it worked. THanks a Lot for your help. I would like to use makefile to do these compilations on gcc. All the sample makefiles descibe making .mod files for device with arm-gcc. Can you post a sample makefile/code snippet for compiling dlls. As I said I am not a make expert and I would really appreciate your help.
thanks in advance

I guess you are trying to compile your code for ARM using GCC compiler.
Unfortunately, I use ARM RealView compiler (RVCT). All the sample programs makefile is for RVCT. I am not very sure about the differences between GCC ARM compiler makefile and that of RVCT.
ruben

I guess you are trying to compile your code for ARM using GCC compiler.
Unfortunately, I use ARM RealView compiler (RVCT). All the sample programs makefile is for RVCT. I am not very sure about the differences between GCC ARM compiler makefile and that of RVCT.
ruben

I am just starting BREW, so compiling only for emulator. I will do the devices .mod files later after learning more. I just wanted a sample makefile for compiling a dll using gcc, for emulator. I am using gcc version 3.3 that comes with cygwin.
thanks in advance

I am just starting BREW, so compiling only for emulator. I will do the devices .mod files later after learning more. I just wanted a sample makefile for compiling a dll using gcc, for emulator. I am using gcc version 3.3 that comes with cygwin.
thanks in advance

For windows version of emulator you need Microsoft visual C++ 6.0 or above.
As far I know you may not be able to compile for windows emulator using GCC, at least I am not aware of anyone doing that.
ruben

For windows version of emulator you need Microsoft visual C++ 6.0 or above.
As far I know you may not be able to compile for windows emulator using GCC, at least I am not aware of anyone doing that.
ruben

I have ordered msvs .net. I guess till then gcc will do, I have seen one post about using gcc for compiling dlls. I will do some more research, and refresh my make skills.

I have ordered msvs .net. I guess till then gcc will do, I have seen one post about using gcc for compiling dlls. I will do some more research, and refresh my make skills.

Quote:Originally posted by ruben
For windows version of emulator you need Microsoft visual C++ 6.0 or above.
As far I know you may not be able to compile for windows emulator using GCC, at least I am not aware of anyone doing that.
ruben
GCC should work fine in theory, though I've never attempted to use it for this purpose. Any compiler that can build a Windows DLL should do the trick.

Quote:Originally posted by ruben
For windows version of emulator you need Microsoft visual C++ 6.0 or above.
As far I know you may not be able to compile for windows emulator using GCC, at least I am not aware of anyone doing that.
ruben
GCC should work fine in theory, though I've never attempted to use it for this purpose. Any compiler that can build a Windows DLL should do the trick.

Thanks for the info. I haven't done it yet :(
ruben

Thanks for the info. I haven't done it yet :(
ruben

I make all DLLs with gcc, and have passed TrueBREW with a gcc DLL included in the submission. My process is entirely MSVS free: you can use gdb on the DLLs (by calling gdb on the emulator executable).
See http://brewforums.qualcomm.com/showthread.php?s=&threadid=1793
-Jesse

I make all DLLs with gcc, and have passed TrueBREW with a gcc DLL included in the submission. My process is entirely MSVS free: you can use gdb on the DLLs (by calling gdb on the emulator executable).
See http://brewforums.qualcomm.com/showthread.php?s=&threadid=1793
-Jesse

Can you post a sample make file that I modify and use to compile my DLLs? I would really appreciate if you help me here.
TIA

Can you post a sample make file that I modify and use to compile my DLLs? I would really appreciate if you help me here.
TIA

Well, there's 90% of a GnuMake Makefile that does just that at the above link.

Well, there's 90% of a GnuMake Makefile that does just that at the above link.