JCR said:
Hi,
Programing for smart phones/pda/pocket PC... can be difficult because
of the number of operating systems and the variety of devices. Is
anyone aware of a cross-operating system/cross-device environment to
write programs in C++. Open-source or not! Or maybe there is no such
thing and the solution is to set up a specific project for each target?
Unfortunately, I think you have to give up on using a cross-platform
system for mobile device development. You cannot even use standard C++
on mobile devices. The largest smart phone OS - Symbian is one of the
problems. On Symbian you cannot use exceptions at all and are required
to use two phase construction and a very problematic (and manual)
cleanup stack. You don't have any standard library. Symbian uses a
strange string descriptor model that can be tricky to handle. And
Symbian has a very odd multi-tasking model of active objects (which are
not active at all - in a preemptive sense - but rather a state machine
of co-routines). Another problem with symbian is that is "hardwired" to
a very old version of GCC (2.7 or 2.9 - don't remember) with bad
support for templates and other standard C++ 98 features. And Window
Mobile (or any of it's very similar, but different, setups of Windows
CE-based operating systems) pushes the compact Dotnet framework.
Porting C++ projects between Symbian and Windows Mobile is very
difficult (in any direction). You need to rewrite even the core parts
of most projects (or even start over). And then you may add Linux to
the mix... (which doesn't allow external C++ development at all in many
cases - only Java is supported by several vendors).
Java would seem to be the solution but it's so seriously flawed on
mobile devices that Sun is working on a completely new implementation
together with Docomo, intended to be finished in a year or so. Today,
to make a Java program work on a resonable range of multiple devices
you need something like 100 - 150 profiles (slightly different versions
of your Java program). And then you have all the limitations of the
Java MIDP framework with a very strict security policy. You cannot
store anything on the flash disk in MIDP 1.0 and only limited settings
on MIDP 2.0 - there is no way to reach the file system or even start
another Java application. Very frustrating!
To summarize: Any type of mobile device development on several
platforms is very tricky. An effort in the direction of a unified
platform is the Tao Group's Intent platform. But the drawback is a high
price (like ~$30,000 for the SDK) and no solid support for Symbian (at
least a year ago when I checked last time).
Good luck! (or maybe see it as a good opportunity for a new startup...