summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorfearlessTobi <thm.frey@gmail.com>2018-09-29 02:51:28 +0200
committerfearlessTobi <thm.frey@gmail.com>2018-10-02 15:30:49 +0200
commitac06105dfe9c7e5306e1f4cac0ee12dc5f72f14e (patch)
tree0797733e572350b7be8270942d6576cbbc46e8ba
parentReview comments - part 3 (diff)
downloadyuzu-ac06105dfe9c7e5306e1f4cac0ee12dc5f72f14e.tar
yuzu-ac06105dfe9c7e5306e1f4cac0ee12dc5f72f14e.tar.gz
yuzu-ac06105dfe9c7e5306e1f4cac0ee12dc5f72f14e.tar.bz2
yuzu-ac06105dfe9c7e5306e1f4cac0ee12dc5f72f14e.tar.lz
yuzu-ac06105dfe9c7e5306e1f4cac0ee12dc5f72f14e.tar.xz
yuzu-ac06105dfe9c7e5306e1f4cac0ee12dc5f72f14e.tar.zst
yuzu-ac06105dfe9c7e5306e1f4cac0ee12dc5f72f14e.zip
-rw-r--r--CMakeLists.txt7
-rw-r--r--src/core/CMakeLists.txt1
-rw-r--r--src/web_service/web_backend.cpp4
-rw-r--r--src/yuzu/CMakeLists.txt4
4 files changed, 7 insertions, 9 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 047443704..5e94e57ca 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -325,13 +325,6 @@ if (ENABLE_QT)
find_package(Qt5 REQUIRED COMPONENTS Widgets OpenGL ${QT_PREFIX_HINT})
endif()
-if (ENABLE_WEB_SERVICE)
- add_definitions(-DENABLE_WEB_SERVICE)
-endif()
-if (YUZU_ENABLE_COMPATIBILITY_REPORTING)
- add_definitions(-DYUZU_ENABLE_COMPATIBILITY_REPORTING)
-endif()
-
# Platform-specific library requirements
# ======================================
diff --git a/src/core/CMakeLists.txt b/src/core/CMakeLists.txt
index 95f8b5d4a..378d8128d 100644
--- a/src/core/CMakeLists.txt
+++ b/src/core/CMakeLists.txt
@@ -395,6 +395,7 @@ create_target_directory_groups(core)
target_link_libraries(core PUBLIC common PRIVATE audio_core video_core)
target_link_libraries(core PUBLIC Boost::boost PRIVATE fmt lz4_static mbedtls opus unicorn open_source_archives)
if (ENABLE_WEB_SERVICE)
+ add_definitions(-DENABLE_WEB_SERVICE)
target_link_libraries(core PUBLIC json-headers web_service)
endif()
diff --git a/src/web_service/web_backend.cpp b/src/web_service/web_backend.cpp
index 5df4df5eb..787b0fbcb 100644
--- a/src/web_service/web_backend.cpp
+++ b/src/web_service/web_backend.cpp
@@ -13,7 +13,7 @@
namespace WebService {
-constexpr char API_VERSION[]{"1"};
+constexpr std::array<const char, 1> API_VERSION{'1'};
constexpr u32 HTTP_PORT = 80;
constexpr u32 HTTPS_PORT = 443;
@@ -70,7 +70,7 @@ Common::WebResult Client::GenericJson(const std::string& method, const std::stri
};
}
- params.emplace(std::string("api-version"), std::string(API_VERSION));
+ params.emplace(std::string("api-version"), std::string(API_VERSION.begin(), API_VERSION.end()));
if (method != "GET") {
params.emplace(std::string("Content-Type"), std::string("application/json"));
};
diff --git a/src/yuzu/CMakeLists.txt b/src/yuzu/CMakeLists.txt
index f93ba2569..04464ad5e 100644
--- a/src/yuzu/CMakeLists.txt
+++ b/src/yuzu/CMakeLists.txt
@@ -120,6 +120,10 @@ target_link_libraries(yuzu PRIVATE common core input_common video_core)
target_link_libraries(yuzu PRIVATE Boost::boost glad Qt5::OpenGL Qt5::Widgets)
target_link_libraries(yuzu PRIVATE ${PLATFORM_LIBRARIES} Threads::Threads)
+if (YUZU_ENABLE_COMPATIBILITY_REPORTING)
+ add_definitions(-DYUZU_ENABLE_COMPATIBILITY_REPORTING)
+endif()
+
if (USE_DISCORD_PRESENCE)
target_sources(yuzu PUBLIC
discord_impl.cpp