Partager via


Creating and Building Kitl.dll (Windows Embedded CE 6.0)

1/5/2010

Moving the KITL source code from the OAL into Kitl.dll should be a fairly straightforward process. Kitl.dll must export the following new functions:

  • OEMKitlStartup
    This function is called from the kernel when KITLIoctl(IOCTL_KITL_STARTUP, NULL, 0, NULL, 0, NULL) is invoked by the OAL.
    This function is equivalent to the OALKitlStart function, but it has been renamed to follow the convention for public OEM functions. The Windows Embedded CE 6.0 kernel requires that you use the new function name OEMKitlStartup.
  • OEMKitlIoctl
    This function handles all KITL-related IOCTLs when KITL is removed from the OAL. In most cases, you can use the common version of this function, which is implemented in Oal_Kitl.lib.

Procedure

To create and build Kitl.dll

  1. Move all your KITL-related source code from the Src\Oal\OalLib folder into the Src\Kitl folder.

    For more information on how to do this, see Removing KITL from the OAL.

  2. Copy the makefile from the Src\Oal\OalLib folder to the Src\Kitl folder.

  3. Create the sources file.

    To do this, use the following commands:

    TARGETNAME=KITL
    TARGETTYPE=DYNLINK
    DLLENTRY=KitlDllMain
    DEFFILE=
    

    Then, add the following TARGETLIBS: KitlCore.lib, OEMStub.lib, and NkStub.lib.

    These libraries are in addition to any other libraries required by your KITL implementation.

  4. Rename OALKitlStart to OEMKitlStartup.

  5. Initialize two KITL power function pointers in OEMKitlInit.

    To do this, use the following code example:

    pKitl->pfnPowerOn = OALKitlPowerOn;
    pKitl->pfnPowerOff = OALKitlPowerOff;
    

    This step is required only if your OAL is implementing these functions.

  6. Run the build command and verify that Kitl.dll builds without any errors.

See Also

Tasks

How to Separate the Kernel, OAL, and KITL

Concepts

BSP Migration Guide