I just downloaded Windows CE 5.0 Evaluation Edition. I'm trying to build
for a Geode platform, so that is what I selected. I then did a build and
sysgen, created an empty project, and inserted the "hello" sample app into
the project. When I build the project, I get "Wininet.h not found". I
defined "_WIN32_WCE_NO_ WININET" in stdafx.h to get past that. I then got
about 80 linker errors on various MFC classes, none of them directly from my
code.

I didn't do anything fancy, this must be a common problem, but I've seen
nothing on the newsgroups.

Can anybody help?

-Russ

Re: Porting to 5.0, bad libraries by Steve

Steve
Fri Aug 26 14:44:26 CDT 2005

What OS design template did you start with. What exactly are the errors? It
sounds like you started with a fairly limited OS design that won't support
MFC.

--
Steve Maillet
EmbeddedFusion
www.EmbeddedFusion.com
smaillet at EmbeddedFusion dot com



Re: Porting to 5.0, bad libraries by Russ

Russ
Fri Aug 26 16:10:34 CDT 2005

I think you're on to something, it makes sense.

The template I used is "WCE Application"; the only other template that
seemed reasonable was "WCE Console Application", but that sounded like
something running from a DOS prompt, which this is not.

These errors are from the "hello" sample (NOT the "hello" app offered as a
target.

BUILD: [01:0000000035:ERRORE] hello.obj : error LNK2001: unresolved external
symbol "protected: static struct AFX_MSGMAP const CDialog::messageMap"
(?messageMap@CDialog@@1UAFX_MSGMAP@@B)

BUILD: [01:0000000036:ERRORE] hello.obj : error LNK2001: unresolved external
symbol "protected: static struct AFX_MSGMAP const CFrameWnd::messageMap"
(?messageMap@CFrameWnd@@1UAFX_MSGMAP@@B)

BUILD: [01:0000000037:ERRORE] hello.obj : error LNK2001: unresolved external
symbol "unsigned short const * const _afxPchNil" (?_afxPchNil@@3PBGB)

BUILD: [01:0000000038:ERRORE] hello.obj : error LNK2001: unresolved external
symbol "public: virtual void __thiscall CWinApp::WinHelp(unsigned
long,unsigned int)" (?WinHelp@CWinApp@@UAEXKI@Z)

BUILD: [01:0000000039:ERRORE] hello.obj : error LNK2001: unresolved external
symbol "public: virtual int __thiscall CWinApp::OnDDECommand(unsigned short
*)" (?OnDDECommand@CWinApp@@UAEHPAG@Z)

BUILD: [01:0000000040:ERRORE] hello.obj : error LNK2001: unresolved external
symbol "public: virtual void __thiscall CWinApp::DoWaitCursor(int)"
(?DoWaitCursor@CWinApp@@UAEXH@Z)

BUILD: [01:0000000041:ERRORE] hello.obj : error LNK2001: unresolved external
symbol "public: virtual int __thiscall CWinApp::DoMessageBox(unsigned short
const *,unsigned int,unsigned int)" (?DoMessageBox@CWinApp@@UAEHPBGII@Z)

BUILD: [01:0000000042:ERRORE] hello.obj : error LNK2001: unresolved external
symbol "public: virtual int __thiscall CWinApp::SaveAllModified(void)"
(?SaveAllModified@CWinApp@@UAEHXZ)

BUILD: [01:0000000043:ERRORE] hello.obj : error LNK2001: unresolved external
symbol "public: virtual int __thiscall CWinApp::InitApplication(void)"
(?InitApplication@CWinApp@@UAEHXZ)

BUILD: [01:0000000044:ERRORE] hello.obj : error LNK2001: unresolved external
symbol "public: virtual void __thiscall
CWinApp::AddToRecentFileList(unsigned short const *)"
(?AddToRecentFileList@CWinApp@@UAEXPBG@Z)

BUILD: [01:0000000045:ERRORE] hello.obj : error LNK2001: unresolved external
symbol "public: virtual class CDocument * __thiscall
CWinApp::OpenDocumentFile(unsigned short const *)"
(?OpenDocumentFile@CWinApp@@UAEPAVCDocument@@PBG@Z)

BUILD: [01:0000000046:ERRORE] hello.obj : error LNK2001: unresolved external
symbol "public: virtual void __thiscall CWinThread::Delete(void)"
(?Delete@CWinThread@@UAEXXZ)

BUILD: [01:0000000047:ERRORE] hello.obj : error LNK2001: unresolved external
symbol "public: virtual class CWnd * __thiscall
CWinThread::GetMainWnd(void)" (?GetMainWnd@CWinThread@@UAEPAVCWnd@@XZ)

I appreciate your help.

-Russ



"Steve Maillet (eMVP)" <nospam1@EntelechyConsulting.com> wrote in message
news:Oxl2qanqFHA.2696@TK2MSFTNGP11.phx.gbl...
> What OS design template did you start with. What exactly are the errors?
It
> sounds like you started with a fairly limited OS design that won't support
> MFC.
>
> --
> Steve Maillet
> EmbeddedFusion
> www.EmbeddedFusion.com
> smaillet at EmbeddedFusion dot com
>
>



Re: Porting to 5.0, bad libraries by Bruce

Bruce
Fri Aug 26 16:27:03 CDT 2005

Does your platform include MFC?

--
Bruce Eitman (eMVP)
Senior Engineer
beitman AT applieddata DOT net

Applied Data Systems
www.applieddata.net
An ISO 9001:2000 Registered Company
Microsoft WEP Gold-level Member


"Russ Bakke" <russ.bakke@ziehm.com> wrote in message
news:%23GKqwJoqFHA.3720@TK2MSFTNGP14.phx.gbl...
>I think you're on to something, it makes sense.
>
> The template I used is "WCE Application"; the only other template that
> seemed reasonable was "WCE Console Application", but that sounded like
> something running from a DOS prompt, which this is not.
>
> These errors are from the "hello" sample (NOT the "hello" app offered as a
> target.
>
> BUILD: [01:0000000035:ERRORE] hello.obj : error LNK2001: unresolved
> external
> symbol "protected: static struct AFX_MSGMAP const CDialog::messageMap"
> (?messageMap@CDialog@@1UAFX_MSGMAP@@B)
>
> BUILD: [01:0000000036:ERRORE] hello.obj : error LNK2001: unresolved
> external
> symbol "protected: static struct AFX_MSGMAP const CFrameWnd::messageMap"
> (?messageMap@CFrameWnd@@1UAFX_MSGMAP@@B)
>
> BUILD: [01:0000000037:ERRORE] hello.obj : error LNK2001: unresolved
> external
> symbol "unsigned short const * const _afxPchNil" (?_afxPchNil@@3PBGB)
>
> BUILD: [01:0000000038:ERRORE] hello.obj : error LNK2001: unresolved
> external
> symbol "public: virtual void __thiscall CWinApp::WinHelp(unsigned
> long,unsigned int)" (?WinHelp@CWinApp@@UAEXKI@Z)
>
> BUILD: [01:0000000039:ERRORE] hello.obj : error LNK2001: unresolved
> external
> symbol "public: virtual int __thiscall CWinApp::OnDDECommand(unsigned
> short
> *)" (?OnDDECommand@CWinApp@@UAEHPAG@Z)
>
> BUILD: [01:0000000040:ERRORE] hello.obj : error LNK2001: unresolved
> external
> symbol "public: virtual void __thiscall CWinApp::DoWaitCursor(int)"
> (?DoWaitCursor@CWinApp@@UAEXH@Z)
>
> BUILD: [01:0000000041:ERRORE] hello.obj : error LNK2001: unresolved
> external
> symbol "public: virtual int __thiscall CWinApp::DoMessageBox(unsigned
> short
> const *,unsigned int,unsigned int)" (?DoMessageBox@CWinApp@@UAEHPBGII@Z)
>
> BUILD: [01:0000000042:ERRORE] hello.obj : error LNK2001: unresolved
> external
> symbol "public: virtual int __thiscall CWinApp::SaveAllModified(void)"
> (?SaveAllModified@CWinApp@@UAEHXZ)
>
> BUILD: [01:0000000043:ERRORE] hello.obj : error LNK2001: unresolved
> external
> symbol "public: virtual int __thiscall CWinApp::InitApplication(void)"
> (?InitApplication@CWinApp@@UAEHXZ)
>
> BUILD: [01:0000000044:ERRORE] hello.obj : error LNK2001: unresolved
> external
> symbol "public: virtual void __thiscall
> CWinApp::AddToRecentFileList(unsigned short const *)"
> (?AddToRecentFileList@CWinApp@@UAEXPBG@Z)
>
> BUILD: [01:0000000045:ERRORE] hello.obj : error LNK2001: unresolved
> external
> symbol "public: virtual class CDocument * __thiscall
> CWinApp::OpenDocumentFile(unsigned short const *)"
> (?OpenDocumentFile@CWinApp@@UAEPAVCDocument@@PBG@Z)
>
> BUILD: [01:0000000046:ERRORE] hello.obj : error LNK2001: unresolved
> external
> symbol "public: virtual void __thiscall CWinThread::Delete(void)"
> (?Delete@CWinThread@@UAEXXZ)
>
> BUILD: [01:0000000047:ERRORE] hello.obj : error LNK2001: unresolved
> external
> symbol "public: virtual class CWnd * __thiscall
> CWinThread::GetMainWnd(void)" (?GetMainWnd@CWinThread@@UAEPAVCWnd@@XZ)
>
> I appreciate your help.
>
> -Russ
>
>
>
> "Steve Maillet (eMVP)" <nospam1@EntelechyConsulting.com> wrote in message
> news:Oxl2qanqFHA.2696@TK2MSFTNGP11.phx.gbl...
>> What OS design template did you start with. What exactly are the errors?
> It
>> sounds like you started with a fairly limited OS design that won't
>> support
>> MFC.
>>
>> --
>> Steve Maillet
>> EmbeddedFusion
>> www.EmbeddedFusion.com
>> smaillet at EmbeddedFusion dot com
>>
>>
>
>



Re: Porting to 5.0, bad libraries by Steve

Steve
Fri Aug 26 16:26:38 CDT 2005

Wrong kind of template - I meant for the Complete OS. When you used the new
platform wizard to create a new OS design - what did you select as the OS
Design template?

--
Steve Maillet
EmbeddedFusion
www.EmbeddedFusion.com
smaillet at EmbeddedFusion dot com



Re: Porting to 5.0, bad libraries by Russ

Russ
Mon Aug 29 12:18:18 CDT 2005

I'm sorry, I misunderstood.

I just went back and created a new platform. I used the template for
"Custom Device" and selected (oops, can't read my notes: Cbitereg?), MFC,
SDK, Display Serial, about 4 fonts, GWE, shell, UI.

I created a blank project, then inserted the files for the sample "hello"
program, in this platform.

I then did a "OS build and sysgen". This was successful until it got to
where it tried to build the hello program, that gave me about a hundred
errors, all of which appear to be MFC library link errors.

I see where the platform template selection is critical to this, and if I
hadn't selected MFC support I'd get these errors, but I do have MFC
selected.

-Russ


"Steve Maillet (eMVP)" <nospam1@EntelechyConsulting.com> wrote in message
news:uzF5xToqFHA.460@TK2MSFTNGP15.phx.gbl...
> Wrong kind of template - I meant for the Complete OS. When you used the
new
> platform wizard to create a new OS design - what did you select as the OS
> Design template?
>
> --
> Steve Maillet
> EmbeddedFusion
> www.EmbeddedFusion.com
> smaillet at EmbeddedFusion dot com
>
>



Re: Porting to 5.0, bad libraries by Russ

Russ
Mon Aug 29 12:36:17 CDT 2005

It just occurred to me: When I first ran Win CE 5.0 a couple of weeks ago,
it complained that it couldn't find some include files in a directory which
was in the Visual Studio 2003 package; I use that for another project. So I
set the system environment variable INCLUDE to point to what seemed the
correct place in Win CE 5.0 instead. But I also set LIB at the same time,
and I'll bet it's wrong. Are these needed? What should they be set to?

-Russ

"Steve Maillet (eMVP)" <nospam1@EntelechyConsulting.com> wrote in message
news:uzF5xToqFHA.460@TK2MSFTNGP15.phx.gbl...
> Wrong kind of template - I meant for the Complete OS. When you used the
new
> platform wizard to create a new OS design - what did you select as the OS
> Design template?
>
> --
> Steve Maillet
> EmbeddedFusion
> www.EmbeddedFusion.com
> smaillet at EmbeddedFusion dot com
>
>



Re: Porting to 5.0, bad libraries by Steve

Steve
Mon Aug 29 14:07:04 CDT 2005

Unless you really know what you are doing selecting custom device is a bad
idea, you can get into situations where stuff won't build right. Pick an OS
design template that closely matches what you need then select the sub
features in the wizard as necessary. If you still need to add or remove
something you can then do it in the IDE later. It's much easier that way.

The CE build system will set up it's own environment variables setting
global ones for the compiler and linker have no effect.

--
Steve Maillet
EmbeddedFusion
www.EmbeddedFusion.com
smaillet at EmbeddedFusion dot com