native
native copied to clipboard
Dart packages related to FFI and native assets bundling.
For example: ```dart extension NSURLRequest$Methods on NSURLRequest { NSURLRequestCachePolicy get cachePolicy { ... extension type NSMutableURLRequest._(objc.ObjCObject object$) implements objc.ObjCObject, NSURLRequest { set cachePolicy$1(NSURLRequestCachePolicy value) { ``` This means that, for...
This PR turns the Arena parameter in the using computation function into a named parameter. While working with the using-pattern, I wished for this tiny quality of life improvement. I...
User defines are typically used to control how a hook compiles native code. Sometimes, one might want to use different options depending on the target operating system or architecture. So...
```shell Exception in Java code called through JNI: java.lang.NoClassDefFoundError: com/github/dart_lang/jni/PortProxyBuilder ``` will error if not included , when calling a .implement function through implementIn() . even when jni:setup and Jni.spawn()...
If I run the following generation script: ```dart FfiGenerator( [...] objectiveC: ObjectiveC( interfaces: Interfaces( includeMember: (Declaration declaration, String member) { final String interfaceName = declaration.originalName; final String signature = member;...
It only has an effect on codegen for functions and globals, and it doesn't really make sense for interfaces/protocols/categories. For interfaces and protocols we could expose the native class/protocol pointer,...
Running ffigen results in a *lot* of logging about things it is skipping. For instance, I'm doing the following: ```dart FfiGenerator( [...] headers: Headers( entryPoints: [ Uri.file('$macSdkPath/System/Library/Frameworks/AVFAudio.framework/Headers/AVAudioPlayer.h'), ], ), objectiveC:...
@marshelino-maged @HosseinYousefi and I were discussing ingesting JNIgen and FFIgen generated code into a vector database in the context of https://github.com/dart-lang/native/tree/main/pkgs/native_doc_dartifier. Java and Kotlin have a natural structure in their...
``` // ignore_for_file: avoid_print import 'dart:io'; import 'package:ffigen/ffigen.dart'; import 'package:logging/logging.dart'; void main() { final iosSdkPath = '/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks'; final generator = FfiGenerator( headers: Headers( entryPoints: [ // UIKit and PDFKit from...
We have a visitor that tries to decide which imports are needed. Ideally there would be no false positive imports, but that's very hard to guarantee after https://github.com/dart-lang/native/pull/2525.