aboutsummaryrefslogtreecommitdiff
path: root/scripts/generate_libghostty_bindings.sh
blob: 0868b73e31071b3432f09c576f010492138d7d82 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
#!/usr/bin/env bash
set -euo pipefail
cd "$(dirname "$0")/.."

# Additional clang arguments can supply a resource directory on minimal hosts.
"${BINDGEN:-bindgen}" vendor/libghostty-vt/include/ghostty/vt.h \
  --allowlist-type 'Ghostty.*' \
  --allowlist-function 'ghostty_.*' \
  --allowlist-var 'GHOSTTY_.*' \
  --with-derive-default \
  --output crates/ghostty-vt/src/bindings.rs \
  -- -Ivendor/libghostty-vt/include "$@"