Hi Jiehua,
Please review the instructions on my webpage : in particular use my compilation scripts, and look inside them to know the syntax.
It is quite simple : makece X86 for stunnel.
For openssl, "mywcebuild X86".

It works.

Let me know if you have problems.
Pierre


Le 10/01/2011 17:40, Li, Jiehua a écrit :
Dear Pierre and Dear Stunnel Users,
 
We are trying to build stunnel for WinCE on X86 processor. After reviewing messages on the board, I found your article published in late November. I’ve downloaded packages from your personal website at http://delaage.pierre.free.fr/
 
These packages include:
1.    Precompiled wcecompat library 
2.    Source code for openssl v100a for WCE. 
3.    Source code for stunnel v434 for WCE.
 
I was hoping to the get the precompiled openssl library files, but it seems there are only library files for ARM processor under the folder of “out32dll_ARMV4” and there’s no precompiled version for X86. So I tried to compile the openssl downloaded from your website for the X86 processor after customizing a few parameters (OSVERSION, PLATFORM, WCEROOT, SDKROOT, WCECOMPAT) as you suggested. But the compilation failed, I got error messages as below. I’m also including all options for cl.exe in the email as well. I wonder if you have seen similar issues before. Any suggestion is appreciated. Thanks for the help.
 
Regards,

Jiehua
 
        cl.exe /Fotmp32dll_x86\cryptlib.obj  -Iinc32 -Itmp32dll_x86 /MC  /O1 /Oi
 /W3 /WX /GF /Gy /nologo -DUNICODE -D_UNICODE -DOPENSSL_SYSNAME_WINCE -DWIN32_LE
AN_AND_MEAN -DL_ENDIAN -DDSO_WIN32 -DNO_CHMOD -DOPENSSL_SMALL_FOOTPRINT -D_WIN32
_WCE=420 -DUNDER_CE=420 -DWCE_PLATFORM_STANDARDSDK_420 -Dx86 -D_ -IC:\STunnel\wc
ecompat12_patched2X86\patchedX86/include -DOPENSSL_NO_RC5 -DOPENSSL_NO_MD2 -DOPE
NSSL_NO_KRB5 -DOPENSSL_NO_JPAKE -DOPENSSL_NO_STATIC_ENGINE /Zi /Fdtmp32dll_x86/l
ib -D_WINDLL -D_DLL  -DOPENSSL_BUILD_SHLIBCRYPTO -c .\crypto\cryptlib.c
Command line warning D4002 : ignoring unknown option '/MC'
cryptlib.c
C:\Program Files\Windows CE Tools\WCE420\STANDARDSDK_420\include\x86\winnt.h(301
9) : error C2061: syntax error : identifier 'PCONTEXT'
C:\Program Files\Windows CE Tools\WCE420\STANDARDSDK_420\include\x86\winnt.h(302
0) : error C2059: syntax error : '}'
C:\Program Files\Windows CE Tools\WCE420\STANDARDSDK_420\include\x86\winbase.h(1
481) : error C2061: syntax error : identifier 'LPCONTEXT'
C:\Program Files\Windows CE Tools\WCE420\STANDARDSDK_420\include\x86\winbase.h(1
481) : error C2059: syntax error : ';'
C:\Program Files\Windows CE Tools\WCE420\STANDARDSDK_420\include\x86\winbase.h(2
222) : error C2146: syntax error : missing ')' before identifier 'lpContext'
C:\Program Files\Windows CE Tools\WCE420\STANDARDSDK_420\include\x86\winbase.h(2
222) : error C2081: 'LPCONTEXT' : name in formal parameter list illegal
C:\Program Files\Windows CE Tools\WCE420\STANDARDSDK_420\include\x86\winbase.h(2
222) : error C2061: syntax error : identifier 'lpContext'
C:\Program Files\Windows CE Tools\WCE420\STANDARDSDK_420\include\x86\winbase.h(2
222) : error C2059: syntax error : ';'
C:\Program Files\Windows CE Tools\WCE420\STANDARDSDK_420\include\x86\winbase.h(2
223) : error C2059: syntax error : ')'
C:\Program Files\Windows CE Tools\WCE420\STANDARDSDK_420\include\x86\winbase.h(2
230) : error C2143: syntax error : missing ')' before '*'
C:\Program Files\Windows CE Tools\WCE420\STANDARDSDK_420\include\x86\winbase.h(2
230) : error C2143: syntax error : missing '{' before '*'
C:\Program Files\Windows CE Tools\WCE420\STANDARDSDK_420\include\x86\winbase.h(2
231) : error C2059: syntax error : ')'
NMAKE : fatal error U1077: 'cl.exe' : return code '0x2'
Stop.