diff options
Diffstat (limited to 'windows')
| -rw-r--r-- | windows/build.ps1 | 26 | ||||
| -rw-r--r-- | windows/const.ps1 | 9 | ||||
| -rw-r--r-- | windows/release.ps1 | 8 |
3 files changed, 24 insertions, 19 deletions
diff --git a/windows/build.ps1 b/windows/build.ps1 index abc139e2109c..a26ae1bfd6e8 100644 --- a/windows/build.ps1 +++ b/windows/build.ps1 @@ -74,11 +74,9 @@ if (-Not (Test-Path $GPG)) { throw "Unable to find GPG at $GPG" } -# Override CMAKE_SYSTEM_VERSION if $WinSDK is set. -if (-Not ([string]::IsNullOrEmpty($WinSDK))) { - $CMAKE_SYSTEM_VERSION = "-DCMAKE_SYSTEM_VERSION='$WinSDK'" -} else { - $CMAKE_SYSTEM_VERSION = '' +# 10.0.261000.0 appear to have dropped ARM32 support, pin the SDK version +if ($Arch -eq "ARM" -and [string]::IsNullOrEmpty($WinSDK)) { + $WinSDK = '10.0.22621.0' } Write-Host "WinSDK: $WinSDK" @@ -110,6 +108,11 @@ New-Item -Type Directory "${OUTPUT}" -Force New-Item -Type Directory "${OUTPUT}\${Arch}" -Force New-Item -Type Directory "${OUTPUT}\${Arch}\${Type}" -force +# Override Windows SDK version if $WinSDK is set. +if (-Not ([string]::IsNullOrEmpty($WinSDK))) { + $Arch = "$Arch,version=$WinSDK" +} + # Fetch and verify dependencies. Push-Location ${BUILD} try { @@ -155,7 +158,7 @@ try { -DLIBRESSL_APPS=OFF -DCMAKE_C_FLAGS_DEBUG="${CFLAGS_DEBUG}" ` -DCMAKE_C_FLAGS_RELEASE="${CFLAGS_RELEASE}" ` -DCMAKE_MSVC_RUNTIME_LIBRARY="${CMAKE_MSVC_RUNTIME_LIBRARY}" ` - -DCMAKE_INSTALL_PREFIX="${PREFIX}" "${CMAKE_SYSTEM_VERSION}"; ` + -DCMAKE_INSTALL_PREFIX="${PREFIX}"; ` ExitOnError & $CMake --build . --config ${Config} --verbose; ExitOnError & $CMake --build . --config ${Config} --target install --verbose; ` @@ -174,7 +177,7 @@ try { -DBUILD_SHARED_LIBS="${SHARED}" ` -DCMAKE_C_FLAGS_DEBUG="${CFLAGS_DEBUG} /wd4703" ` -DCMAKE_C_FLAGS_RELEASE="${CFLAGS_RELEASE} /wd4703" ` - -DCMAKE_INSTALL_PREFIX="${PREFIX}" "${CMAKE_SYSTEM_VERSION}"; ` + -DCMAKE_INSTALL_PREFIX="${PREFIX}"; ` ExitOnError & $CMake --build . --config ${Config} --verbose; ExitOnError & $CMake --build . --config ${Config} --target install --verbose; ` @@ -193,7 +196,7 @@ try { -DCMAKE_C_FLAGS_DEBUG="${CFLAGS_DEBUG}" ` -DCMAKE_C_FLAGS_RELEASE="${CFLAGS_RELEASE}" ` -DCMAKE_MSVC_RUNTIME_LIBRARY="${CMAKE_MSVC_RUNTIME_LIBRARY}" ` - -DCMAKE_INSTALL_PREFIX="${PREFIX}" "${CMAKE_SYSTEM_VERSION}"; ` + -DCMAKE_INSTALL_PREFIX="${PREFIX}"; ` ExitOnError & $CMake --build . --config ${Config} --verbose; ExitOnError & $CMake --build . --config ${Config} --target install --verbose; ` @@ -229,10 +232,11 @@ try { -DCRYPTO_INCLUDE_DIRS="${PREFIX}\include" ` -DCRYPTO_LIBRARY_DIRS="${PREFIX}\lib" ` -DCRYPTO_BIN_DIRS="${PREFIX}\bin" ` - -DCRYPTO_LIBRARIES="${CRYPTO_LIBRARIES}" ` + -DCRYPTO_LIBRARIES="${CRYPTO_LIB}" ` + -DCRYPTO_DLL="${CRYPTO_DLL}" ` -DCMAKE_C_FLAGS_DEBUG="${CFLAGS_DEBUG} ${Fido2Flags}" ` -DCMAKE_C_FLAGS_RELEASE="${CFLAGS_RELEASE} ${Fido2Flags}" ` - -DCMAKE_INSTALL_PREFIX="${PREFIX}" "${CMAKE_SYSTEM_VERSION}"; ` + -DCMAKE_INSTALL_PREFIX="${PREFIX}"; ` ExitOnError & $CMake --build . --config ${Config} --verbose; ExitOnError & $CMake --build . --config ${Config} --target regress --verbose; ` @@ -241,7 +245,7 @@ try { ExitOnError # Copy DLLs. if ("${SHARED}" -eq "ON") { - "cbor.dll", "${CRYPTO_LIBRARIES}.dll", "zlib1.dll" | ` + "cbor.dll", "${CRYPTO_DLL}.dll", "zlib1.dll" | ` %{ Copy-Item "${PREFIX}\bin\$_" ` -Destination "examples\${Config}" } } diff --git a/windows/const.ps1 b/windows/const.ps1 index 7a39b015c7a0..787fe5badf20 100644 --- a/windows/const.ps1 +++ b/windows/const.ps1 @@ -7,12 +7,13 @@ New-Variable -Name 'LIBRESSL_URL' ` -Value 'https://ftp.openbsd.org/pub/OpenBSD/LibreSSL' ` -Option Constant -New-Variable -Name 'LIBRESSL' -Value 'libressl-3.9.2' -Option Constant -New-Variable -Name 'CRYPTO_LIBRARIES' -Value 'crypto' -Option Constant +New-Variable -Name 'LIBRESSL' -Value 'libressl-4.0.0' -Option Constant +New-Variable -Name 'CRYPTO_LIB' -Value 'crypto' -Option Constant +New-Variable -Name 'CRYPTO_DLL' -Value 'crypto-55' -Option Constant # libcbor coordinates. -New-Variable -Name 'LIBCBOR' -Value 'libcbor-0.11.0' -Option Constant -New-Variable -Name 'LIBCBOR_BRANCH' -Value 'v0.11.0' -Option Constant +New-Variable -Name 'LIBCBOR' -Value 'libcbor-0.12.0' -Option Constant +New-Variable -Name 'LIBCBOR_BRANCH' -Value 'v0.12.0' -Option Constant New-Variable -Name 'LIBCBOR_GIT' -Value 'https://github.com/pjk/libcbor' ` -Option Constant diff --git a/windows/release.ps1 b/windows/release.ps1 index 6989a5c34a9b..07bc2d45a964 100644 --- a/windows/release.ps1 +++ b/windows/release.ps1 @@ -35,8 +35,8 @@ Function Package-Dynamic(${SRC}, ${DEST}) { Copy-Item "${SRC}\lib\cbor.lib" "${DEST}" Copy-Item "${SRC}\bin\zlib1.dll" "${DEST}" Copy-Item "${SRC}\lib\zlib1.lib" "${DEST}" - Copy-Item "${SRC}\bin\${CRYPTO_LIBRARIES}.dll" "${DEST}" - Copy-Item "${SRC}\lib\${CRYPTO_LIBRARIES}.lib" "${DEST}" + Copy-Item "${SRC}\bin\${CRYPTO_DLL}.dll" "${DEST}" + Copy-Item "${SRC}\lib\${CRYPTO_LIB}.lib" "${DEST}" Copy-Item "${SRC}\bin\fido2.dll" "${DEST}" Copy-Item "${SRC}\lib\fido2.lib" "${DEST}" } @@ -44,13 +44,13 @@ Function Package-Dynamic(${SRC}, ${DEST}) { Function Package-Static(${SRC}, ${DEST}) { Copy-Item "${SRC}/lib/cbor.lib" "${DEST}" Copy-Item "${SRC}/lib/zlib1.lib" "${DEST}" - Copy-Item "${SRC}/lib/${CRYPTO_LIBRARIES}.lib" "${DEST}" + Copy-Item "${SRC}/lib/${CRYPTO_LIB}.lib" "${DEST}" Copy-Item "${SRC}/lib/fido2_static.lib" "${DEST}/fido2.lib" } Function Package-PDBs(${SRC}, ${DEST}) { Copy-Item "${SRC}\${LIBRESSL}\crypto\crypto_obj.dir\${Config}\crypto_obj.pdb" ` - "${DEST}\${CRYPTO_LIBRARIES}.pdb" + "${DEST}\${CRYPTO_LIB}.pdb" Copy-Item "${SRC}\${LIBCBOR}\src\cbor.dir\${Config}\vc${SDK}.pdb" ` "${DEST}\cbor.pdb" Copy-Item "${SRC}\${ZLIB}\zlib.dir\${Config}\vc${SDK}.pdb" ` |
