[GH-ISSUE #1778] Build warnings and notes #610

Closed
opened 2026-02-27 21:07:13 +03:00 by kerem · 2 comments
Owner

Originally created by @C0rn3j on GitHub (Dec 14, 2024).
Original GitHub issue: https://github.com/shadps4-emu/shadPS4/issues/1778

Currently, building from master throws a bunch of warnings and notes on my system, most seem harmless, but some seem possibly a bit worrying.

I figured I might just ask about all of them to make sure they are okay, and not an actual issue perhaps limited to my setup.


  1. I suppose this is on the external lib?
In file included from /build/shadps4-git/src/shadps4/externals/tracy/public/TracyClient.cpp:25:
/build/shadps4-git/src/shadps4/externals/tracy/public/client/TracySysPower.cpp: In member function void tracy::SysPower::ScanDirectory(const char*, int):
/build/shadps4-git/src/shadps4/externals/tracy/public/client/TracySysPower.cpp:88:27: warning: ignoring return value of int fscanf(FILE*, const char*, ...) declared with attribute warn_unused_result [-Wunused-result]
   88 |                     fscanf( f, "%" PRIu64, &maxRange );
      |                     ~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~

  1. I suppose the Qt UI elements just need a rename?
AutoUic: /build/shadps4-git/src/shadps4/src/qt_gui/settings_dialog.ui: Warning: The name 'inputTabVLayout' (QVBoxLayout) is already in use, defaulting to 'inputTabVLayout1'.

  1. There's a PR for this one already, just a deprecation, and I am not hitting it anymore after github.com/shadps4-emu/shadPS4@3f1061de56 relegated it to just an UPDATER ifdef anyway:
/build/shadps4-git/src/shadps4/src/qt_gui/settings_dialog.cpp:133:53: warning: void QCheckBox::stateChanged(int) is deprecated: Use checkStateChanged() instead [-Wdeprecated-declarations]

  1. These following two look(to my ignorant eye) like the only actually worrying ones:
In file included from /build/shadps4-git/src/shadps4/src/core/loader/symbols_resolver.cpp:9:
/build/shadps4-git/src/shadps4/src/core/loader/symbols_resolver.h: In static member function static std::string_view Core::Loader::SymbolsResolver::SymbolTypeToS(Core::Loader::SymbolType):
/build/shadps4-git/src/shadps4/src/core/loader/symbols_resolver.h:72:5: warning: control reaches end of non-void function [-Wreturn-type]
   72 |     }
      |     ^
In file included from /build/shadps4-git/src/shadps4/src/shader_recompiler/frontend/control_flow_graph.h:16,
                 from /build/shadps4-git/src/shadps4/src/shader_recompiler/frontend/control_flow_graph.cpp:6:
/build/shadps4-git/src/shadps4/src/shader_recompiler/ir/condition.h: In function constexpr std::string_view Shader::IR::NameOf(Condition):
/build/shadps4-git/src/shadps4/src/shader_recompiler/ir/condition.h:41:1: warning: control reaches end of non-void function [-Wreturn-type]
   41 | }
      | ^

  1. Is this only related to debug packages?
/usr/src/debug/shadps4-git/shadps4/src/core/libraries/kernel/threads/exception.h:62:8: warning: type struct Stack violates the C++ One Definition Rule [-Wodr]
/usr/src/debug/shadps4-git/shadps4/src/core/libraries/kernel/threads/thread_state.h:20:8: note: a different type is defined in another translation unit
/usr/src/debug/shadps4-git/shadps4/src/core/libraries/kernel/threads/exception.h:63:11: note: the first difference of corresponding definitions is field ss_sp
/usr/src/debug/shadps4-git/shadps4/src/core/libraries/kernel/threads/thread_state.h:21:12: note: a field with different name is defined in another translation unit

  1. I presume these are entirely on SDL3, and only related to debug packages?
/usr/src/debug/shadps4-git/shadps4/externals/sdl3/src/video/kmsdrm/../SDL_egl_c.h:133: warning: type of SDL_EGL_CreateSurface does not match original declaration [-Wlto-type-mismatch]
/usr/src/debug/shadps4-git/shadps4/externals/sdl3/src/video/SDL_egl.c:1214: note: type mismatch in parameter 3
/usr/src/debug/shadps4-git/shadps4/externals/sdl3/src/video/SDL_egl.c:1214: note: type NativeWindowType should match type struct wl_egl_window *
/usr/src/debug/shadps4-git/shadps4/externals/sdl3/src/video/SDL_egl.c:1214: note: SDL_EGL_CreateSurface was previously declared here
/usr/src/debug/shadps4-git/shadps4/externals/sdl3/src/video/SDL_egl.c:1214: note: code may be misoptimized unless -fno-strict-aliasing is used

Full build log: shadps4-git-0.4.0.r197.ge752f04c-2-x86_64-build.log

Originally created by @C0rn3j on GitHub (Dec 14, 2024). Original GitHub issue: https://github.com/shadps4-emu/shadPS4/issues/1778 Currently, building from master throws a bunch of warnings and notes on my system, most seem harmless, but some seem possibly a bit worrying. I figured I might just ask about all of them to make sure they are okay, and not an actual issue perhaps limited to my setup. --- 1. I suppose this is on the external lib? ```c++ In file included from /build/shadps4-git/src/shadps4/externals/tracy/public/TracyClient.cpp:25: /build/shadps4-git/src/shadps4/externals/tracy/public/client/TracySysPower.cpp: In member function ‘void tracy::SysPower::ScanDirectory(const char*, int)’: /build/shadps4-git/src/shadps4/externals/tracy/public/client/TracySysPower.cpp:88:27: warning: ignoring return value of ‘int fscanf(FILE*, const char*, ...)’ declared with attribute ‘warn_unused_result’ [-Wunused-result] 88 | fscanf( f, "%" PRIu64, &maxRange ); | ~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~ ``` --- 2. I suppose the Qt UI elements just need a rename? ```c++ AutoUic: /build/shadps4-git/src/shadps4/src/qt_gui/settings_dialog.ui: Warning: The name 'inputTabVLayout' (QVBoxLayout) is already in use, defaulting to 'inputTabVLayout1'. ``` --- 3. There's a PR for this one already, just a deprecation, and I am not hitting it anymore after https://github.com/shadps4-emu/shadPS4/commit/3f1061de5613c0c4a74d6394a6493491280bc03f relegated it to just an UPDATER ifdef anyway: ```c++ /build/shadps4-git/src/shadps4/src/qt_gui/settings_dialog.cpp:133:53: warning: ‘void QCheckBox::stateChanged(int)’ is deprecated: Use checkStateChanged() instead [-Wdeprecated-declarations] ``` --- 4. These following two look(to my ignorant eye) like the only actually worrying ones: ```c++ In file included from /build/shadps4-git/src/shadps4/src/core/loader/symbols_resolver.cpp:9: /build/shadps4-git/src/shadps4/src/core/loader/symbols_resolver.h: In static member function ‘static std::string_view Core::Loader::SymbolsResolver::SymbolTypeToS(Core::Loader::SymbolType)’: /build/shadps4-git/src/shadps4/src/core/loader/symbols_resolver.h:72:5: warning: control reaches end of non-void function [-Wreturn-type] 72 | } | ^ ``` ```c++ In file included from /build/shadps4-git/src/shadps4/src/shader_recompiler/frontend/control_flow_graph.h:16, from /build/shadps4-git/src/shadps4/src/shader_recompiler/frontend/control_flow_graph.cpp:6: /build/shadps4-git/src/shadps4/src/shader_recompiler/ir/condition.h: In function ‘constexpr std::string_view Shader::IR::NameOf(Condition)’: /build/shadps4-git/src/shadps4/src/shader_recompiler/ir/condition.h:41:1: warning: control reaches end of non-void function [-Wreturn-type] 41 | } | ^ ``` --- 5. Is this only related to debug packages? ```c++ /usr/src/debug/shadps4-git/shadps4/src/core/libraries/kernel/threads/exception.h:62:8: warning: type ‘struct Stack’ violates the C++ One Definition Rule [-Wodr] /usr/src/debug/shadps4-git/shadps4/src/core/libraries/kernel/threads/thread_state.h:20:8: note: a different type is defined in another translation unit /usr/src/debug/shadps4-git/shadps4/src/core/libraries/kernel/threads/exception.h:63:11: note: the first difference of corresponding definitions is field ‘ss_sp’ /usr/src/debug/shadps4-git/shadps4/src/core/libraries/kernel/threads/thread_state.h:21:12: note: a field with different name is defined in another translation unit ``` --- 6. I presume these are entirely on SDL3, and only related to debug packages? ```c++ /usr/src/debug/shadps4-git/shadps4/externals/sdl3/src/video/kmsdrm/../SDL_egl_c.h:133: warning: type of ‘SDL_EGL_CreateSurface’ does not match original declaration [-Wlto-type-mismatch] /usr/src/debug/shadps4-git/shadps4/externals/sdl3/src/video/SDL_egl.c:1214: note: type mismatch in parameter 3 /usr/src/debug/shadps4-git/shadps4/externals/sdl3/src/video/SDL_egl.c:1214: note: type ‘NativeWindowType’ should match type ‘struct wl_egl_window *’ /usr/src/debug/shadps4-git/shadps4/externals/sdl3/src/video/SDL_egl.c:1214: note: ‘SDL_EGL_CreateSurface’ was previously declared here /usr/src/debug/shadps4-git/shadps4/externals/sdl3/src/video/SDL_egl.c:1214: note: code may be misoptimized unless ‘-fno-strict-aliasing’ is used ``` Full build log: [shadps4-git-0.4.0.r197.ge752f04c-2-x86_64-build.log](https://github.com/user-attachments/files/18135926/shadps4-git-0.4.0.r197.ge752f04c-2-x86_64-build.log)
kerem closed this issue 2026-02-27 21:07:14 +03:00
Author
Owner

@Hermiten commented on GitHub (Dec 14, 2024):

These are things that developers are aware of, but sometimes there's no need to change or it's not necessarily useful.
It's better to propose a PR to correct them :)

<!-- gh-comment-id:2543112711 --> @Hermiten commented on GitHub (Dec 14, 2024): These are things that developers are aware of, but sometimes there's no need to change or it's not necessarily useful. It's better to propose a PR to correct them :)
Author
Owner

@C0rn3j commented on GitHub (Dec 14, 2024):

If it's all known and not something that plagues just my setup that's all I needed to know, thanks!

<!-- gh-comment-id:2543115139 --> @C0rn3j commented on GitHub (Dec 14, 2024): If it's all known and not something that plagues just my setup that's all I needed to know, thanks!
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/shadPS4#610
No description provided.