diff --git a/src/xrt/state_trackers/oxr/CMakeLists.txt b/src/xrt/state_trackers/oxr/CMakeLists.txt index 446f0580d..fc4c55bb5 100644 --- a/src/xrt/state_trackers/oxr/CMakeLists.txt +++ b/src/xrt/state_trackers/oxr/CMakeLists.txt @@ -19,12 +19,12 @@ set(OXR_SOURCE_FILES oxr_api_verify.h oxr_binding.c oxr_chain.h - oxr_event.cpp + oxr_event.c oxr_extension_support.h oxr_handle_base.c oxr_input.c oxr_instance.c - oxr_logger.cpp + oxr_logger.c oxr_logger.h oxr_objects.h oxr_path.c diff --git a/src/xrt/state_trackers/oxr/meson.build b/src/xrt/state_trackers/oxr/meson.build index 0446b97b6..46bed2cb7 100644 --- a/src/xrt/state_trackers/oxr/meson.build +++ b/src/xrt/state_trackers/oxr/meson.build @@ -20,7 +20,7 @@ lib_st_oxr = static_library( 'oxr_handle_base.c', 'oxr_input.c', 'oxr_instance.c', - 'oxr_logger.cpp', + 'oxr_logger.c', 'oxr_logger.h', 'oxr_objects.h', 'oxr_path.c', diff --git a/src/xrt/state_trackers/oxr/oxr_logger.cpp b/src/xrt/state_trackers/oxr/oxr_logger.c similarity index 97% rename from src/xrt/state_trackers/oxr/oxr_logger.cpp rename to src/xrt/state_trackers/oxr/oxr_logger.c index b0d9b11fd..5eb7abbd4 100644 --- a/src/xrt/state_trackers/oxr/oxr_logger.cpp +++ b/src/xrt/state_trackers/oxr/oxr_logger.c @@ -137,7 +137,7 @@ oxr_slog_ensure(struct oxr_sink_logger *slog, size_t extra) slog->store = (char *)realloc(slog->store, slog->store_size); } -extern "C" void +void oxr_slog(struct oxr_sink_logger *slog, const char *fmt, ...) { va_list args; @@ -162,7 +162,7 @@ oxr_slog(struct oxr_sink_logger *slog, const char *fmt, ...) slog->length += ret; } -extern "C" void +void oxr_slog_free(struct oxr_sink_logger *slog) { free(slog->store); @@ -170,21 +170,21 @@ oxr_slog_free(struct oxr_sink_logger *slog) slog->store_size = 0; } -extern "C" void +void oxr_log_slog(struct oxr_logger *log, struct oxr_sink_logger *slog) { oxr_log(log, "%s", slog->store); oxr_slog_free(slog); } -extern "C" void +void oxr_warn_slog(struct oxr_logger *log, struct oxr_sink_logger *slog) { oxr_warn(log, "%s", slog->store); oxr_slog_free(slog); } -extern "C" XrResult +XrResult oxr_error_slog(struct oxr_logger *log, XrResult res, struct oxr_sink_logger *slog)