diff --git a/CMakeLists.txt b/CMakeLists.txt index beab52f..48c6728 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -152,7 +152,7 @@ set(MAIN_SOURCE if(WIN32) list(APPEND MAIN_SOURCE assets/resources.rc) list(APPEND DEFINES UNICODE) - list(APPEND PLATFORM_LIBRARIES Secur32) + list(APPEND PLATFORM_LIBRARIES Secur32 Shlwapi) include_directories( ${CMAKE_CURRENT_BINARY_DIR}/windows ) @@ -267,6 +267,7 @@ set(BINDING_HEADERS binding-mri/sceneelement-binding.h binding-mri/viewportelement-binding.h binding-mri/flashable-binding.h + binding-mri/journal-binding.h ) set(BINDING_SOURCE binding-mri/binding-mri.cpp diff --git a/conanfile.py b/conanfile.py index f0eace2..496e9ec 100644 --- a/conanfile.py +++ b/conanfile.py @@ -16,14 +16,18 @@ class MkxpConan(ConanFile): "openal/1.18.2@bincrafters/stable", "physfs/3.0.1@eliza/stable", "pixman/0.34.0@bincrafters/stable", - "ruby/2.5.1@eliza/stable", + "ruby/2.3.7@eliza/stable", "sdl2/2.0.8@bincrafters/stable", "sdl2_image/2.0.3@bincrafters/stable", "sdl2_ttf/2.0.14@eliza/stable", "sdl_sound-mkxp/1.0.1@eliza/stable", "sigc++/2.10.0@eliza/stable", ) + options = { + "platform": ["standalone", "steam"], + } default_options = ( + "platform=standalone", "boost:without_test=True", "cygwin_installer:packages=xxd", ) @@ -34,6 +38,8 @@ class MkxpConan(ConanFile): def build_configure(self): cmake = CMake(self) + if self.options.platform == "steam": + cmake.definitions["STEAM"] = "ON" cmake.configure() cmake.build() diff --git a/src/config.cpp b/src/config.cpp index ec6c8af..727ae11 100644 --- a/src/config.cpp +++ b/src/config.cpp @@ -35,6 +35,18 @@ #include "util.h" #include "sdl-util.h" +namespace std +{ + std::ostream& operator<<(std::ostream &os, const std::vector &vec) + { + for (auto item : vec) + { + os << item << " "; + } + return os; + } +} + static std::string prefPath(const char *org, const char *app) { char *path = SDL_GetPrefPath(org, app); @@ -117,9 +129,9 @@ void Config::read(int argc, char *argv[]) po::options_description podesc; podesc.add_options() PO_DESC_ALL - ("preloadScript", po::value()->composing()) - ("fontSub", po::value()->composing()) - ("rubyLoadpath", po::value()->composing()) + ("preloadScript", po::value()->composing()->default_value(StringVec())) + ("fontSub", po::value()->composing()->default_value(StringVec())) + ("rubyLoadpath", po::value()->composing()->default_value(StringVec())) ; po::variables_map vm; diff --git a/src/main.cpp b/src/main.cpp index c7af9b7..7edf507 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -46,10 +46,6 @@ #include "binding.h" -#ifdef __WINDOWS__ -#include "resource.h" -#endif - #include "icon.png.xxd" #ifdef STEAM