diff --git a/CMakeLists.txt b/CMakeLists.txt index 232fbf9e1..e75536997 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -86,7 +86,8 @@ option(ENABLE_QT_TRANSLATION "Enable translations for the Qt frontend" OFF) option(ENABLE_QT_UPDATE_CHECKER "Enable built-in update checker for the Qt frontend" OFF) CMAKE_DEPENDENT_OPTION(ENABLE_TESTS "Enable generating tests executable" ON "NOT IOS" OFF) -CMAKE_DEPENDENT_OPTION(ENABLE_ROOM "Enable generating dedicated room executable" ON "NOT ANDROID AND NOT IOS" OFF) +CMAKE_DEPENDENT_OPTION(ENABLE_ROOM "Enable dedicated room functionality" ON "NOT ANDROID AND NOT IOS" OFF) +CMAKE_DEPENDENT_OPTION(ENABLE_ROOM_STANDALONE "Enable generating a standalone dedicated room executable" ON "ENABLE_ROOM" OFF) option(ENABLE_WEB_SERVICE "Enable web services (telemetry, etc.)" ON) option(ENABLE_SCRIPTING "Enable RPC server for scripting" ON) @@ -487,6 +488,9 @@ if (NOT ANDROID AND NOT IOS) elseif (ENABLE_SDL2_FRONTEND) bundle_target(citra_meta) endif() + if (ENABLE_ROOM_STANDALONE) + bundle_target(citra_room_standalone) + endif() endif() # Installation instructions diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 3dd3a31fa..16820de20 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -199,6 +199,10 @@ if (ENABLE_ROOM) add_subdirectory(citra_room) endif() +if (ENABLE_ROOM_STANDALONE) + add_subdirectory(citra_room_standalone) +endif() + if (ANDROID) add_subdirectory(android/app/src/main/jni) target_include_directories(citra-android PRIVATE android/app/src/main) diff --git a/src/citra_room_standalone/CMakeLists.txt b/src/citra_room_standalone/CMakeLists.txt new file mode 100644 index 000000000..e48051469 --- /dev/null +++ b/src/citra_room_standalone/CMakeLists.txt @@ -0,0 +1,11 @@ +add_executable(citra_room_standalone + citra_room_standalone.cpp +) + +set_target_properties(citra_room_standalone PROPERTIES OUTPUT_NAME "azahar-room") + +target_link_libraries(citra_room_standalone PRIVATE citra_room) + +if(UNIX AND NOT APPLE) + install(TARGETS citra_room_standalone RUNTIME DESTINATION "${CMAKE_INSTALL_PREFIX}/bin") +endif() diff --git a/src/citra_room_standalone/citra_room_standalone.cpp b/src/citra_room_standalone/citra_room_standalone.cpp new file mode 100644 index 000000000..7bc6240ad --- /dev/null +++ b/src/citra_room_standalone/citra_room_standalone.cpp @@ -0,0 +1,9 @@ +// Copyright Citra Emulator Project / Azahar Emulator Project +// Licensed under GPLv2 or any later version +// Refer to the license.txt file included. + +#include "citra_room/citra_room.h" + +int main(int argc, char* argv[]) { + LaunchRoom(argc, argv); +}