
Hi, I've just started on a project which is Windows CE based, using Microsoft Embedded Visual C++ V3 and V4, and I'm having trouble using boost. There are several #defines in the code that cover Windows CE (e.g. BOOST_NO_ANSI_APIS), so somebody must be using boost successfully. So, my first question is: what compiler(s) are people using for Windows CE? Secondly, though these compilers are pretty similar to MSVC6 in terms of direct C++ language support, they are further hampered by the lack of exceptions and RTTI for the Windows CE targets needed for my project, and by the lack of a decent Standard Library. I've managed to overcome the latter by using STLPort 5.1, but much of boost is still not usable due to the lack of exceptions and RTTI --- I can't even use simple stuff like lexical_cast! Am I the only one in this boat, or has anyone got any recommendations? Anthony -- Anthony Williams Just Software Solutions Ltd - http://www.justsoftwaresolutions.co.uk Registered in England, Company Number 5478976. Registered Office: 15 Carrallack Mews, St Just, Cornwall, TR19 7UL

Anthony Williams wrote:
Hi,
I've just started on a project which is Windows CE based, using Microsoft Embedded Visual C++ V3 and V4, and I'm having trouble using boost. There are several #defines in the code that cover Windows CE (e.g. BOOST_NO_ANSI_APIS), so somebody must be using boost successfully.
I've used but only some of Boost libraries like smart pointers, any, and other small stuff, with eVC++ 4.0 and Visual C++ 8.0
So, my first question is: what compiler(s) are people using for Windows CE?
I used to use eVC++ 3.0 for ~1 year, next I was glad to move to eVC++ 4.0. Finally, I'm extremely happy and my psyche is healthier after I moved to Visual C++ 8.0 :-) Certainly, selection of toolset depends on a) target platform and b) budget becasue Visual C++ 8.0 is not free. Here you can find a nice matrix presenting what Windows CE-based systems are supported by what tools: http://blogs.msdn.com/windowsmobile/archive/2005/06/02/424382.aspx Generally, if you are able to drop eVC++ line, do it as fast as you can.
Secondly, though these compilers are pretty similar to MSVC6 in terms of direct C++ language support,
eVC++ 3.0 and 4.0 are just Visual C++ 6.0, so these are considered as the same compiler in terms of C++ support - *weak support*
they are further hampered by the lack of exceptions and RTTI for the Windows CE targets needed for my project, and by the lack of a decent Standard Library.
You can install RTTI patch for Windows CE 4.x platform: http://support.microsoft.com/default.aspx?scid=kb;%5BLN%5D;830482
I've managed to overcome the latter by using STLPort 5.1, but much of boost is still not usable due to the lack of exceptions and RTTI --- I can't even use simple stuff like lexical_cast! Am I the only one in this boat, or has anyone got any recommendations?
Try the patch above and check if it helps. Cheers -- Mateusz Loskot http://mateusz.loskot.net

Mateusz Loskot <mateusz@loskot.net> writes:
Anthony Williams wrote:
So, my first question is: what compiler(s) are people using for Windows CE?
I used to use eVC++ 3.0 for ~1 year, next I was glad to move to eVC++ 4.0. Finally, I'm extremely happy and my psyche is healthier after I moved to Visual C++ 8.0 :-)
Thanks for the info.
Certainly, selection of toolset depends on a) target platform and b) budget becasue Visual C++ 8.0 is not free.
Yes. Unfortunately, one of the target platforms is running Windows CE 3.0, with a non-standard SDK and therefore needs eVC++ 3.0
Here you can find a nice matrix presenting what Windows CE-based systems are supported by what tools:
http://blogs.msdn.com/windowsmobile/archive/2005/06/02/424382.aspx
Thanks.
Secondly, though these compilers are pretty similar to MSVC6 in terms of direct C++ language support,
eVC++ 3.0 and 4.0 are just Visual C++ 6.0, so these are considered as the same compiler in terms of C++ support - *weak support*
Yup.
they are further hampered by the lack of exceptions and RTTI for the Windows CE targets needed for my project, and by the lack of a decent Standard Library.
You can install RTTI patch for Windows CE 4.x platform:
http://support.microsoft.com/default.aspx?scid=kb;%5BLN%5D;830482
I've managed to overcome the latter by using STLPort 5.1, but much of boost is still not usable due to the lack of exceptions and RTTI --- I can't even use simple stuff like lexical_cast! Am I the only one in this boat, or has anyone got any recommendations?
Try the patch above and check if it helps.
The patch is for Windows CE 4.x, and one of my targets is running CE 3.0, so thanks, but it's not any use to me. Anthony -- Anthony Williams Just Software Solutions Ltd - http://www.justsoftwaresolutions.co.uk Registered in England, Company Number 5478976. Registered Office: 15 Carrallack Mews, St Just, Cornwall, TR19 7UL

Anthony Williams wrote:
Mateusz Loskot <mateusz@loskot.net> writes:
Certainly, selection of toolset depends on a) target platform and b) budget becasue Visual C++ 8.0 is not free.
Yes. Unfortunately, one of the target platforms is running Windows CE 3.0, with a non-standard SDK and therefore needs eVC++ 3.0
I see. Unfortunately, I can't give you any better solution. There is also Intel C/C++ compiler, with 30 days trial available, so you may try it to see if provides better support for C++. I tried Intel C/C++ with eVC++ 4.0. It can be attached to the eVC++ IDE. Cheers -- Mateusz Loskot http://mateusz.loskot.net

Anthony Williams wrote:
Mateusz Loskot <mateusz@loskot.net> writes:
You can install RTTI patch for Windows CE 4.x platform:
http://support.microsoft.com/default.aspx?scid=kb;%5BLN%5D;830482
The patch is for Windows CE 4.x, and one of my targets is running CE 3.0, so thanks, but it's not any use to me.
Why would you need to patch an OS to support RTTI? This is pretty weird. Did you look whether you could simply use GCC ?

Mathias Gaunard <mathias.gaunard@etu.u-bordeaux1.fr> writes:
Anthony Williams wrote:
Mateusz Loskot <mateusz@loskot.net> writes:
You can install RTTI patch for Windows CE 4.x platform:
http://support.microsoft.com/default.aspx?scid=kb;%5BLN%5D;830482
The patch is for Windows CE 4.x, and one of my targets is running CE 3.0, so thanks, but it's not any use to me.
Why would you need to patch an OS to support RTTI? This is pretty weird.
It's not a patch for the OS, but a patch for the compiler's runtime support libraries for that OS.
Did you look whether you could simply use GCC ?
I didn't, because my client requires me to use the Microsoft compiler. Anthony -- Anthony Williams Just Software Solutions Ltd - http://www.justsoftwaresolutions.co.uk Registered in England, Company Number 5478976. Registered Office: 15 Carrallack Mews, St Just, Cornwall, TR19 7UL

Anthony Williams wrote:
Mathias Gaunard <mathias.gaunard@etu.u-bordeaux1.fr> writes:
Anthony Williams wrote:
Mateusz Loskot <mateusz@loskot.net> writes:
You can install RTTI patch for Windows CE 4.x platform:
http://support.microsoft.com/default.aspx?scid=kb;%5BLN%5D;830482
The patch is for Windows CE 4.x, and one of my targets is running CE 3.0, so thanks, but it's not any use to me. Why would you need to patch an OS to support RTTI? This is pretty weird.
It's not a patch for the OS, but a patch for the compiler's runtime support libraries for that OS.
That's right. Cheers -- Mateusz Loskot http://mateusz.loskot.net

Mathias Gaunard wrote:
Anthony Williams wrote:
Mateusz Loskot <mateusz@loskot.net> writes:
You can install RTTI patch for Windows CE 4.x platform:
http://support.microsoft.com/default.aspx?scid=kb;%5BLN%5D;830482
The patch is for Windows CE 4.x, and one of my targets is running CE 3.0, so thanks, but it's not any use to me.
Why would you need to patch an OS to support RTTI? This is pretty weird.
I'm not a member of Windows CE dev team, so I can't answer this question.
Did you look whether you could simply use GCC ?
Shortly, yes you can and the GCC tools chain is ported. IMHO, longer answer is that usability of these tools is limited, ie. you don't have access to remote debugging on a device, many of libraries are not supported like ATL which makes impossible to use WTL - two crucial libraries for me. Cheers -- Mateusz Loskot http://mateusz.loskot.net

Mateusz Loskot wrote:
Anthony Williams wrote:
Hi,
I've just started on a project which is Windows CE based, using Microsoft Embedded Visual C++ V3 and V4, and I'm having trouble using boost. There are several #defines in the code that cover Windows CE (e.g. BOOST_NO_ANSI_APIS), so somebody must be using boost successfully.
I've used but only some of Boost libraries like smart pointers, any, and other small stuff, with eVC++ 4.0 and Visual C++ 8.0
So, my first question is: what compiler(s) are people using for Windows CE?
I used to use eVC++ 3.0 for ~1 year, next I was glad to move to eVC++ 4.0. Finally, I'm extremely happy and my psyche is healthier after I moved to Visual C++ 8.0 :-)
Certainly, selection of toolset depends on a) target platform and b) budget becasue Visual C++ 8.0 is not free.
Here you can find a nice matrix presenting what Windows CE-based systems are supported by what tools:
http://blogs.msdn.com/windowsmobile/archive/2005/06/02/424382.aspx
Generally, if you are able to drop eVC++ line, do it as fast as you can.
Secondly, though these compilers are pretty similar to MSVC6 in terms of direct C++ language support,
eVC++ 3.0 and 4.0 are just Visual C++ 6.0, so these are considered as the same compiler in terms of C++ support - *weak support*
they are further hampered by the lack of exceptions and RTTI for the Windows CE targets needed for my project, and by the lack of a decent Standard Library.
You can install RTTI patch for Windows CE 4.x platform:
http://support.microsoft.com/default.aspx?scid=kb;%5BLN%5D;830482
I've managed to overcome the latter by using STLPort 5.1, but much of boost is still not usable due to the lack of exceptions and RTTI --- I can't even use simple stuff like lexical_cast! Am I the only one in this boat, or has anyone got any recommendations?
Try the patch above and check if it helps.
That's quite useful to know. Thanks, Michael Marcin

On Wednesday 24 January 2007 16:30, Anthony Williams wrote:
I've just started on a project which is Windows CE based, using Microsoft Embedded Visual C++ V3 and V4, and I'm having trouble using boost. There are several #defines in the code that cover Windows CE (e.g. BOOST_NO_ANSI_APIS), so somebody must be using boost successfully.
So, my first question is: what compiler(s) are people using for Windows CE?
I'm using those that come with eVC4 and VC8 (VS2005). eVC4 comes with versions 12.00 to 12.02. Note: version 12.00 is bug-to-bug compatible with the one from VC6, the other two don't differ much either. All of them are cross-compilers (except the one for the emulator) so some additional backend-problems apply with ARM and MIPS (see e.g. STLport's documentation, which has official CE support). VC8 comes with compilers versions 14.x, which are already pretty good and should be able compile all of Boost (though not necessarily do so due to platform and library restrictions).
Secondly, though these compilers are pretty similar to MSVC6 in terms of direct C++ language support, they are further hampered by the lack of exceptions and RTTI for the Windows CE targets needed for my project, and by the lack of a decent Standard Library.
Okay, the stdlib can be overcome with STLport5, as you have noticed yourself. Now, concerning RTTI (which again is a requirement for exceptions), you should be able to use it. Some platforms don't include support for it (see again the STLport docs) but it can be retrofitted using patches from MS. For other platforms, you will need access to "Platform Builder", which is basically a tool to assemble a CE platform from the various modules. If you have to use an existing platform, you might be able to persuade the supplier to add RTTI support to it, otherwise I'm afraid you're out of luck - at least I wouldn't be aware of a way to simply retrofit it to an existing platform. Concerning the question which libs we use, there are - smart pointers - optional - threads - regex - function - bind - lexical_cast I know that lexical_cast has problems with std::wstring under VC6 and eVC4 though, so that one is restricted. Also, we are using a patched 1.33.1 version, and I'm not sure which patches have been accepted yet. The major breakage (#if _MSC_VER==1200, which fails for 1201 and 1202) seems to have been fixed already, for all others I'd be willing to help out, too, if the patches got lost. cheers Uli

Ulrich Eckhardt wrote:
On Wednesday 24 January 2007 16:30, Anthony Williams wrote:
I've just started on a project which is Windows CE based, using Microsoft Embedded Visual C++ V3 and V4, and I'm having trouble using boost. There are several #defines in the code that cover Windows CE (e.g. BOOST_NO_ANSI_APIS), so somebody must be using boost successfully.
So, my first question is: what compiler(s) are people using for Windows CE?
I'm using those that come with eVC4 and VC8 (VS2005). eVC4 comes with versions 12.00 to 12.02. Note: version 12.00 is bug-to-bug compatible with the one from VC6, the other two don't differ much either. All of them are cross-compilers (except the one for the emulator) so some additional backend-problems apply with ARM and MIPS (see e.g. STLport's documentation, which has official CE support). VC8 comes with compilers versions 14.x, which are already pretty good and should be able compile all of Boost (though not necessarily do so due to platform and library restrictions). [...]
Ulrich, Thank you very much for this detailed explanation! It's very informative. Cheers -- Mateusz Loskot http://mateusz.loskot.net
participants (5)
-
Anthony Williams
-
Mateusz Loskot
-
Mathias Gaunard
-
Michael Marcin
-
Ulrich Eckhardt