-
-
Notifications
You must be signed in to change notification settings - Fork 626
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Compile NVDA with the Windows 10 SDK #7568
Conversation
…Helper macros, and remove a pre-vista TSF check.
Hi, When I try to compile this from source, Command prompt and powerShell says MIDL.EXE is not a recognized command or an operable program. Thanks. |
It compiled fine on my machine, and on appveyor.
It will require Visual Studio 2015 community as usual. Also In the VS
2015 community installer, check that you have The latest Windows 10 SDK
and tools. Specifically:
- Programming Languages:
-- Visual C++
-- * Common Tools for Visual C++ 2015
- Windows and web development:
-- Universal Windows App Development Tools:
-- * Tools (1.4.1) and Windows 10 SDK (10.0.14393)
You may also want to clean your git working directory as well.
Once Scons 3.0 is released we'll move to Visual Studio 2017 as well.
|
Yep. Note to others: do NOT (ever) uninstall whatever SDK that comes with Visual studio Community, otherwise build failures may result. Thanks. |
@feerrenrut: another review please. This now also upgrades to SCons 3.0 official and switches to Visual Studio 2017 for compilation. This completes the switch to more modern tools. |
@michaelDCurran: Could you please review the sconscript for nvdahelper/localWin10 There is now some obsolete stuff in there which can be removed. |
I also have the following error
|
Hi, also, this means I can safely merge #7520 into this PR to be done by Mick, so no need for me to even submit my own branch. Thanks.
From: Leonard de Ruijter [mailto:notifications@github.com]
Sent: Monday, September 18, 2017 11:13 PM
To: nvaccess/nvda <nvda@noreply.github.com>
Cc: Joseph Lee <joseph.lee22590@gmail.com>; Comment <comment@noreply.github.com>
Subject: Re: [nvaccess/nvda] Compile NVDA with the Windows 10 SDK (#7568)
@michaelDCurran <https://github.com/michaeldcurran> : Could you please review the sconscript for nvdahelper/localWin10 There is now some obsolete stuff in there which can be removed.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub <#7568 (comment)> , or mute the thread <https://github.com/notifications/unsubscribe-auth/AHgLkAE0Vv2GxWZOE1hMlfSF2L5vb0bCks5sj1uBgaJpZM4PMdXL> .
|
…t and /I to MIDLFLAGS as this was dropping /x64 which is needed for compiling when 64 bit.
…e can compile nvdaHelperLocalWin10 using the same infrastructure as nvdaHelperRemote and nvdaHelperLocal etc, except that rather than /mt, /ZW should be used. This removes a great deal of code from the nvdaHelperLocalWin10 sconscript. # Please enter the commit message for your changes. Lines starting
I've now reordered things so that the localWin10 sconscript no longer
needs to copy much of archBuild_sconscript.
|
Found and fixed this error as well.
I'm surprised this used to work pre Win10 sdk.
|
It looks like SCons now has officially moved to github. Would it be possible to use the official repo as a submodule? |
Err... this didn't exist when I looked a few weeks ago. Must have just
happened?
But certainly, if it is official, then yes I'll switch it.
|
@michaelDCurran commented on 4 okt. 2017 09:37 CEST:
It is now mentioned on the website as their primary development platform. |
…erting the user to the fact they may need to run git submodule update --init
Actually, this was too early. Give it another week. master now reset to before this pr. I read the date wrong ;) |
Hmm, Github still thinks this is merged. |
Yep. Doesn't seem there is any way to fix that.
Can't reopen the pr either.
Even though I reset master to the commit before.
|
|
||
# UWP dlls can only be dynamically linked with the CRT, | ||
# but some systems might not have this version of the CRT. | ||
# Therefore, we must include it. | ||
vcRedist = os.path.join(progFilesX86, r"Microsoft Visual Studio 14.0\VC\redist\onecore\x86\Microsoft.VC140.CRT") | ||
vcRedist = os.path.join(progFilesX86, r"Microsoft Visual Studio\2017\Community\VC\Redist\MSVC\14.11.25415\onecore\x86\Microsoft.VC141.CRT") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Would it be possible to get rid of the 14.11.25415 part here by using glob and only use the most recent version available? One problem I see with the current approach is that Appveyor silently updates its Visual Studio 2017 image to a newer build of VS, which might bundle a newer version of the redistributable. Strange enough, when I updated to Visual Studio 2017.4, i lost 14.11.25415 and have now 14.11.25325.
* Switch to using SCons 3.0 from a git mirror we manage. * Compile NVDA with the Windows 10 SDK, replace GetVersion with versionHelper macros, and remove a pre-vista TSF check. * Instruct appveyor to use its Visual Studio 2017 image * Update readme to mention Visual Studio 2017 * iSimpleDOMNode_sconscript: don't lose existing flags when adding c_ext and /I to MIDLFLAGS as this was dropping /x64 which is needed for compiling when 64 bit. * nvdaHelper sconscripts: now we are always using the Windows 10 SDK, we can compile nvdaHelperLocalWin10 using the same infrastructure as nvdaHelperRemote and nvdaHelperLocal etc, except that rather than /mt, /ZW should be used. This removes a great deal of code from the nvdaHelperLocalWin10 sconscript. * Readme.md: update VS 2017 section with extra needed dependency * Clarify error message when VC++ 14.1 is missing. * Ensure that all Python directories exist, eitherwise raise an error alerting the user to the fact they may need to run git submodule update --init * nvdaHelperLocalWin10 sconscript: search versioned directories from newest to oldest to find the vc restributables.
I was able to reproduce this once upgrading VS 2017. I fixed this before
it was merged to master.
|
is it ok to build with vs2019 professional on windows 10 os? |
Summary of the issue:
Currently NVDA is specifically compiled with Windows SDK 7.1A which was the last windows SDK version to support XP. Newer versions of Visual Studio have contained a special re-packaged Windows SDK 7.1a for this purpose. However, this SDK may lack particular features (E.g. static analysis) or optimizations, and will not take advantage of APIs only available on newer Operating Systems.
Description of how this pull request fixes the issue:
This PR upgrades to SCons 3.0, which now detects and uses Visual Studio 2017. Our sconscripts specifically check for VS 2017 and will no longer run on anything lower.
This PR also removes the use of Windows SDK 7.1a, thereby falling back to the latest SDK available on the system; This will be the latest Windows 10 SDK.
This PR also changes the _WIN32_WINNT define to be WIN7 (rather than XP), which allows the use of features available on at most Windows 7. The linker now also no longer receives /subsystem or /machine arguments, which now means binaries will default to being suitable for Windows 7 at a minimum, and CPU features such as SSE2 will be used.
There were some calls to GetVersion which is now deprecated. These were either removed (as they were only checking for Vista anyway), or changed to the now recommended versionHelper macros.
Testing performed:
Known issues with pull request:
None
Change log entry:
No user visible change.
Changes for Developers: