Changes between Version 9 and Version 10 of CompilationGuide/WinRT


Ignore:
Timestamp:
May 12, 2015, 12:59:44 AM (4 years ago)
Author:
gillesk
Comment:

Updating instructions for VS 2015 RC and Win10 10074

Legend:

Unmodified
Added
Removed
Modified
  • CompilationGuide/WinRT

    v9 v10  
    1111=== Prerequisites ===
    1212
    13 * For Windows 10: [https://www.visualstudio.com/downloads/visual-studio-2015-ctp-vs Microsoft Visual Studio 2015] & [http://blogs.windows.com/buildingapps/2015/03/23/windows-10-developer-tooling-preview-now-available-to-windows-insiders/ Windows 10 SDK] (tested with Visual Studio 2015 CTP6)
     13* For Windows 10: [https://dev.windows.com/en-us/downloads/windows-10-developer-tools Microsoft Visual Studio 2015] (tested with Visual Studio 2015 RC)
    1414* For Windows 8.1: [http://www.visualstudio.com/downloads/download-visual-studio-vs Microsoft Visual Studio 2013] (use MSVC 2013 Update 3 RTM or newer)
    1515* [http://msys2.github.io/ MSYS2] (GNU Make environment)
     
    2020=== Windows 10 Setup ===
    2121
    22 Download and install [https://www.visualstudio.com/downloads/visual-studio-2015-ctp-vs Microsoft Visual Studio 2015] and [http://blogs.windows.com/buildingapps/2015/03/23/windows-10-developer-tooling-preview-now-available-to-windows-insiders/ Windows 10 SDK] on a Windows 10 machine.
     22Download and install [https://dev.windows.com/en-us/downloads/windows-10-developer-tools Microsoft Visual Studio 2015] on a Windows 10 machine.
    2323
    2424=== Windows 8.1 Setup ===
     
    111111{{{
    112112for /F "tokens=3* delims= " %V in ('reg query "HKLM\SOFTWARE\Microsoft\Microsoft SDKs\Windows\v10.0" /v ProductVersion /reg:32') do set UCRTSdkVer=%V.0
    113 SET LIB=%VSINSTALLDIR%VC\lib\store;%VSINSTALLDIR%VC\atlmfc\lib;%UniversalCRTSdkDir%lib\winv10.0\ucrt\x86;;%UniversalCRTSdkDir%lib\%UCRTSdkVer%\um\x86;C:\Program Files (x86)\Windows Kits\NETFXSDK\4.6\lib\um\x86;;C:\Program Files (x86)\Windows Kits\NETFXSDK\4.6\Lib\um\x86
     113SET LIB=%VSINSTALLDIR%VC\lib\store;%VSINSTALLDIR%VC\atlmfc\lib;%UniversalCRTSdkDir%lib\%UCRTSdkVer%\ucrt\x86;;%UniversalCRTSdkDir%lib\%UCRTSdkVer%\um\x86;C:\Program Files (x86)\Windows Kits\NETFXSDK\4.6\lib\um\x86;;C:\Program Files (x86)\Windows Kits\NETFXSDK\4.6\Lib\um\x86
    114114SET LIBPATH=%VSINSTALLDIR%VC\atlmfc\lib;%VSINSTALLDIR%VC\lib;
    115 SET INCLUDE=%VSINSTALLDIR%VC\include;%VSINSTALLDIR%VC\atlmfc\include;%UniversalCRTSdkDir%Include\ucrt;;%UniversalCRTSdkDir%Include\%UCRTSdkVer%\um;%UniversalCRTSdkDir%Include\%UCRTSdkVer%\shared;%UniversalCRTSdkDir%Include\%UCRTSdkVer%\winrt;C:\Program Files (x86)\Windows Kits\NETFXSDK\4.6\Include\um;
     115SET INCLUDE=%VSINSTALLDIR%VC\include;%VSINSTALLDIR%VC\atlmfc\include;%UniversalCRTSdkDir%Include\%UCRTSdkVer%\ucrt;%UniversalCRTSdkDir%Include\%UCRTSdkVer%\um;%UniversalCRTSdkDir%Include\%UCRTSdkVer%\shared;%UniversalCRTSdkDir%Include\%UCRTSdkVer%\winrt;C:\Program Files (x86)\Windows Kits\NETFXSDK\4.6\Include\um;
    116116}}}
    117117
     
    141141--target-os=win32 \
    142142--extra-cflags="-MD -DWINAPI_FAMILY=WINAPI_FAMILY_APP -D_WIN32_WINNT=0x0A00" \
     143--extra-ldflags="WindowsApp.lib" \
    143144--prefix=../../../Build/Windows10/Win32
    144145
     
    163164{{{
    164165for /F "tokens=3* delims= " %V in ('reg query "HKLM\SOFTWARE\Microsoft\Microsoft SDKs\Windows\v10.0" /v ProductVersion /reg:32') do set UCRTSdkVer=%V.0
    165 SET LIB=%VSINSTALLDIR%VC\lib\store\amd64;%VSINSTALLDIR%VC\atlmfc\lib\amd64;%UniversalCRTSdkDir%lib\winv10.0\ucrt\x64;;%UniversalCRTSdkDir%lib\%UCRTSdkVer%\um\x64;C:\Program Files (x86)\Windows Kits\NETFXSDK\4.6\lib\um\x64;;C:\Program Files (x86)\Windows Kits\NETFXSDK\4.6\Lib\um\x64
     166SET LIB=%VSINSTALLDIR%VC\lib\store\amd64;%VSINSTALLDIR%VC\atlmfc\lib\amd64;%UniversalCRTSdkDir%lib\%UCRTSdkVer%\ucrt\x64;;%UniversalCRTSdkDir%lib\%UCRTSdkVer%\um\x64;C:\Program Files (x86)\Windows Kits\NETFXSDK\4.6\lib\um\x64;;C:\Program Files (x86)\Windows Kits\NETFXSDK\4.6\Lib\um\x64
    166167SET LIBPATH=%VSINSTALLDIR%VC\atlmfc\lib\amd64;%VSINSTALLDIR%VC\lib\amd64;
    167 SET INCLUDE=%VSINSTALLDIR%VC\include;%VSINSTALLDIR%VC\atlmfc\include;%UniversalCRTSdkDir%Include\ucrt;;%UniversalCRTSdkDir%Include\%UCRTSdkVer%\um;%UniversalCRTSdkDir%Include\%UCRTSdkVer%\shared;%UniversalCRTSdkDir%Include\%UCRTSdkVer%\winrt;C:\Program Files (x86)\Windows Kits\NETFXSDK\4.6\Include\um;
     168SET INCLUDE=%VSINSTALLDIR%VC\include;%VSINSTALLDIR%VC\atlmfc\include;%UniversalCRTSdkDir%Include\%UCRTSdkVer%\ucrt;%UniversalCRTSdkDir%Include\%UCRTSdkVer%\um;%UniversalCRTSdkDir%Include\%UCRTSdkVer%\shared;%UniversalCRTSdkDir%Include\%UCRTSdkVer%\winrt;C:\Program Files (x86)\Windows Kits\NETFXSDK\4.6\Include\um;
    168169}}}
    169170
     
    193194--target-os=win32 \
    194195--extra-cflags="-MD -DWINAPI_FAMILY=WINAPI_FAMILY_APP -D_WIN32_WINNT=0x0A00" \
     196--extra-ldflags="WindowsApp.lib" \
    195197--prefix=../../../Build/Windows10/x64
    196198
     
    201203
    202204Generated libraries can be found in `Build/Windows10/x64` folder specified in `--prefix` option above
     205
     206If you encounter an error linking because link.exe complains that MSPDB140.dll has the wrong version installed. Run the following command from an administrative command-prompt and rebuild:
     207{{{
     208copy "C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\bin\mspdbsrv.exe" "C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE"
     209}}}
    203210
    204211----
     
    215222{{{
    216223for /F "tokens=3* delims= " %V in ('reg query "HKLM\SOFTWARE\Microsoft\Microsoft SDKs\Windows\v10.0" /v ProductVersion /reg:32') do set UCRTSdkVer=%V.0
    217 SET LIB=%VSINSTALLDIR%VC\lib\store\ARM;%VSINSTALLDIR%VC\atlmfc\lib\ARM;%UniversalCRTSdkDir%lib\winv10.0\ucrt\arm;;%UniversalCRTSdkDir%lib\%UCRTSdkVer%\um\arm;C:\Program Files (x86)\Windows Kits\NETFXSDK\4.6\lib\um\arm;;C:\Program Files (x86)\Windows Kits\NETFXSDK\4.6\Lib\um\arm
     224SET LIB=%VSINSTALLDIR%VC\lib\store\ARM;%VSINSTALLDIR%VC\atlmfc\lib\ARM;%UniversalCRTSdkDir%lib\%UCRTSdkVer%\ucrt\arm;;%UniversalCRTSdkDir%lib\%UCRTSdkVer%\um\arm;C:\Program Files (x86)\Windows Kits\NETFXSDK\4.6\lib\um\arm;;C:\Program Files (x86)\Windows Kits\NETFXSDK\4.6\Lib\um\arm
    218225SET LIBPATH=%VSINSTALLDIR%VC\atlmfc\lib\ARM;%VSINSTALLDIR%VC\lib\ARM;
    219 SET INCLUDE=%VSINSTALLDIR%VC\include;%VSINSTALLDIR%VC\atlmfc\include;%UniversalCRTSdkDir%Include\ucrt;;%UniversalCRTSdkDir%Include\%UCRTSdkVer%\um;%UniversalCRTSdkDir%Include\%UCRTSdkVer%\shared;%UniversalCRTSdkDir%Include\%UCRTSdkVer%\winrt;C:\Program Files (x86)\Windows Kits\NETFXSDK\4.6\Include\um;
     226SET INCLUDE=%VSINSTALLDIR%VC\include;%VSINSTALLDIR%VC\atlmfc\include;%UniversalCRTSdkDir%Include\%UCRTSdkVer%\ucrt;%UniversalCRTSdkDir%Include\%UCRTSdkVer%\um;%UniversalCRTSdkDir%Include\%UCRTSdkVer%\shared;%UniversalCRTSdkDir%Include\%UCRTSdkVer%\winrt;C:\Program Files (x86)\Windows Kits\NETFXSDK\4.6\Include\um;
    220227}}}
    221228
     
    248255--target-os=win32 \
    249256--extra-cflags="-MD -DWINAPI_FAMILY=WINAPI_FAMILY_APP -D_WIN32_WINNT=0x0A00 -D__ARM_PCS_VFP" \
     257--extra-ldflags="WindowsApp.lib" \
    250258--prefix=../../../Build/Windows10/ARM
    251259
     
    257265Generated libraries can be found in `Build/Windows10/ARM` folder specified in `--prefix` option above
    258266
    259 There is currently a bug on Visual Studio 2015 CTP 6 ARM compiler that prevent the mjpeg source code to be compiled. As a workaround, disable mjpeg by adding the following options to configure command above.
     267There is currently an issue on Visual Studio 2015 RC ARM compiler that prevent the mjpeg source code to be compiled. As a workaround, disable mjpeg by adding the following options to configure command above.
    260268{{{
    261269--disable-decoder=avrn \
     
    263271--disable-encoder=mjpeg \
    264272}}}
     273
     274If you encounter an error linking because link.exe complains that MSPDB140.dll has the wrong version installed. Run the following command from an administrative command-prompt and rebuild:
     275{{{
     276copy "C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\bin\mspdbsrv.exe" "C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE"
     277}}}
     278
    265279
    266280----