aboutsummaryrefslogtreecommitdiffhomepage
path: root/externals
diff options
context:
space:
mode:
authorAlexandre Bouvier <[email protected]>2023-11-03 19:27:08 +0100
committerAlexandre Bouvier <[email protected]>2023-11-30 16:54:00 +0100
commitd2bb9e9729bbdeb396817c2335c4fafbf5ac94a2 (patch)
treef09b1f3a4c07ffdd1ba36ad6993a3220c5fbdf0b /externals
parent127bfb81d5f03eb86f21053e6423083fec18d3fa (diff)
downloadyuzu-mainline-d2bb9e9729bbdeb396817c2335c4fafbf5ac94a2.tar.gz
yuzu-mainline-d2bb9e9729bbdeb396817c2335c4fafbf5ac94a2.zip
cmake: prefer system gamemode library
Diffstat (limited to 'externals')
-rw-r--r--externals/CMakeLists.txt6
-rw-r--r--externals/gamemode/CMakeLists.txt11
-rw-r--r--externals/gamemode/gamemode_client.h (renamed from externals/gamemode/include/gamemode_client.h)3
3 files changed, 4 insertions, 16 deletions
diff --git a/externals/CMakeLists.txt b/externals/CMakeLists.txt
index 04007a538..407c5c640 100644
--- a/externals/CMakeLists.txt
+++ b/externals/CMakeLists.txt
@@ -193,8 +193,10 @@ if (ANDROID)
endif()
endif()
-if (UNIX AND NOT APPLE)
- add_subdirectory(gamemode)
+if (UNIX AND NOT APPLE AND NOT TARGET gamemode::headers)
+ add_library(gamemode INTERFACE)
+ target_include_directories(gamemode INTERFACE gamemode)
+ add_library(gamemode::headers ALIAS gamemode)
endif()
# Breakpad
diff --git a/externals/gamemode/CMakeLists.txt b/externals/gamemode/CMakeLists.txt
deleted file mode 100644
index 87095642e..000000000
--- a/externals/gamemode/CMakeLists.txt
+++ /dev/null
@@ -1,11 +0,0 @@
-# SPDX-FileCopyrightText: Copyright 2023 yuzu Emulator Project
-# SPDX-License-Identifier: GPL-3.0-or-later
-
-project(gamemode LANGUAGES CXX C)
-
-add_library(gamemode include/gamemode_client.h)
-
-target_link_libraries(gamemode PRIVATE common)
-
-target_include_directories(gamemode PUBLIC include)
-set_target_properties(gamemode PROPERTIES LINKER_LANGUAGE C)
diff --git a/externals/gamemode/include/gamemode_client.h b/externals/gamemode/gamemode_client.h
index 184812334..b9f64fe46 100644
--- a/externals/gamemode/include/gamemode_client.h
+++ b/externals/gamemode/gamemode_client.h
@@ -1,6 +1,3 @@
-// SPDX-FileCopyrightText: Copyright 2017-2019 Feral Interactive
-// SPDX-License-Identifier: BSD-3-Clause
-
/*
Copyright (c) 2017-2019, Feral Interactive