PowerShell / PowerShell/Win32-OpenSSH
Unable to build on Windows Server 2016
Open
@tgauth is already working on this.
Since Jan 28, 2022.
- Dominant language
- No language data
- Stars
- 8.3k
- Forks
- 819
- PR merge metrics
- No merged PRs in 30d
Description
On Windows Server 2016:
I clone the repo:
git clone https://github.com/PowerShell/openssh-portable.git
I run the build script:
.\openssh-portable\contrib\win32\openssh\OpenSSH-build.ps1
I get the following error (First Bug):
VERBOSE: Start-OpenSSHBuild -NativeHostArch x64 -Configuration Release -NoOpenSSL:False -Onecore:False -Verbose
Checking tools and dependencies
Chocolatey not present. Installing chocolatey.
Start-OpenSSHBuild : Exception calling "DownloadString" with "1" argument(s): "The request was aborted: Could not create SSL/TLS secure channel."
At C:\src\openssh-portable\contrib\win32\openssh\OpenSSH-build.ps1:29 char:5
+ Start-OpenSSHBuild -NativeHostArch $NativeHostArch -Configuration ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (:) [Start-OpenSSHBuild], MethodInvocationException
+ FullyQualifiedErrorId : WebException,Start-OpenSSHBuild
So I tell PowerShell to use TLS 1.2:
[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12
I run the build script again:
.\openssh-portable\contrib\win32\openssh\OpenSSH-build.ps1
It takes a while to start the actual build because it is installing:
- chocolatey
- Windows 10 SDK
Then I get the following errors (Second Bug):
24>c:\src\openssh-portable\config.h(1704): fatal error C1083: Cannot open include file: 'io.h': No such file or directory [C:\src\openssh-portable\contrib\win32\openssh\libssh.vcxproj]
addrmatch.c
ClCompile:
arc4random.c
24>c:\src\openssh-portable\config.h(1704): fatal error C1083: Cannot open include file: 'io.h': No such file or directory [C:\src\openssh-portable\contrib\win32\openssh\libssh.vcxproj]
25>c:\src\openssh-portable\config.h(1704): fatal error C1083: Cannot open include file: 'io.h': No such file or directory [C:\src\openssh-portable\contrib\win32\openssh\openbsd_compat.vcxproj]
base64.c
24>ClCompile:
atomicio.c
24>c:\src\openssh-portable\config.h(1704): fatal error C1083: Cannot open include file: 'io.h': No such file or directory [C:\src\openssh-portable\contrib\win32\openssh\libssh.vcxproj]
Full log here:
Log.txt
Are there some environment variables I'm supposed to set up or another dependency that I'm missing?
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.