Skip to content

Update FFI expected files for improved pointer type resolution #64

Update FFI expected files for improved pointer type resolution

Update FFI expected files for improved pointer type resolution #64

Workflow file for this run

name: Tests
on:
push:
branches: [main]
pull_request:
branches: [main]
workflow_dispatch:
jobs:
test:
name: ${{matrix.ruby}} on ${{matrix.os}}
runs-on: ${{matrix.os}}
strategy:
fail-fast: false
matrix:
include:
# Ubuntu - full Ruby matrix
- { os: ubuntu-latest, ruby: "3.2" }
- { os: ubuntu-latest, ruby: "3.3" }
- { os: ubuntu-latest, ruby: "3.4" }
- { os: ubuntu-latest, ruby: "4.0" }
# macOS
- { os: macos-latest, ruby: "4.0" }
# Windows MinGW
- { os: windows-latest, ruby: "4.0" }
# Windows MSVC
- { os: windows-latest, ruby: "mswin" }
steps:
- uses: actions/checkout@v6
- name: Set up Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: ${{matrix.ruby}}
bundler-cache: true
mingw: clang llvm
- name: Install LLVM and Clang (Ubuntu)
if: runner.os == 'Linux'
run: sudo apt-get update && sudo apt-get install -y llvm libclang-dev
- name: Install LLVM and Clang (macOS)
if: runner.os == 'macOS'
run: brew install llvm
- name: Install LLVM and Clang (Windows MinGW)
if: runner.os == 'Windows' && matrix.ruby != 'mswin'
run: pacman -S --noconfirm mingw-w64-ucrt-x86_64-clang mingw-w64-ucrt-x86_64-llvm
- name: Debug LLVM paths (Windows MSVC)
if: matrix.ruby == 'mswin'
shell: pwsh
run: |
Write-Host "=== vswhere output ==="
& "C:\Program Files (x86)\Microsoft Visual Studio\Installer\vswhere.exe" -latest -products * -prerelease -requires Microsoft.VisualStudio.Component.VC.Llvm.Clang -property installationPath
Write-Host ""
Write-Host "=== VS LLVM directories ==="
$vsPath = & "C:\Program Files (x86)\Microsoft Visual Studio\Installer\vswhere.exe" -latest -products * -prerelease -requires Microsoft.VisualStudio.Component.VC.Llvm.Clang -property installationPath
if ($vsPath) {
$llvmDir = Join-Path $vsPath "VC\Tools\Llvm\x64\bin"
Write-Host "Looking in: $llvmDir"
if (Test-Path $llvmDir) { Get-ChildItem $llvmDir -Filter "libclang*" } else { Write-Host "Directory not found" }
}
Write-Host ""
Write-Host "=== Standalone LLVM ==="
where.exe llvm-config 2>$null
where.exe clang 2>$null
if (Test-Path "C:\Program Files\LLVM\bin") { Get-ChildItem "C:\Program Files\LLVM\bin" -Filter "libclang*" }
Write-Host ""
Write-Host "=== PATH ==="
$env:PATH -split ";" | Where-Object { $_ -match "llvm|clang" -or $_ -match "LLVM" }
- name: Run tests
timeout-minutes: 10
run: bundle exec rake test