|
|
|
The conventional way of defining the entry point for a Symbian OS
executable is by including "E32Main" in the application source.
Since Symbian OS v9.3, you can define the entry point for an executable by
including "main" instead of "E32Main". With this
approach, developers may easily port their C/C++ code to Symbian OS platforms
with less changes to the original source.
Symbian OS v9.3 and later releases provide an Open Environment (OE) to
develop EXEs with the "main" entry point. The OE executables and
libraries are identified by their targettype, which can either be
STDEXE, STDDLL or STDLIB. An OE EXE may
choose to have a wide character entry point using the MMP keyword,
wcharentrypoint.
Here is a list of important differences between native Symbian OS executables and OE executables:
Native Symbian OS EXEs use "E32Main" entry point,
whereas OE EXEs use "main" entry point.
The UIDs used to identify native Symbian OS EXEs and DLLs are different when compared to OE EXEs and DLLs.
In a native Symbian OS executable, the functions and data symbols
with extern linkage are exported only if
IMPORT_C/EXPORT_C declarations are found in the
header or source files. In a OE executable, all functions and data symbols with
extern linkage are exported by default without
IMPORT_C/EXPORT_C declarations in the header or
source files.
The libraries required by a native Symbian OS executable/library have to be listed explicitly in the MMP file, whereas for an OE executable/library they are included by default.
The native Symbian OS EXEs and DLLs does not have symbol lookup, whereas OE EXEs and DLLs support symbol lookup using dlsym.
A native Symbian OS EXE, DLL or LIB must include the path to standard
APIs in the mmp file. For an OE EXE, DLL or LIB the build system
includes ${EPOCROOT}epoc32/include/stdapis as the default path for
header files.
The build system has been modified to support compilation of C++ source
files with extensions “.cc”, “.cxx” and
“.c++”. This change is applicable to both OE and native Symbian OS
executables and libraries. That is, from Symbian OS v9.3 onwards a native
Symbian OS or an OE executable/library can be built using C++ source files with
extensions “.cc”, “.cxx” and “.c++”.