blob: 4dd9eb9727627750f7365ab6a59f8a07dedb2266 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
|
$originalLocation = Get-Location
Set-Location (Split-Path -Parent (Split-Path -Parent $MyInvocation.MyCommand.Path))
if (-not (Get-Command cbindgen -ErrorAction SilentlyContinue)) {
cargo install cbindgen
}
if (Test-Path ffi/.temp/jvlib.h) {
Remove-Item ffi/.temp/jvlib.h
}
$env:RUSTUP_TOOLCHAIN = "nightly"
cbindgen `
--config cbindgen.toml `
ffi `
--output ffi/.temp/jvlib.h `
--quiet
Set-Location $originalLocation
|