All Projects → BrainiumLLC → Cargo Mobile

BrainiumLLC / Cargo Mobile

Licence: other
Rust on mobile made easy!

Programming Languages

rust
11053 projects

Projects that are alternatives of or similar to Cargo Mobile

Android Kubernetes Blockchain
WARNING: This repository is no longer maintained ⚠️ This repository will not be updated. The repository will be kept available in read-only mode. Refer to https://developer.ibm.com/patterns/category/blockchain/ for other blockchain code patterns.
Stars: ✭ 105 (-70.99%)
Mutual labels:  android-studio, mobile
Xtream Iptv Player Reactnative
Stars: ✭ 30 (-91.71%)
Mutual labels:  xcode, android-studio
Flutter Architecture Blueprints
Flutter Architecture Blueprints is a project that introduces MVVM architecture and project structure approaches to developing Flutter apps.
Stars: ✭ 707 (+95.3%)
Mutual labels:  xcode, android-studio
Stompclientlib
Simple STOMP Client library, Swift 3 and 4, 4.2, 5 compatible
Stars: ✭ 99 (-72.65%)
Mutual labels:  xcode, mobile
Streetmusicmap
StreetMusicMap is a collab line up of street music performers from all over the world.
Stars: ✭ 13 (-96.41%)
Mutual labels:  xcode, mobile
Figma Export
Command line utility to export colors, typography, icons and images from Figma to Xcode / Android Studio project
Stars: ✭ 235 (-35.08%)
Mutual labels:  xcode, android-studio
Intellij Rainbow Brackets
🌈Rainbow Brackets for IntelliJ based IDEs/Android Studio/HUAWEI DevEco Studio
Stars: ✭ 3,663 (+911.88%)
Mutual labels:  android-studio
Objection
📱 objection - runtime mobile exploration
Stars: ✭ 4,404 (+1116.57%)
Mutual labels:  mobile
React Native Redux Crypto Tracker
💎 Learn how to build a Redux + React Native cryptocurrency app
Stars: ✭ 351 (-3.04%)
Mutual labels:  mobile
Easyswiftlayout
Lightweight Swift framework for Apple's Auto-Layout
Stars: ✭ 345 (-4.7%)
Mutual labels:  xcode
Tulsi
An Xcode Project Generator For Bazel
Stars: ✭ 365 (+0.83%)
Mutual labels:  xcode
Xcode Wakatime
Xcode plugin for automatic time tracking and metrics generated from your programming activity.
Stars: ✭ 360 (-0.55%)
Mutual labels:  xcode
Awesome Android Ui
😎 A curated list of awesome Android UI/UX libraries
Stars: ✭ 353 (-2.49%)
Mutual labels:  android-studio
Luaviewsdk
A cross-platform framework to build native, dynamic and swift user interface - 强大轻巧灵活的客户端动态化解决方案
Stars: ✭ 3,586 (+890.61%)
Mutual labels:  mobile
Ci helloworld
A simple example of how to setup a complete CI environment for C and C++
Stars: ✭ 357 (-1.38%)
Mutual labels:  xcode
Apple Juice
An advanced battery gauge for macOS, that displays the remaining battery time and more.
Stars: ✭ 350 (-3.31%)
Mutual labels:  xcode
Flutter Settings Ui
Create native settings for Flutter app in a minutes.
Stars: ✭ 363 (+0.28%)
Mutual labels:  mobile
Gmscore
Free implementation of Play Services
Stars: ✭ 4,356 (+1103.31%)
Mutual labels:  mobile
Cht Core
The CHT Core Framework makes it faster to build responsive, offline-first digital health apps that equip health workers to provide better care in their communities. It is a central resource of the Community Health Toolkit.
Stars: ✭ 354 (-2.21%)
Mutual labels:  mobile
Solarized Dark For Xcode
Solarized Dark Theme for Xcode. Compatible with all modern versions of Xcode since 2013!
Stars: ✭ 358 (-1.1%)
Mutual labels:  xcode

cargo-mobile

The answer to "how do I use Rust on iOS and Android?"

cargo-mobile takes care of generating Xcode and Android Studio project files, building and running on device, generating project boilerplate, and a few other things!

Check out the announcement post!

Status

Everything here works and is already used internally! However, this hasn't seen a lot of external use yet, so there could still be some rough edges.

Building for iOS is broken on Rust 1.46.0, 1.47.0, and 1.48.0!

Sorry for the inconvenience! This is resolved in Rust 1.49.0, so please update to that if you haven't already:

rustup update stable
rustup default stable

Installation

The build will probably take a bit, so feel free to go get a snack or something.

cargo install --git https://github.com/BrainiumLLC/cargo-mobile

cargo-mobile is currently supported on macOS and Linux. Note that it's not possible to target iOS on platforms other than macOS! You'll still get to target Android either way.

A PR adding Windows support would be hugely appreciated!

You'll need to have Xcode and the Android SDK/NDK installed. Some of this will ideally be automated in the future, or at least we'll provide a helpful guide and diagnostics.

Whenever you want to update:

cargo mobile update

Usage

To start a new project, all you need to do is make a directory with a cute name, cd into it, and then run this command:

cargo mobile init

After some straightforward prompts, you'll be asked to select a template pack. Template packs are used to generate project boilerplate, i.e. using the bevy template pack gives you a minimal Bevy project that runs out-of-the-box on desktop and mobile.

name info
bevy Minimal Bevy project derived from sprite example
bevy-demo Bevy breakout demo
wgpu Minimal wgpu project derived from hello-triangle example
winit Minimal winit project derived from window example

Template pack contribution is encouraged; we'd love to have very nice template packs for Bevy, Amethyst, and whatever else people find helpful! We'll write up a guide for template pack creation soon, but in the mean time, the existing ones are a great reference point. Any template pack placed into ~./cargo-mobile/templates/apps/ will appear as an option in cargo mobile init.

Once you've generated your project, you can run cargo run as usual to run your app on desktop. However, now you can also do cargo apple run and cargo android run to run on connected iOS and Android devices respectively!

If you prefer to work in the usual IDEs, you can use cargo apple open and cargo android open to open your project in Xcode and Android Studio respectively.

For more commands, run cargo mobile, cargo apple, or cargo android to see help information.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].