dart-sdk/samples/ffi/http
Jake Macdonald 1405695675 Add sample directories to the package config.
This allows the package imports in the tests to resolve.

Change-Id: Idadca8b55516a5b5d1511ebc38c298479aa8eda0
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/333662
Commit-Queue: Nate Bosch <nbosch@google.com>
Auto-Submit: Jake Macdonald <jakemac@google.com>
Reviewed-by: Nate Bosch <nbosch@google.com>
2023-11-02 21:00:41 +00:00
..
lib [ffi] Reland the iNativeCallable.listener example test. 2023-09-28 22:41:42 +00:00
test Add sample directories to the package config. 2023-11-02 21:00:41 +00:00
.gitignore [ffi] Reland the iNativeCallable.listener example test. 2023-09-28 22:41:42 +00:00
BUILD.gn [build] Fix Windows linker warning about unrecognized flag. 2023-10-26 19:23:20 +00:00
pubspec.yaml Add sample directories to the package config. 2023-11-02 21:00:41 +00:00
README.md [ffi] Reland the iNativeCallable.listener example test. 2023-09-28 22:41:42 +00:00

This is an example that shows how to use NativeCallable.listener to interact with a multi threaded native API.

The native API is a fake HTTP library with some hard coded requests and responses. To build the dynamic library, run this command:

c++ -shared -fpic lib/fake_http.cc -lstdc++ -o lib/libfake_http.so

On Windows the output library should be lib/fake_http.dll and on Mac it should be lib/libfake_http.dylib.