首 页 | 新 闻 | Symbian | Android| Windows Mobile | J2ME | 下载中心 | 游戏策划招聘与求职 | 购书指南 | 视频教程
您现在的位置: 开发视界 >> Symbian英文资料 >> Tools SDK >> 正文
How to compile for WINSCW without a CodeWarrior or Visual Studio IDE
作者:佚名    文章来源:不详    更新时间:2006-5-7 11:22:25

Traditionally, there have been two different versions of the Symbian emulator under Windows:

  WINS (to be used with Visual Studio and Borland)
  WINSCW (to be used with CodeWarrior)

This became neccessary because that the binaries created by the different supported C++ compilers are not all interoperable (for example, C++ classes are laid out in memory in a different way). As a result, the entire emulator had to be built with a compiler that is compatible to the one you are using [1].

With all SDKs prior to Series 60 2nd Edition, FP3 this has required Nokia to publish different versions for CodeWarrior and VS/Borland of each of the SDKs, with the main difference being the included emulator.

However, the FP3 SDK (which can be downloaded here has so far only been released with a WINSCW emulator, so it is only compatible with CodeWarrior “out of the box”.

To use it with the Visual Studio .NET 2003 IDE, Nokia recommends installing the Nokia Developer’s Suite for Symbian OS package. This add-on can only be installed if VS.NET is actually detected on the machine.

Now what to do if you want to use another IDE, such as Visual Studio 6.0, or a free one like Eclipse? It turns out that the Developer’s Suite in fact comes with a self-contained command line compiler that can be used by the Symbian toolchain, and does not depend on VS.NET at all (probably as a result of Nokia’s acquisition of some of Metrowerks’ technology). Nokia have even included documentation on how to install the compiler “by hand” - but so far have simply not made it available outside the Developer’s Suite package.

How to install the compiler without using the installer

Since the installer for NDS is built around self-extracting .zip and .jar files (which in turn are actually zips for the most port), the only tool required is an unzipping utility for Windows - I have used WinZip, which even lets you look into the self-extracting exe by just right-clicking it.

So here are the steps that worked for me:

  1. Download the file nds_symbian_vs_11.exe from here
  2. Open it with WinZip, or another tool of your choice
  3. Extract the file Resource1.zip in InstallerData\Disk1\InstData (the biggest file in the package)
  4. From Resource1.zip, you need only the files under the path C_\Nokia_x86_CompLink3.2.3_b437_Beta3
  5. Rename the .jar files to .zip, if your tool doesn’t let you view their contents already

You can now just have a look at the file Nokia3.2.3x86Compiler_READMEFIRST.html to find out some more about the compiler (this file also describes the file layout into which the .jar files have to be extracted).

Now you can unpack the following three zips/jars with pathnames into the following subdirectories under a common directory (I used C:\Symbian\MWCC):

Name of zip/jar Name of target folder
bin_zg_ia_sf bin
Symbian_Support_zg_ia_sf Symbian_Support
Symbian_Tools_zg_ia_sf Symbian_Tools

You should end up with something like this:

\Symbian
 \MWCC
   \Symbian_Support
     \MSL ...
     \Runtime ...
     \Win32-x86 Support ...
   \Symbian_Tools
     \Command_Line_Tools ...
   \bin

Almost done... now the only thing left is to run the env_update.exe tool in the bin subdirectory, and tell it that you want to use the 3.2.x version. This will set the environment variables needed to run the compiler.

After logging off from Windows and back on (to make sure the environment changes take full effect), you should now be able to use the compiler to build your first WINSCW project, by going to a directory with a Symbian bld.inf file, and trying something like this (assuming that you are using the 2nd Edition, FP3 SDK.):

bldmake bldfiles @S60_2nd_FP3:com.nokia.series60
abld build winscw udeb @S60_2nd_FP3:com.nokia.series60

As the Nokia3.2.3x86Compiler_READMEFIRST.html document points out, the resulting code can even be debugged in Visual Studio 6.0 as normal. To do this, just use the “Open Workspace...” command in VS6 to open the ...\winscw\udeb\epoc.exe executable, and start the debugger.



[1] This does not affect compiling for the phone itself, as this always uses GCC.

相关文章:
How to reset the alternate makmake entry in Codewarrior
Integrating LeaveScan into Codewarrior 3.x
Codewarrior: how to avoid the "Too Many Include Paths" error when using the UIQ 2.1 SDK
Carbide.c++: Setting up On Target Debugging
Using SIP with Nokia Series60 and Asterisk
How to get a Series 60 phone firmware version number ?
How to identify a mobile at execution or installation time
Compress Your Symbian C++ Executables
 

站点地图 | 加入收藏 | 联系站长 | 广告服务 |
QQ:280529124  Tel:0592-8271361 辽ICP备05021703号