From 51ef66174a5cb3093d3e043c8aad73146aaeeed4 Mon Sep 17 00:00:00 2001 From: Henry-Hiles Date: Thu, 10 Sep 2026 15:15:12 -0400 Subject: [PATCH] fix generate script to work with new ffigen --- scripts/generate.dart | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/scripts/generate.dart b/scripts/generate.dart index 4dc7329..7109929 100644 --- a/scripts/generate.dart +++ b/scripts/generate.dart @@ -1,4 +1,5 @@ import "dart:io"; + import "package:ffigen/ffigen.dart"; import "package:path/path.dart"; import "package:nexus/helpers/extensions/get_xcode_sdk.dart"; @@ -11,16 +12,17 @@ void main(List args) async { final libclangPath = Platform.environment["LIBCLANG_PATH"]; FfiGenerator( output: Output( - dartFile: Platform.script.resolve("../lib/src/third_party/gomuks.g.dart"), + dart: .new( + path: Platform.script.resolve("../lib/src/third_party/gomuks.g.dart"), + ), ), - headers: Headers( + input: .new( entryPoints: [File(join(repoDir.path, "pkg", "ffi", "gomuksffi.h")).uri], compilerOptions: [ "--no-warnings", if (Platform.isMacOS) "-I${await getXCodeTool()}/usr/include", ], ), - functions: Functions.includeAll, ).generate( libclangDylib: libclangPath == null ? null