From 97f94854a0362836ad86d06132877032b9ffa86a Mon Sep 17 00:00:00 2001 From: Dax Raad Date: Tue, 9 Jun 2026 15:27:58 -0400 Subject: [PATCH] fix(opencode): restore valid fff patch --- patches/@ff-labs%2Ffff-bun@0.9.3.patch | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/patches/@ff-labs%2Ffff-bun@0.9.3.patch b/patches/@ff-labs%2Ffff-bun@0.9.3.patch index e1a9d6d8bf..b60128af9e 100644 --- a/patches/@ff-labs%2Ffff-bun@0.9.3.patch +++ b/patches/@ff-labs%2Ffff-bun@0.9.3.patch @@ -2,10 +2,18 @@ diff --git a/src/download.ts b/src/download.ts index 3454256..6dca25a 100644 --- a/src/download.ts +++ b/src/download.ts -@@ -9,2 +9 @@ +@@ -7,7 +7,6 @@ + */ + import { existsSync } from "node:fs"; -import { createRequire } from "node:module"; -@@ -56,8 +55,8 @@ function resolveFromNpmPackage(): string | null { + import { dirname, join } from "node:path"; + import { fileURLToPath } from "node:url"; + import { getLibFilename, getNpmPackageName } from "./platform"; +@@ -54,14 +53,14 @@ export function binaryExists(): boolean { + * in the same directory. + */ + function resolveFromNpmPackage(): string | null { - const packageName = getNpmPackageName(); - try { @@ -21,3 +29,6 @@ index 3454256..6dca25a 100644 + : getNpmPackageName().endsWith("musl") + ? require(`../../../../../@ff-labs+fff-bin-linux-${process.arch}-musl@0.9.3/node_modules/@ff-labs/fff-bin-linux-${process.arch}-musl/libfff_c.so`) + : require(`../../../../../@ff-labs+fff-bin-linux-${process.arch}-gnu@0.9.3/node_modules/@ff-labs/fff-bin-linux-${process.arch}-gnu/libfff_c.so`); + + if (existsSync(binaryPath)) { + return binaryPath;