Files
bun.sh/scripts/build-libarchive.ps1
dave caruso 093e9c2499 ci: does this fix the windows build (#9715)
* does this fix the windows build

* [autofix.ci] apply automated fixes

* a

* enable tar oop

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2024-03-29 15:20:13 -07:00

17 lines
661 B
PowerShell

$ErrorActionPreference = 'Stop' # Setting strict mode, similar to 'set -euo pipefail' in bash
. (Join-Path $PSScriptRoot "env.ps1")
Push-Location (Join-Path $BUN_DEPS_DIR 'libarchive')
try {
Set-Location (mkdir -Force build)
Run cmake @CMAKE_FLAGS -DBUILD_SHARED_LIBS=OFF -DENABLE_TEST=OFF -DENABLE_INSTALL=OFF -DENABLE_WERROR=0 -DENABLE_ICONV=0 -DENABLE_LibGCC=0 -DENABLE_LZMA=0 -DENABLE_LZ4=0 -DENABLE_LIBXML2=0 -DENABLE_LIBB2=0 -DENABLE_OPENSSL=0 -DENABLE_CAT=0 ..
Run cmake --build . --clean-first --config Release
Copy-Item libarchive\archive_static.lib $BUN_DEPS_OUT_DIR\archive.lib
Write-Host "-> archive.lib"
}
finally {
Pop-Location
}