CeGCC cross compiler for PocketPC

Choosing in which environment to develop

Remember that arm-wince-cegcc implements a unix-like layer on top of Windows CE, and that arm-wince-mingw32ce implements the native CE API.

Our recommendation is to use the arm-wince-mingw32ce toolset whenever possible because the newlib-based unix-like layer that arm-wince-cegcc implements is incomplete (it's newlib, not glibc) and sometimes confusing and incompatible with coredll.

On the other hand, arm-wince-mingw32ce offers more complete C++ DLL support. We will probably implement a C++ DLL for the arm-wince-mingw32ce environment shortly. Until we do so, you can easily build it for yourself by using the src/build-mingw32ce-dlls.sh script.

1. Porting a Unix-like application

Arm-wince-cegcc is a great tool to start porting your application to WinCE, as it offers a unix-like layer on top of the Windows CE API.

This doesn't come without risks though (it is very easy to mix up stdio API's from coredll and newlib, and they're incompatible). Also be aware that Windows CE has many Unicode based system calls, you'll have to make sure your application can deal with that.

2. Porting an application that uses only the Windows CE API

It should be abundantly clear that the right tool for this job is the arm-wince-mingw32ce toolset.

3. Recompiling a CE application that was built with Embedded Visual C++

If you want to build an existing Windows CE application that already builds with eVC, then you probably think you're not porting an application.

The right tool to use is arm-wince-mingw32ce, but you need to be aware that some of the C or C++ extensions supported by eVC aren't available in our toolset.

4. Porting an application that was built with MicroSoft Visual C++

An application that is built not with eVC but MSVC (MicroSoft Visual C++) is not typically a Windows CE but a Windows application. This may be an issue because Windows CE supports only a limited subset of the Windows API.

Once more, the right tool to use is arm-wince-mingw32ce.

5. Microsoft environment equivalents

The /ENTRY option to the Microsoft compiler is equivalent to ld's -e option.

6. Console Applications

In the NT/9x target versions of Microsoft's tools, there is have some default behaviour, such as if main is defined then CONSOLE subsytem is the default.

Windows CE applications don't have that functionality, as they must always specify the Windows CE subsystem: http://msdn2.microsoft.com/en-us/library/fcc1zstk.aspx

If you want to develop a console based application, take a look at Pocket Console: http://www.symbolictools.de/public/pocketconsole/

The default user entry point in mingw32ce is WinMain, but if you don't provide one, a default one will be linked in that will call the standard int main (int argc, char** argv) with argc and argv properly filled.

Information

Support

Powered by Sourceforge.net