Skip to content

Commit c3c4343

Browse files
committed
bun: Add pre_install check for CPU
1 parent 6149a81 commit c3c4343

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

bucket/bun.json

+6
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,12 @@
1212
"hash": "60e9291d09657ab315bcc6bc07cbf67d2e9b9b18c21bb7cf9ce2d9fa983c9719"
1313
}
1414
},
15+
"pre_install": [
16+
"if (-not (Add-Type -MemberDefinition '[DllImport(\"kernel32.dll\")] public static extern bool IsProcessorFeaturePresent(int ProcessorFeature);'-Name 'Kernel32'-Namespace 'Win32'-PassThru)::IsProcessorFeaturePresent(40)) {",
17+
" Write-Host -Foreground Red \"This CPU does not support AVX2 instructions. please install 'bun-baseline' instead.\"",
18+
" break",
19+
"}"
20+
],
1521
"extract_dir": "bun-windows-x64",
1622
"bin": [
1723
"bun.exe",

0 commit comments

Comments
 (0)