Commit 0f43bbe9 authored by Ryan Pavlik's avatar Ryan Pavlik
Browse files

inc/xrt: Add Android config header to store package name.

parent b90dc8fd
......@@ -178,6 +178,17 @@ cmake_dependent_option(XRT_BUILD_DRIVER_SURVIVE "Enable libsurvive driver" OFF "
# All drivers must be listed in here to be included in the generated header!
list(APPEND AVAILABLE_DRIVERS ARDUINO DUMMY HDK HYDRA NS OHMD PSMV PSVR RS V4L2 VIVE DAYDREAM REMOTE SURVIVE)
# Package name needs to be known by the native code itself.
# Can be overridden from outside/command line
if(ANDROID AND NOT XRT_ANDROID_PACKAGE)
if(XRT_FEATURE_SERVICE)
set(XRT_ANDROID_PACKAGE "org.freedesktop.monado.openxr_runtime.out_of_process")
else()
set(XRT_ANDROID_PACKAGE "org.freedesktop.monado.openxr_runtime.in_process")
endif()
endif()
###
# Flags
###
......
......@@ -30,3 +30,9 @@ configure_file(
${CMAKE_CURRENT_BINARY_DIR}/xrt_config_vulkan.h
@ONLY
)
configure_file(
${CMAKE_CURRENT_SOURCE_DIR}/xrt_config_android.h.cmake_in
${CMAKE_CURRENT_BINARY_DIR}/xrt_config_android.h
@ONLY
)
// Copyright 2020, Collabora, Ltd.
// SPDX-License-Identifier: BSL-1.0
/*!
* @file
* @brief Android defines.
* @author Ryan Pavlik <ryan.pavlik@collabora.com>
* @ingroup xrt_iface
*/
#pragma once
#cmakedefine XRT_ANDROID_PACKAGE "@XRT_ANDROID_PACKAGE@"
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment