Skip to content

About

Dart script to build curl for Android, iOS and macOS

Topics

Resources

Stars

10 stars

Watchers

1 watching

Forks

Repository files navigation

Dart script to build curl for iOS and Android

Builds curl native lib in following config:

  • TLS with BoringSSL (built by quiche)
  • HTTP3 with quiche
  • HTTP2 with nghttp2
  • Brotli
  • c-ares DNS resolver (macOS only)
  • Android lib as AAR (arm64-v8a, armeabi-v7a, x86_64)
  • iOS lib as an xcframework holding a dynamic Curl.framework (arm64 iphoneos, arm64 iphonesimulator, x86_64 iphonesimulator)
  • macOS lib as an xcframework holding a dynamic Curl.framework (arm64 Apple Silicon, x86_64 Intel)

Binaries are available to download in the releases.

Setup

Tested on a Mac with M5 Max, macOS 27.0.1, Xcode 27.1

Requirements:

  • dart
  • Xcode
  • Android NDK 30.0.16248370 in ~/Library/Android/sdk/ndk/ (version set in env.dart)
  • git
  • autoconf
  • automake
  • libtool
  • cmake
  • pkg-config
  • go
  • rust
  • cargo-ndk

Rust targets:

  • aarch64-linux-android
  • armv7-linux-androideabi
  • x86_64-linux-android
  • aarch64-apple-ios
  • aarch64-apple-ios-sim
  • x86_64-apple-ios
  • x86_64-apple-darwin
  • aarch64-apple-darwin

Running script

$ dart main.dart clean cloneRepos patchQuiche patchCurl setupDirs

# clones git repos, applies patches

$ dart main.dart alliOS

# output in build/ios/Curl.xcframework

$ dart main.dart allmacOS

# output in build/macos/Curl.xcframework

$ dart main.dart allAndroid

# output in build/android/Curl.aar

References

About

Dart script to build curl for Android, iOS and macOS

Topics

Resources

Stars

10 stars

Watchers

1 watching

Forks

Releases

Contributors

Languages