Hi All, (Using mingw32ce toolchain, revision 1049 I believe.)
Can someone help explain to me the mechanisms behind how the 'dummy WinMain' function (in winmain_ce.c) is conditionally linked into the output binary if the developer doesn't provide his own WinMain() function? My problem is that I *am* providing my own WinMain() function but it is tucked away inside a static link library rather than in the source files I am compiling. When building, the linker says that there is a multiple definition of WinMain. See error below: $ arm-wince-mingw32ce-gcc -o output.exe main.c -lmylib [...]/arm-wince-mingw32ce/lib/libmingw32.a(winmain_ce.o): In function `WinMain': [...]/cegcc/src/mingw/winmain_ce.c:143: multiple definition of `WinMain' [...]/libmylib.a(main.o):main.c:(.text+0x0): first defined here [...]/arm-wince-mingw32ce/lib/libmingw32.a(winmain_ce.o):winmain_ce.c:(.text+0x1e0): undefined reference to `main' collect2: ld returned 1 exit status I'll be grateful for any guidance and ideas on how to solve this. Thanks. -- Matt. ------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2005. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ _______________________________________________ Cegcc-devel mailing list Cegcc-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/cegcc-devel