none
Cannot Target XP though SDK says it can.... Hmmm

    Question

  • Hi, I was wondering how to target XP from VS2008 and with the 6.1 SDK installed?  I am getting entrypoint not found in user32.dll when my app runs under XP. (Works fine btw in 2008 & Vista x86 or x64).

     

    I thought that the idea was that "the 6.1 SDK" can target xp / W2K3 / Vista / Server 2008.

     

    But earlier versions of user32.lib cannot be found. Sure, I solved this problem by grabbing user32.lib from the SDK folder of a VS2005 full install. But that's hardly the point is it.

     

    Did I miss something?  Oh, the export is ChangeWindowsMessageFilter.... Any suggestions?

     

    Thanks!

     

    Sunday, November 23, 2008 3:24 AM

All replies

  • The ChangeWindowMessageFilter function is Vista Only so if you don't get compiler error, then your target OS is Vista or newer.
    Sunday, November 23, 2008 3:56 PM
  • Thanks Sheng, but I am targeting XP, so, therefore I should be able to build using latest SDK. Yes?

    The settings in VS2008 are Win32, static link (/MT).

     

    Yes, the prog makes (compiles/links) fine in VC 2008 & runs fine on my build environment (Server 2008 Enterprise x64) i.e. NT 6 and above - & both x86 & x64 i.e. Vista / W7.

     

    But, in order to get prog to load on XP I need to find an old user32.lib from previous SDK's (I found one in 6.1 DDK actually) and put that in the dependancy list for the linker. So, I guess that was my dissapointment. With the earlier user32.lib the prog runs fine on all platforms.

     

    I set winver lower to see if that would help, but no luck.

     

    Btw, I'm not calling this export in my code, the app is looking for it because of some other dependancy.

     

    So, I guess I would just like to confirm with the experts that this is a good workaround & the ChangeWindowMessageFilter call is not a 'required' export for XP's user32.dll.

     

    Thanks,

    Ring0

    Sunday, November 23, 2008 8:32 PM
  • Maybe you intended to target Windows XP, but from what you are describing, you are not.
    Your problem maybe a missing conditional declaration
    Sunday, November 23, 2008 8:57 PM
  • Dear Sheng, I tried 0x0500 as the winver already.

     

    I'm just saying that this is just one of those things. I think this is a rare problem when user32.dll function exports are missing from the (2K/XP) USER32.dll, and the compile/link was run with the "lastest SDK" user32.lib dependancy.

     

    And so, "did I do the right thing"? By giving the compile/link the older user32.lib to chew on?

     

    Or am I getting too old & forgot my 1993 learnings abot .DEF files and ordinals 

    EXPORTS etc.

     

    I'm not too stressed about it. As I said, I can & did grab an old user32.lib and that does not cause the NT 5 / 5.1 / 5.2 loaders to cry out "missing entrypoint".

    As I said - all platforms run my app. just fine when built with the older XP user32.lib.

     

    Vista and higher are obviously not attempting any call into ChangeWindowsMessageFilter for the PE I made using older XP version of user32.lib.

     

    Thanks!

    Ring0

     

     

     

     

    Monday, November 24, 2008 2:17 AM