[nostalgia/studio] Add Bullock integration

This commit is contained in:
Gary Talent 2023-02-01 22:44:11 -06:00
parent fea6a0764c
commit 09d30acd7b
2 changed files with 12 additions and 0 deletions

View File

@ -15,6 +15,7 @@ add_executable(
target_link_libraries(
nostalgia-studio
OxClArgs
OxLogConn
NostalgiaStudio
NostalgiaCore-Studio
)

View File

@ -2,6 +2,8 @@
* Copyright 2016 - 2022 Gary Talent (gary@drinkingtea.net). All rights reserved.
*/
#include <ox/logconn/logconn.hpp>
#include <ox/std/trace.hpp>
#include <nostalgia/core/core.hpp>
@ -53,6 +55,15 @@ static ox::Error run(ox::UniquePtr<ox::FileSystem> fs) noexcept {
static ox::Error run(int argc, const char **argv) noexcept {
ox::trace::init();
#ifdef DEBUG
ox::LoggerConn loggerConn;
const auto loggerErr = loggerConn.initConn("Nostalgia Studio");
if (loggerErr) {
oxErrf("Could not connect to logger: {}\n", toStr(loggerErr));
} else {
ox::trace::setLogger(&loggerConn);
}
#endif
if (argc >= 2) {
const auto path = argv[1];
oxRequireM(fs, core::loadRomFs(path));