#716 Support Windows Server 2012

Next
closed-fixed
Platform (66)
5
2012-09-25
2012-09-07
No

Recognize Windows Server 2012 based on the OS version/release information.
Windows Server 2012 was made available on 09/04/2012 and is only for x64_86 systems.

The version number of Windows Server 2012 and Windows 8 are identical (6.2), so must also test if ProductType is 1 (VER_NT_WORKSTATION). If so, it's Windows 8, otherwise it is Windows Server 2012.

I'd already added a check in STAF V3.4.9 to set STAF/OS/Name to Win8 if the Windows version is 6.2. So, now need to check if Product Type is 1 (VER_NT_WORKSTATION) and if not, set STAF/OS/Name to WinSrv2012.

Also, need to test STAF on Windows Server 2012.

Will also need to upgrade to InstallAnywhere FP 4 (just released) which provides support for Windows Server 2012 and Windows 8 64-bit (there's a separate feature for this).

Discussion

  • Sharon Lucas

    Sharon Lucas - 2012-09-10

    Here's a cvs diff of the changes to recognize Windows Server 2012 and to set STAF/OS/Name to "WinSrv2012" (not "Win8"). This fix will be in STAF V3.4.11 planned to be released at the end of September 2012.

    Index: stafif/win32/STAFUtilWin32.h

    RCS file: /cvsroot/staf/src/staf/stafif/win32/STAFUtilWin32.h,v
    retrieving revision 1.11
    diff -r1.11 STAFUtilWin32.h
    37a38
    > kSTAFWinSrv2012 = 0x8000,
    43c44
    < 0x1000 | 0x2000 | 0x4000 | 0x0080),
    ---
    > 0x1000 | 0x2000 | 0x4000 | 0x8000 | 0x0080),
    46c47
    < 0x2000 | 0x4000 | 0x0080),
    ---
    > 0x2000 | 0x4000 | 0x8000 | 0x0080),
    48c49
    < 0x4000 | 0x0080),
    ---
    > 0x4000 | 0x8000 | 0x0080),
    49a51,52
    > 0x8000 | 0x0080),
    > kSTAFWinVistaPlus = (0x0400 | 0x0800 | 0x1000 | 0x2000 | 0x4000 | 0x8000 |

    51,52c54
    < kSTAFWinVistaPlus = (0x0400 | 0x0800 | 0x1000 | 0x2000 | 0x4000 | 0x0080),

    < kSTAFWinSrv2008Plus = (0x0800 | 0x1000 | 0x2000 | 0x4000 | 0x0080)
    ---
    > kSTAFWinSrv2008Plus = (0x0800 | 0x1000 | 0x2000 | 0x4000 | 0x8000 | 0x0080
    )
    Index: stafif/win32/STAFUtil.cpp
    ===================================================================
    RCS file: /cvsroot/staf/src/staf/stafif/win32/STAFUtil.cpp,v
    retrieving revision 1.28
    diff -r1.28 STAFUtil.cpp
    215c215,218
    < // Windows 8
    ---
    > // Because the version numbers for Windows Server 2012
    > // and Windows 8 are identical (6.2), we must also test if

    > // the productType is 1 (VER_NT_WORKSTATION). If so, then

    > // it's Windows 8, otherwise it's Windows Server 2012.
    217c220,272
    < type = kSTAFWin8;
    ---
    > BYTE productType = 1; // Default to Workstation type
    >
    > // Call GetVersionEx using the OSVERSIONINFOEX structure
    > // to get the wProductType field.
    >
    > // Note: Using the OSVERSIONINFOEX structure requires
    > // Windows 2000 or later which is why we had to call
    > // GetVersionEx earlier using the OSVERSIONINFO structure
    > // as it works with earlier Windows versions.
    >
    > OSVERSIONINFOEX osVersionInfoEx =
    > { sizeof(OSVERSIONINFOEX), 0 };
    >
    > if (GetVersionEx((OSVERSIONINFO *) &osVersionInfoEx))
    > {
    > // However, the wProductType field is not available
    > // in the OSVERSIONINFOEX structures until VC++ 7.0.
    > // In VC++ 6.0, the wReserved field is defined as:
    > // WORD wReserved[2].
    > // In VC++ 7.0 and later versions, these last 4 bytes
    > // are defined as:
    > // WORD wSuiteMask;
    > // BYTE wProductType;
    > // BYTE wReserved;
    > #ifdef _MSC_VER
    > #if _MSC_VER < 1300
    > // Compiling using VC++ 6.0 or earlier as
    > // 1300 is the version number for VC++ 7.0
    >
    > // Get productType from the 1st byte in the 2nd
    > // word of the wReserved field
    > union
    > {
    > BYTE half[2];
    > WORD whole;
    > } data;
    >
    > data.whole = osVersionInfoEx.wReserved[1];
    > productType = data.half[0];
    > #else
    > // Compiling using VC++ 7.0 or later
    > productType = osVersionInfoEx.wProductType;
    > #endif
    > #endif
    > }
    >
    > // VER_NT_WORKSTATION = 1
    > // However, it's not defined until VC++ 7.0 so can't use
    >
    > if (productType == 1)
    > type = kSTAFWin8;
    > else
    > type = kSTAFWinSrv2012;
    331d385
    < case kSTAFWin8: osName = "Win8"; break;
    332a387,388
    > case kSTAFWin8: osName = "Win8"; break;
    > case kSTAFWinSrv2012: osName = "WinSrv2012"; break;

     
  • Sharon Lucas

    Sharon Lucas - 2012-09-24

    Here's a cvs diff of the changes to document that STAF now supports Windows Server 2012 (and Windows 8):

    Index: docs/userguide/Overview.script

    RCS file: /cvsroot/staf/src/staf/docs/userguide/Overview.script,v
    retrieving revision 1.40
    diff -r1.40 Overview.script
    50,55c50,57
    < :li.Windows Server 2003 (i386, AMD64 / x86_64, IA64)
    < :li.Windows Vista (i386, AMD64 / x86_864)
    < :li.Windows Server 2008 (i386, AMD64 / x86_64, IA64)
    < :li.Windows 7 (i386, AMD64 / x86_64)
    < :li.Windows Server 2008 R2 (AMD64 / x86_864, IA64)
    < :li.Linux (i386, AMD64 / x86_64, PPC64)
    ---
    > :li.Windows Server 2003 (i386, x86_64, IA64)
    > :li.Windows Vista (i386, x86_64)
    > :li.Windows Server 2008 (i386, x86_64, IA64)
    > :li.Windows 7 (i386, x86_64)
    > :li.Windows Server 2008 R2 (x86_64, IA64)
    > :li.Windows 8 (i386, x86_64)
    > :li.Windows Server 2012 (x86_64)
    > :li.Linux (i386, x86_64, PPC64)
    Index: docs/faq/STAFFAQ.xml
    ===================================================================
    RCS file: /cvsroot/staf/src/staf/docs/faq/STAFFAQ.xml,v
    retrieving revision 1.84
    diff -r1.84 STAFFAQ.xml
    62c62
    < STAF 3.4.10+ is supported on the following operating systems:
    ---
    > STAF 3.4.11+ is supported on the following operating systems:
    66,71c66,73
    < <listitem>Windows Server 2003 (i386, AMD64 / x86_64, IA64)</listitem>
    < <listitem>Windows Vista (i386, AMD64 / x86_64)</listitem>
    < <listitem>Windows Server 2008 (i386, AMD64 / x86_64, IA64)</listitem>
    < <listitem>Windows 7 (i386, AMD64 / x86_64)</listitem>
    < <listitem>Windows Server 2008 R2 (AMD64 / x86_64, IA64)</listitem>
    < <listitem>Linux (i386, AMD64 / x86_64, PPC64)</listitem>
    ---
    > <listitem>Windows Server 2003 (i386, x86_64, IA64)</listitem>
    > <listitem>Windows Vista (i386, x86_64)</listitem>
    > <listitem>Windows Server 2008 (i386, x86_64, IA64)</listitem>
    > <listitem>Windows 7 (i386, x86_64)</listitem>
    > <listitem>Windows Server 2008 R2 (x86_64, IA64)</listitem>
    > <listitem>Windows 8 (i386, x86_64)</listitem>
    > <listitem>Windows Server 2012 (x86_64)</listitem>
    > <listitem>Linux (i386, x86_64, PPC64)</listitem>

     
  • Sharon Lucas

    Sharon Lucas - 2012-09-24

    Verified that when STAF is built usint InstallAnywhere 2012 FP 4, the STAF IA installer files now work on Windows Server 2012 (and Windows 8).

     
  • Sharon Lucas

    Sharon Lucas - 2012-09-25
    • status: open --> closed-fixed
     
  • Sharon Lucas

    Sharon Lucas - 2012-09-25

    STAF V3.4.11 (to be released at the end of September 2012) provides support for Windows Server 2012.

    The standard STAF installers for Windows x86_64 (aka AMD64) such as STAF3411-setup-winamd64.exe can be used to install STAF on Windows Server 2012 as they have been updated to use InstallAnywhere 2011 FP 4 which supports Windows Server 2012.

     

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks