Add CMake switch for disabling Discord Rich Presence and fix no llvm build

This commit is contained in:
Zion Nimchuk 2018-12-19 21:55:05 -08:00 committed by Megamouse
parent d643dcb43b
commit b5cbe02f4d
4 changed files with 5 additions and 3 deletions

View file

@ -23,5 +23,5 @@ export VULKAN_SDK=${PWD}/vulkan-sdk
git submodule update --quiet --init asmjit 3rdparty/ffmpeg 3rdparty/pugixml 3rdparty/GSL 3rdparty/libpng 3rdparty/cereal 3rdparty/hidapi 3rdparty/xxHash 3rdparty/yaml-cpp Vulkan/glslang
mkdir build; cd build
cmake .. -DWITHOUT_LLVM=On -DUSE_NATIVE_INSTRUCTIONS=OFF -G Ninja
cmake .. -DWITH_LLVM=OFF -DUSE_NATIVE_INSTRUCTIONS=OFF -G Ninja
ninja

View file

@ -152,7 +152,7 @@ target_include_directories(3rdparty_stblib INTERFACE stblib)
add_library(3rdparty_discord-rpc INTERFACE)
# We don't want Discord Rich Presence on the BSDs and other OSes
if (WIN32 OR CMAKE_SYSTEM MATCHES "Linux" OR APPLE)
if (USE_DISCORD_RPC AND (WIN32 OR CMAKE_SYSTEM MATCHES "Linux" OR APPLE))
if (WIN32 AND NOT MSVC)
ExternalProject_Add(discord-rpc
GIT_REPOSITORY https://github.com/discordapp/discord-rpc

2
3rdparty/llvm.cmake vendored
View file

@ -1,4 +1,4 @@
if(NOT WITHOUT_LLVM)
if(WITH_LLVM)
if(BUILD_LLVM_SUBMODULE)
message(STATUS "LLVM will be built from the submodule.")

View file

@ -12,6 +12,8 @@ option(USE_ALSA "ALSA audio backend" ON)
option(USE_PULSE "PulseAudio audio backend" ON)
option(USE_LIBEVDEV "libevdev-based joystick support" ON)
option(USE_DISCORD_RPC "Discord rich presence integration" ON)
option(USE_SYSTEM_ZLIB "Prefer system ZLIB instead of the builtin one" ON)
option(USE_VULKAN "Vulkan render backend" ON)