Re: Unresolved Externals creating driver
From: Susan (susan_at_pile_HATE_SPAM_DOT_com)
Date: 10/04/04
- Next message: Susan: "Re: Unresolved Externals creating driver"
- Previous message: Dean Ramsier: "Re: GetTickCount problem on Intel PXA255 platform"
- In reply to: Susan: "Unresolved Externals creating driver"
- Next in thread: Susan: "Re: Unresolved Externals creating driver"
- Reply: Susan: "Re: Unresolved Externals creating driver"
- Messages sorted by: [ date ] [ thread ]
Date: Mon, 4 Oct 2004 15:00:43 -0400
So, I shouldn't have added usbd_lib.lib since that does cinldue ClosePipe
(as does one of my source files).
Removing that, and adding the library usbclient.lib, is now have
usbpdi.obj : error LNK2019: unresolved external symbol
RegisterClientSettings referenced in function USBInstallDriver
usbpdi.obj : error LNK2019: unresolved external symbol
RegisterClientDriverID referenced in function USBInstallDriver
usbpdi.obj : error LNK2019: unresolved external symbol
UnRegisterClientDriverID referenced in function USBUnInstallDriver
usbpdi.obj : error LNK2019: unresolved external symbol
UnRegisterClientSettings referenced in function USBUnInstallDriver
corelibc.lib(pegwmain.obj) : error LNK2019: unresolved external symbol
WinMain referenced in function WinMainCRTStartup
But this is progress, so I'm much happier.
"Susan" <susan@pile_HATE_SPAM_DOT_com> wrote in message
news:uBItk8jqEHA.3868@TK2MSFTNGP15.phx.gbl...
> Well, I'm a little disappointed in myself in that I'm resorting to help
this
> early, but...
>
>
>
> All I'm trying to do is take the current USB Mass Storage Class and create
> an identical driver, under a different name.
>
>
>
> I've tried three different scenarios, in order to create a 'dummy' driver
> based on the USB Mass Storage Driver class. In all three cases, I wind up
> with undefined externals/multiply defined objects. (I thought maybe I
didn'
> t create my platform correctly - didn't pull in all the needed files, but
> one of my attempts at creating this 'dummy' driver doesn't even use PB.
And
> I get the exact same error messages.)
>
>
>
> I grab the directory
>
> C:\WINCE420\PUBLIC\COMMON\OAK\DRIVERS\USB\CLASS\STORAGE\CLASS
>
> and copy it to
>
> C:\WINCE420\PLATFORM\ARMINTEGRATOR\DRIVERS
>
> then rename the directory 'USBPDI'.
>
>
>
> Now, according to "How to Create a Device Driver" (from MS instructions),
I
> am supposed to rename the "sample driver files to names that correspond
with
> the intended functionality of" my driver. So,
>
> usbmsc.c becomes usbpdi.c
>
> usbmscp.h becomes usbpdip.h
>
>
>
> (OK. On my third attempt I ran out of descriptive names for device
> functionality, and was very close to becoming crass.)
>
>
>
> The files 'sources' is edited:
>
> TARGETNAME = USBMSC_LIB becomes TARGETNAME=USBPDI_LIB
>
>
>
> SOURCES = \
>
> BOT.C \
>
> CBIT.C \
>
> USBMSC.C \
>
>
>
> becomes
>
>
>
> SOURCES = \
>
> BOT.C \
>
> CBIT.C \
>
> USBPDI.C \
>
>
>
> Finally,
>
> WINCEOEM=1
>
> is added to the 'sources' file.
>
>
>
> I have a 'platform' created into which I add a project of type WCE dynamic
> link library - an empty project. Once created, I drag all the files in
> directory
>
> C:\WINCE420\PLATFORM\ARMINTEGRATOR\DRIVERS
>
> into the newly created project. (Well, all the files except 'makefile'.)
>
>
>
> Naturally, I didn't change the #include directives to match the above
> changes, so I have to edit bot.h, cbit.h and usbpdi.c, and change
>
> #include "usbmscp.h" to #include "usbpdip.h"
>
>
>
> I build once again, only to get "Cannot open include file: 'warning.h': No
> such file or directory". So I add the following data to the Project
> Settings, C/C++ tab, Additional Include Directories:
> C:\WINCE420\PUBLIC\COMMON\OAK\DRIVERS\USB\CLASS\COMMON
>
>
>
> And rebuild. And get "Cannot open include file: 'usbmsc.h': No such file
or
> directory".
>
> So back to the same Tab in the Project Settings to add
>
> C:\WINCE420\PUBLIC\COMMON\OAK\DRIVERS\USB\CLASS\STORAGE\INC
>
> to the Additional Include Directories.
>
>
>
> Rebuild.
>
>
>
> And this is where it all falls apart.
>
>
>
> I get in this vicious circle of putting in a reference to a library, then
> having the build complain about multiply defined symbols.
>
>
>
> Complaint: unresolved external symbol ResetDefaultEndpoint referenced in
> function BOT_MassStorageReset
>
>
>
> So I add usbd_lib.lib as an Object/Library Module on the Link tab of
Project
> Settings, and since the build still complains, I also have to give it the
> path where it can find that darn library. So as an Additional Library
Path,
> I add C:\WINCE420\PUBLIC\COMMON\OAK\LIB\ARMV4I\RETAIL
>
>
>
> Now I have "error LNK2005: ClosePipe already defined in usbpdi.obj", in
> addition to the original error about ResetDefaultEndpoint.
>
>
>
> And no matter what I do, I can't seem to resolve these?
>
>
>
> From another post, I read that all I should need to include is
usbd_lib.lib.
>
>
>
> Obviously, whatever I'm during wrong, I'm doing CONSISTENTLY wrong, since
I
> can't get away from these messages.
>
>
>
> I'm leaning towards the problem being in the paths I added via Project
> Settings - meaning I should not have hardcoded the values, but used more
> 'generic' versions. But, I haven't been able (yet) to determine what
those
> 'generic' paths should look like.
>
>
>
> Any help would be appreciated.
>
>
- Next message: Susan: "Re: Unresolved Externals creating driver"
- Previous message: Dean Ramsier: "Re: GetTickCount problem on Intel PXA255 platform"
- In reply to: Susan: "Unresolved Externals creating driver"
- Next in thread: Susan: "Re: Unresolved Externals creating driver"
- Reply: Susan: "Re: Unresolved Externals creating driver"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|
|