Skip to content

[native assets] Add dynamic linking integration test for dart #56459

Closed
@dcharkes

Description

@dcharkes

We want to support dylibs being dynamically linked to other dylibs in native assets:

We have a working PR for Flutter:

But it's not working in Dart standalone out of the box either.

Using the same builder hook setup as with Flutter but with standalone Dart, the linked library can never be found. I've tested dart run, dart test and dart build, always with the same result. I'm going to work on dart-lang/native#1419, but I would prefer landing this PR first and coming back later to update the tests.

@dcharkes If you have any idea what differences between embedders could cause loading the linked library to fail with standalone Dart, that would be very helpful for dart-lang/native#1419.

Originally posted by @blaugold in flutter/flutter#153054 (review)

We should add a similar integration test as in the Flutter PR with dylibs being dynamically linked to each other in pkg/dartdev/test/native_assets/build_test.dart and friends. (We could have the integration test project itself live on dart-lang/native instead of checking it in to the Dart SDK like we do with many other tests in pkg/dartdev/test/native_assets/.)

Metadata

Metadata

Assignees

No one assigned

    Labels

    area-dart-cliUse area-dart-cli for issues related to the 'dart' command like tool.area-native-interopUsed for native interop related issues, including FFI.

    Type

    No type

    Projects

    Status

    Done

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions