x
This website is using cookies. We use cookies to ensure that we give you the best experience on our website. More info. That's Fine
HPC:Factor Logo 
 

Compiling for Windows CE 2.0 using embedded Visual C++ 3.0 file copy hack

CESD|200223

Applies To

  • Windows CE 2.0
  • Embedded Visual C++ 3.0

Overview

Microsoft did not include modular integration for the Windows CE 2.00 SDK in the release of Embedded Visual Tool 3.0 (eVT 3.0). This means that the eVC++ compiler cannot target for Windows CE 2.0. Users who wish to compile for Windows CE 2.0 must purchase Visual Studio 6.0 and the Windows CE Toolkit for Visual C++ 6.0.

This article outlines a series of steps that you can perform to compile against the Windows CE 2.0 compiler using the eVC++ 3.0 IDE.

This document was originally published by Brandon Streiff and documented by Pavel Koza from PDA Gold 11 February 2002.

Downloads

More Info

Programmers are sometime faced up to the task to create tiny program or utility for a machine with operating system Windows CE or Pocket PC. If you are experienced in the MS Visual C++ or Basic, this task can be easy - thanks to free download of Microsoft eMbedded Visual Tools. When you finish download of 300 MB file, you can start to develop... :-) Alas... Problem will appear, when the target computer is "powered by Microsoft Windows CE 2.0". It seems to be very ancient history (2 or 3 years) for MS. So Windows CE 2.0 is not supported in eVT. Unfortunately, I have spent some time on the similar problem. Here there is certain information about possibility to develop for computers with operating system Windows CE 2.0.

There is a lot of ways how to build a program. Unfortunately, most of them are commercial products. And that's why these are not suitable for building a tiny utility for your own purpose. Simple freeware tools may not be suitable for another reasons (e.g. too huge executable code, unstable run or not available necessary functions in the tool). The best way seems to take eVT from MS and to force it to generate code for WinCE 2.0. It seems to be an easy task - on the MS page is available SDK for HPC with Windows 2.0. Alas! (Another alas ...) SDK on the Web is "cut off" version and it doesn't work even with Windows CE Toolkit for Visual C++ 6.0, (It is determined for this toolkit!). I don't know why MS has placed unusable wreck of SDK for HPC on the Web. Surprisingly SDK for PalmPC is full and functional. They may have their reasons for it!? :-(

I found that a full and functional SDK for HPC is on CD "Windows CE Toolkit for Visual C++ 6.0". This version can be installed with eVT without problems. My sorrow - I found out no another source for functional HPC 2.0 SDK. The purchase of "Windows CE Toolkit" only for SDK is not right solution... Difference between both versions SDK is enclosed at the end of this text (I have got directory listing only). Searching discussion news on the Web gave me the instructions how to force eVT to compile for WinCE 2.0. It is from Brandon Streiff. I have tried it. And - it works! To spare your time here it is all with my comments.

  1. Download eVT from the link above and run the installer will extract into 2 directories - DISK1 and DISK2. eVT is in the first of them and the second directory includes SDKs. There is included necessary HPC Pro SDK (determined for HPC with WinCE 2.11).
  2. Download the file mplatsdk.exe (25 MB) from the second link above. This will extract into 2 directories listed at the end of this article.
  3. Install eVT (if it is not installed already) for the next instructions eVT is installed in "c:\program files\microsoft embedded tools\".
  4. You can start with amendment according to Brandon:
    1. install HPC Pro SDK e.g. to "d:\windows ce tools".
    2. install HPC SDK (version 2.0) to "d:\windows ce tools" as well
    3. made a copy of "d:\windows ce tools\wce211\ms hpc pro" for backup (for future restoration of HPC Pro SDK)
    4. delete "d:\windows ce tools\wce211\ms hpc pro\lib\arm" and "d:\windows ce tools\wce211\ms hpc pro\lib\sh4" directories, (there are no versions for WinCE 2.0)
    5. copy contents of "d:\windows ce tools\wce\lib\wce200\hpc\wcemips" over the contents of "d:\windows ce tools\wce211\ms hpc pro\lib\mips"
    6. copy contents of "d:\windows ce tools\wce\lib\wce200\hpc\wcesh" over the contents "d:\windows ce tools\wce211\ms hpc pro\lib\sh3"
    7. copy contents of "d:\windows ce tools\wce\lib\wce200\hpc\x86em" over the contents "d:\windows ce tools\wce211\ms hpc pro\lib\x86em"
    8. copy contents of "d:\windows ce tools\wce\include\hpc" over the contents "d:\windows ce tools\wce211\ms hpc pro\include"
    9. rename directory "c:\program files\microsoft embedded tools\evc\wce211" to "c:\program files\microsoft embedded tools\evc\wce211-backup"
    10. rename directory "c:\program files\microsoft embedded tools\evc\wce200" to "c:\program files\microsoft embedded tools\evc\wce211"
  5. If you choose HPC Pro 2.11 platform in eVT, your type of processor and build a program, it compiles for WinCE HPC 2.0. Move file to your Handheld and try it. Attention! MFC libraries are not included in the "cut off" SDK, that's why you must use only API functions. Choose "WCE Application" as a new project.
  6. The compiler warned that parameter "/MC" is unsupported. To suppress this select menu Project-Settings, choose C/C++ tab an remove parameter /M$(CECrtMT) in the Project Options.
  7. If you need to develop for WinCE 2.11, you must restore HPC Pro SDK!

/////////////////////////////////////////////////////////////////////
APPENDIX
/////////////////////////////////////////////////////////////////////

/*******************************************************************/
List of HPC SDK 2.0 on CD WindowsCE Toolkit for Visual C++6.0
/*******************************************************************/
Directory of D:\HPC20SDK

07/06/00 18:53 .
07/06/00 18:53 ..
29/08/97 14:19 320,127 _INST32I.EX_
26/08/97 12:02 8,192 _ISDEL.EXE
26/08/97 12:01 11,264 _SETUP.DLL
11/12/98 11:37 206,286 _sys1.cab
11/12/98 11:37 56,924 _user1.cab
11/12/98 11:37 152 DATA.TAG
11/12/98 11:44 39,529,647 data1.cab
07/06/00 18:53 emul
16/12/98 15:51 28,351 hpcreadme.htm
07/06/00 18:53 htmlhelp
30/05/97 11:31 4,557 lang.dat
11/12/98 11:44 353 layout.bin
07/06/00 18:53 objstore
06/05/97 14:15 417 os.dat
07/06/00 18:53 platman
19/03/97 11:28 15,872 regenv.exe
07/06/00 18:53 setup
12/11/97 15:53 481,078 setup.bmp
26/08/97 12:02 59,904 SETUP.EXE
11/12/98 11:37 87 SETUP.INI
11/12/98 11:35 87,019 setup.ins
11/12/98 11:44 47 setup.lid
24 File(s) 40,810,277 bytes

Directory of D:\HPC20SDK\emul

07/06/00 18:53 .
07/06/00 18:53 ..
17/12/97 06:48 14,304 wceemuld.sys
3 File(s) 14,304 bytes

Directory of D:\HPC20SDK\htmlhelp

07/06/00 18:53 .
07/06/00 18:53 ..
20/10/98 17:55 54,148 wceddk.chi
20/10/98 17:55 577,960 wceddk.chm
04/12/98 14:43 20,592 wcehpc.chi
04/12/98 14:43 147,220 wcehpc.chm
20/10/98 16:09 10,554 wcelib.chi
20/10/98 16:09 15,740 wcelib.chm
11/11/98 14:29 59,290 wcesdkg.chi
11/11/98 14:29 985,272 wcesdkg.chm
19/11/98 17:23 170,923 wcesdkr.chi
19/11/98 17:23 2,838,552 wcesdkr.chm
12 File(s) 4,880,251 bytes

Directory of D:\HPC20SDK\objstore

07/06/00 18:53 .
07/06/00 18:53 ..
17/12/97 06:50 16,777,216 hpc.obs
3 File(s) 16,777,216 bytes

Directory of D:\HPC20SDK\platman

07/06/00 18:53 .
07/06/00 18:53 ..
11/12/98 00:08 170,160 cemgr.exe
11/12/98 00:08 15,872 cemgrps.dll
11/12/98 00:09 375,636 cemgrui.dll
5 File(s) 561,668 bytes

Directory of D:\HPC20SDK\setup

07/06/00 18:53 .
07/06/00 18:53 ..
29/06/98 09:08 72,704 hhsetup.dll
04/12/98 09:46 68,608 htmlsetup.dll
01/12/98 18:53 74,752 pmsetup.dll
23/11/98 17:27 19,968 SetupHelp.exe
6 File(s) 236,032 bytes

Total Files Listed:
53 File(s) 63,279,748 bytes

/**********************************************************/
List of HPC SDK 2.0 available on Microsoftu web site
/**********************************************************/
Directory of D:\hpc20sdk

. 13.01.02 16.48 .
.. 13.01.02 16.48 ..
OBJSTORE 29.06.01 20.55 objstore
DATA TAG 152 06.01.98 13.31 DATA.TAG
DATA1 CAB 22 796 403 06.01.98 13.34 data1.cab
LANG DAT 4 557 30.05.97 11.31 lang.dat
LAYOUT BIN 353 06.01.98 13.34 layout.bin
OS DAT 417 06.05.97 14.15 os.dat
README HTM 34 770 05.01.98 10.15 readme.htm
REGENV EXE 15 872 19.03.97 11.28 regenv.exe
REGSVR32 EXE 37 648 20.12.99 9.48 regsvr32.exe
SETUP BMP 481 078 12.11.97 15.53 setup.bmp
SETUP EXE 59 904 15.07.97 10.56 SETUP.EXE
SETUP INI 87 06.01.98 13.31 SETUP.INI
SETUP INS 75 703 29.12.97 10.18 setup.ins
SETUP LID 49 06.01.98 13.34 setup.lid
_INST32I EX_ 320 133 14.07.97 13.08 _INST32I.EX_
_ISDEL EXE 8 192 14.07.97 16.37 _ISDEL.EXE
_SETUP DLL 11 264 14.07.97 16.35 _SETUP.DLL
_SYS1 CAB 205 658 06.01.98 13.31 _sys1.cab
_USER1 CAB 54 894 06.01.98 13.31 _user1.cab
18 File(s) 24 107 134 bytes

Directory of D:\hpc20sdk\objstore

. 13.01.02 16.48 .
.. 13.01.02 16.48 ..
HPC OBS 16 777 216 17.12.97 6.50 hpc.obs
1 File(s) 16 777 216 bytes

Acknowledgements

With thanks to Brandon Streiff and Pavel Koza for the original work. Re-published for archival purposes.