Skip to content

gusc/CppCrossPlatform

main
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
 
 
app
 
 
 
 
 
 
 
 
 
 
 
 
 
 

CppCrossPlatform

This is an example project for creating cross-platform apps with C++ for the article in my blog.

Covered platforms

  • Android
  • iOS
  • macOS
  • Windows

Covers techniques

  • JNI
  • Objective-C runtime

Requirements

  • CMake 3.20+ for everything except Android, 3.10 shipped with Android SDK
  • Android Studio for Android developemtn
  • Visual Studio for Windows development (Community Edition will be enough)
  • Xcode for iOS and macOS development
  • Gradle and Ninja are part of Android SDK

Generating IDE projects

Android Stuio

Just open the source root with Android Studio and hit Gradle Sync button on the top-right corner.

Xcode

# Generate iOS project
cmake -G Xcode -S . -B build_ios -DCMAKE_SYSTEM_NAME=iOS
# Generate macOS project
cmake -G Xcode -S . -B build_macos

note: on iOS you'll need to set your devepoment team manually for code signing to work

Visual Studio

# Generate Windows project
cmake -G "Visual Studio 15 2017 Win64" -S . -B build_windows

About

This is an example project for creating cross-platform apps with C++

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published