A side effect of our using a "tweaked" A400V4 SDK rather than A400V4i SDK is that the machine type for new C++ projects defaults to ARM. However our BSP (including libraries like CEDDK.lib) is built with machine type set to THUMB, which is right for A400V4i.
The eVC++ compiler will refuse to link them so you have to tell eVC++ you want it to build thumb code for the application.
This is okay to do because Thumb is simply a subset of Arm architecture. Instructions are compressed into 16 bit wide operations codes and decompressed to 32 bit ARM instructions on execution. This makes the binaries a little bit smaller.
The solution for projects which need to link to A400V4i libraries is the following:
1. With your eVC++ project open, go to Project Settings.
2. Choose Release under the “Settings For” drop down menu
3. Under the Link tab, in the Project Options text box change /MACHINE:ARM to /MACHINE:THUMB
4. Choose Debug under the “Settings For” drop down menu
5. Repeat step 3.
Since each A400V4 project defaults the /MACHINE to ARM, this should be done once to each project which will link A400V4i libraries.
References:
http://msdn.microsoft.com...ml/cmrefLinking.asp)
http://msdn.microsoft.com...ml/ccrefARMGuide.asp
You can inspect the machine setting for a library using the dumpbin packaged with eVC++. For example:
D:\WINCE420\PLATFORM\LoCE_A400_rel_101\lib\ARMV4I\retail>dumpbin ceddk.lib /headers
<snip>
Version : 0
Machine : 1C2 (Thumb)
TimeDateStamp: 4084D20B Tue Apr 20 02:32:27 2004
SizeOfData : 00000020
DLL name : CEDDK.dll
Symbol name : WRITE_REGISTER_USHORT
Type : code
Name type : name
Hint : 35
Name : WRITE_REGISTER_USHORT
Summary
C0 .debug$S
14 .idata$2
14 .idata$3
4 .idata$4
4 .idata$5
A .idata$6