Determining difference from Vista32 and Vista64

Discussion in 'Perl Misc' started by mpetersrx7@gmail.com, Apr 26, 2007.

  1. Guest

    Is ther any way to determine in the running code the type of OS and
    distinguish from 32-bit vs 64-bit Vista or XP. I know the
    Win32::GetOSVersion call but both the 32-bit and 64-bit of Vista
    return the same thing for $major, $minor and $id.

    Thanks,
    Mark
     
    , Apr 26, 2007
    #1
    1. Advertising

  2. Sisyphus Guest

    ----- Original Message -----
    From: <>
    Newsgroups: comp.lang.perl.misc
    Sent: Friday, April 27, 2007 2:56 AM
    Subject: Determining difference from Vista32 and Vista64


    > Is ther any way to determine in the running code the type of OS and
    > distinguish from 32-bit vs 64-bit Vista or XP. I know the
    > Win32::GetOSVersion call but both the 32-bit and 64-bit of Vista
    > return the same thing for $major, $minor and $id.
    >


    Ok - so you've worked out how to determine whether it's Vista or not.
    (Actually, I'd probably use Win32::GetOSName instead.)

    If it's a 64 bit operating system (both XP and Vista, I think) there'll be a
    C:\Windows\SysWOW64\ folder - otherwise that folder won't exist.

    Actually, faik, there may be a way of installing Windows in such a way that
    the system files don't go into the C drive at all .... which would
    complicate matters a little.

    Anyway, on my Vista64 box:

    C:\_32>perl -MWin32 -e "print Win32::GetOSName"
    WinVista
    C:\_32>perl -e "print -e 'C:/Windows/SysWOW64/cmd.exe'"
    1

    And that's the same irrespective of whether it's run in the
    C:\Windows\System32\cmd.exe shell or the C:/Windows/SysWOW64/cmd.exe shell
    .... and irrespective of whether I run ActiveState's 32-bit build of perl or
    their 64-bit build.

    Cheers,
    Rob
     
    Sisyphus, Apr 27, 2007
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. jakk
    Replies:
    4
    Views:
    12,227
  2. David
    Replies:
    1
    Views:
    1,120
    David
    Jan 13, 2009
  3. DwBear75

    installing 2.6 on vista64

    DwBear75, Jul 23, 2009, in forum: Python
    Replies:
    2
    Views:
    298
    Martin v. Löwis
    Jul 24, 2009
  4. Nick Timkovich
    Replies:
    0
    Views:
    69
    Nick Timkovich
    Feb 25, 2014
  5. Skip Montanaro
    Replies:
    0
    Views:
    65
    Skip Montanaro
    Feb 25, 2014
Loading...

Share This Page