Get started

From clone to running app

A C++20 compiler and CMake 3.31 or later are all you need to build the examples. When you are ready, pull YUP into your own project with FetchContent.

1

Install the prerequisites

Pick your platform. Every target builds from the same sources.

Windows

Visual Studio 2022.

macOS and iOS

Xcode 15.2 and the command-line tools.

Wasm

Emscripten SDK 4.0.22 or later. The WebGPU port is fetched automatically.

Android

JDK 17, Android SDK and NDK r27c or later.

Linux packages
sudo apt-get update && sudo apt-get install -y \
    libasound2-dev libjack-jackd2-dev ladspa-sdk libcurl4-openssl-dev libfreetype6-dev \
    libx11-dev libxcomposite-dev libxcursor-dev libxext-dev libxi-dev libxinerama-dev \
    libxrandr-dev libxrender-dev libglu1-mesa-dev mesa-common-dev
2

Clone and build the examples

A standard desktop build with tests and examples enabled.

git clone https://github.com/kunitoki/yup.git
cd yup
cmake -S . -B build -DYUP_BUILD_TESTS=ON -DYUP_BUILD_EXAMPLES=ON
cmake --build build --config Release --parallel 4

Then run targets like example_graphics, example_app or example_console, and yup_tests for the test suite.

3

Add YUP to your project

Fetch the framework and declare an app or plugin target with the modules you need.

cmake_minimum_required (VERSION 3.31)
project (my_app VERSION 1.0.0)

include (FetchContent)

FetchContent_Declare (yup
    GIT_REPOSITORY https://github.com/kunitoki/yup.git
    GIT_TAG        main)

set (YUP_BUILD_EXAMPLES OFF)
set (YUP_BUILD_TESTS OFF)
FetchContent_MakeAvailable (yup)

yup_standalone_app (
    TARGET_NAME my_app
    TARGET_VERSION 1.0.0
    TARGET_IDE_GROUP "MyApp"
    TARGET_APP_NAMESPACE "com.mycompany"
    TARGET_CXX_STANDARD 20
    MODULES
        yup::yup_gui
        yup::yup_audio_devices)

target_sources (my_app PRIVATE main.cpp)
4

Keep going