Platform Setup

Basic setup of Ceramic allows to build apps with the web target and run these through electron.

In order to build native apps (using C++ target) and support additional platforms, specific setup is required.

Mac

Building for Mac can only be done from Mac

You should then be able to build a native Mac app when you select Build/Run Mac from Visual Studio Code.

Windows

Building for Windows can only be done from Windows

You should then be able to build a native Windows app when you select Build/Run Windows from Visual Studio Code.

iOS

Building for iOS can only be done from Mac

You should then be able to build a native Windows app when you select Build/Run iOS from Visual Studio Code.

Android

Building for Android can be done from Mac, Linux and Windows

HXCPP needs to know where your Android SDK and Android NDK are installed. To solve that, you need to add some info inside your .hxcpp-config.xml (that should be located inside your home directory. If not, you can create it).

An example of Android config to put inside .hxcpp-config.xml
<xml>
  <section id="vars">
      <set name="SDK_ROOT" value="C:/Path/to/your/SDKs/" />
      <set name="ANDROID_SETUP" value="true" />
      <set name="ANDROID_SDK" value="C:/Path/to/your/Android/sdk" />
      <set name="ANDROID_NDK_ROOT" value="C:/Path/to/your/Android/NDK" />
      <set name="ANDROID_NDK_DIR" value="C:/Path/to/your/Android/NDK"  />
  </section>
</xml>

Also note that if you are using Android NDK r15c, you'll need to add ceramic_android_use_gcc define to ceramic.yml. If you are on macOS Catalina or above, you may also need to disable Gatekeeper to make that NDK work:

sudo spctl --master-disable

Linux

Building for Linux can only be done from Linux

Install g++ if not installed already:

sudo apt-get install g++

Install SDL (on linux, ceramic app is linking to the SDL installed on your machine).

sudo apt-get install libsdl2-dev

Your SDL version should be equal or above 2.0.22. On Ubuntu, you might need to add an additional repository like ppa:savoury1/multimedia as explained here, in order to get latest SDL version.

Install required dependencies:

sudo apt-get install libasound2-dev libx11-dev libxext-dev libxi-dev libxrandr-dev libxinerama-dev libglfw3-dev libgl1-mesa-dev libglu1-mesa-dev libopenal-dev

You should then be able to build a native Linux app when you select Build/Run Linux from Visual Studio Code.

Unity

Building for unity can be done from Mac and Windows. Linux is considered in a future release but not implemented yet.

You should then be able to export a Unity project when you select Build/Run Unity from Visual Studio Code.

If you installed Unity on a non-standard path, you can specify the path to your Unity installation inside your project's ceramic.yml

ceramic.yml
app:

    unity:
        path: 'C:/Path/To/Your/Unity/Editor/'

Continue reading ➔ Reference: ceramic.yml