Skip to content

Commit

Permalink
Fixed build
Browse files Browse the repository at this point in the history
  • Loading branch information
deathkiller committed Feb 19, 2024
1 parent 6e26917 commit e0aa10c
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 17 deletions.
2 changes: 1 addition & 1 deletion Sources/Jazz2/PreferencesCache.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,7 @@ namespace Jazz2
std::uint8_t controlMappingCount = uc.ReadValue<std::uint8_t>();
for (std::uint32_t i = 0; i < playerCount; i++) {
for (std::uint32_t j = 0; j < controlMappingCount; j++) {
std:uint8_t targetCount = uc.ReadValue<std::uint8_t>();
std::uint8_t targetCount = uc.ReadValue<std::uint8_t>();
if (i < UI::ControlScheme::MaxSupportedPlayers && j < (std::uint32_t)PlayerActions::Count) {
auto& mapping = mappings[i * (std::uint32_t)PlayerActions::Count + j];
mapping.Targets.clear();
Expand Down
20 changes: 6 additions & 14 deletions Sources/backward/backward.h
Original file line number Diff line number Diff line change
Expand Up @@ -53,18 +53,13 @@
// #define BACKWARD_SYSTEM_WINDOWS
// - specialization for Windows (Clang 9 and MSVC2017)
//
// #define BACKWARD_SYSTEM_UNKNOWN
// - placebo implementation, does nothing.
//
#if !(defined(BACKWARD_SYSTEM_LINUX) || defined(BACKWARD_SYSTEM_DARWIN) || defined(BACKWARD_SYSTEM_UNKNOWN) || defined(BACKWARD_SYSTEM_WINDOWS))
#if !(defined(BACKWARD_SYSTEM_LINUX) || defined(BACKWARD_SYSTEM_DARWIN) || defined(BACKWARD_SYSTEM_WINDOWS))
# if defined(__linux) || defined(__linux__)
# define BACKWARD_SYSTEM_LINUX
# elif defined(DEATH_TARGET_APPLE)
# define BACKWARD_SYSTEM_DARWIN
# elif defined(DEATH_TARGET_WINDOWS)
# define BACKWARD_SYSTEM_WINDOWS
# else
# define BACKWARD_SYSTEM_UNKNOWN
# endif
#endif

Expand Down Expand Up @@ -434,18 +429,15 @@ namespace backward {
struct linux_tag; // seems that I cannot call that "linux" because the name is already defined... so I am adding _tag everywhere.
struct darwin_tag;
struct windows_tag;
struct unknown_tag;

#if defined(BACKWARD_SYSTEM_LINUX)
typedef linux_tag current_tag;
#elif defined(BACKWARD_SYSTEM_DARWIN)
typedef darwin_tag current_tag;
#elif defined(BACKWARD_SYSTEM_WINDOWS)
typedef windows_tag current_tag;
#elif defined(BACKWARD_SYSTEM_UNKNOWN)
typedef unknown_tag current_tag;
#else
# error "May I please get my system defines?"
# error "Unsupported platform"
#endif
} // namespace system_tag

Expand Down Expand Up @@ -1282,12 +1274,12 @@ namespace backward {

template <typename TAG> class TraceResolverImpl;

#if defined(BACKWARD_SYSTEM_UNKNOWN)
/*#if defined(BACKWARD_SYSTEM_UNKNOWN)
template<>
class TraceResolverImpl<system_tag::unknown_tag> : public TraceResolverImplBase {};
#endif
#endif*/

#if defined(BACKWARD_SYSTEM_LINUX)

Expand Down Expand Up @@ -4458,7 +4450,7 @@ namespace backward {

#endif // BACKWARD_SYSTEM_WINDOWS

#if defined(BACKWARD_SYSTEM_UNKNOWN)
/*#if defined(BACKWARD_SYSTEM_UNKNOWN)
class SignalHandling {
public:
Expand All @@ -4471,7 +4463,7 @@ namespace backward {
}
};
#endif // BACKWARD_SYSTEM_UNKNOWN
#endif*/

} // namespace backward

Expand Down
1 change: 0 additions & 1 deletion cmake/ncine_extra_sources.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@ endif()
if(BACKWARD_FOUND)
target_compile_definitions(${NCINE_APP} PRIVATE "WITH_BACKWARD")
target_link_libraries(${NCINE_APP} PRIVATE Backward::Interface)
message(STATUS "Building the game with Backward integration")
endif()

if(ANGLE_FOUND OR OPENGLES2_FOUND)
Expand Down
5 changes: 4 additions & 1 deletion cmake/ncine_options.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,10 @@ else()
if((WIN32 OR NOT NCINE_ARM_PROCESSOR) AND NOT ANDROID AND NOT NCINE_BUILD_ANDROID AND NOT NINTENDO_SWITCH)
option(NCINE_WITH_GLEW "Use GLEW library" ON)
endif()

if(NOT WINDOWS_PHONE AND NOT WINDOWS_STORE)
option(NCINE_WITH_BACKWARD "Enable integration with Backward for better stack traces" ON)
endif()
endif()

option(NCINE_WITH_WEBP "Enable WebP image file support" OFF)
Expand All @@ -64,7 +68,6 @@ cmake_dependent_option(NCINE_WITH_VORBIS "Enable Ogg Vorbis audio file support"
cmake_dependent_option(NCINE_WITH_OPENMPT "Enable module (libopenmpt) audio file support" ON "NCINE_WITH_AUDIO" OFF)
option(NCINE_WITH_ANGELSCRIPT "Enable AngelScript scripting support" OFF)
option(NCINE_WITH_IMGUI "Enable integration with Dear ImGui" OFF)
option(NCINE_WITH_BACKWARD "Enable integration with Backward for better stack traces" ON)
option(NCINE_WITH_TRACY "Enable integration with Tracy frame profiler" OFF)
option(NCINE_WITH_RENDERDOC "Enable integration with RenderDoc" OFF)

Expand Down

0 comments on commit e0aa10c

Please sign in to comment.