[GH-ISSUE #2061] [APP BUG]: gcc build failing on PSFAttributes #709

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

Originally created by @C0rn3j on GitHub (Jan 5, 2025).
Original GitHub issue: https://github.com/shadps4-emu/shadPS4/issues/2061

Checklist

  • I have searched for a similar issue in this repository and did not find one.
  • I am using an official build obtained from releases or updated one of those builds using its in-app updater.

Describe the Bug

[ 39%] Building CXX object CMakeFiles/shadps4.dir/src/common/error.cpp.o
In file included from /home/c0rn3j/.cache/paru/clone/shadps4-git/src/shadps4/src/emulator.cpp:19:
/home/c0rn3j/.cache/paru/clone/shadps4-git/src/shadps4/src/common/elf_info.h:114:40: error: declaration of const Common::PSFAttributes& Common::ElfInfo::PSFAttributes() const changes meaning of PSFAttributes [-Wchanges-meaning]
  114 |     [[nodiscard]] const PSFAttributes& PSFAttributes() const {
      |                                        ^~~~~~~~~~~~~
/home/c0rn3j/.cache/paru/clone/shadps4-git/src/shadps4/src/common/elf_info.h:114:25: note: used here to mean union Common::PSFAttributes
  114 |     [[nodiscard]] const PSFAttributes& PSFAttributes() const {
      |                         ^~~~~~~~~~~~~
/home/c0rn3j/.cache/paru/clone/shadps4-git/src/shadps4/src/common/elf_info.h:20:7: note: declared here
   20 | union PSFAttributes {
      |       ^~~~~~~~~~~~~

#2027 makes sure this is caught in the CI, but until that is merged, this made it through again.

Reproduction Steps

Build on GCC

Expected Behavior

No response

Specify OS Version

Arch Linux

Originally created by @C0rn3j on GitHub (Jan 5, 2025). Original GitHub issue: https://github.com/shadps4-emu/shadPS4/issues/2061 ### Checklist - [X] I have searched for a similar issue in this repository and did not find one. - [X] I am using an official build obtained from [releases](https://github.com/shadps4-emu/shadPS4/releases) or updated one of those builds using its in-app updater. ### Describe the Bug ```c++ [ 39%] Building CXX object CMakeFiles/shadps4.dir/src/common/error.cpp.o In file included from /home/c0rn3j/.cache/paru/clone/shadps4-git/src/shadps4/src/emulator.cpp:19: /home/c0rn3j/.cache/paru/clone/shadps4-git/src/shadps4/src/common/elf_info.h:114:40: error: declaration of ‘const Common::PSFAttributes& Common::ElfInfo::PSFAttributes() const’ changes meaning of ‘PSFAttributes’ [-Wchanges-meaning] 114 | [[nodiscard]] const PSFAttributes& PSFAttributes() const { | ^~~~~~~~~~~~~ /home/c0rn3j/.cache/paru/clone/shadps4-git/src/shadps4/src/common/elf_info.h:114:25: note: used here to mean ‘union Common::PSFAttributes’ 114 | [[nodiscard]] const PSFAttributes& PSFAttributes() const { | ^~~~~~~~~~~~~ /home/c0rn3j/.cache/paru/clone/shadps4-git/src/shadps4/src/common/elf_info.h:20:7: note: declared here 20 | union PSFAttributes { | ^~~~~~~~~~~~~ ``` #2027 makes sure this is caught in the CI, but until that is merged, this made it through again. ### Reproduction Steps Build on GCC ### Expected Behavior _No response_ ### Specify OS Version Arch Linux
kerem closed this issue 2026-02-27 21:07:44 +03:00
Author
Owner

@cromachina commented on GitHub (Jan 6, 2025):

Simple patch for this issue on top of 8f33dfe4f1 if anyone wants to just get it to compile on their system with GCC:
patch.txt

<!-- gh-comment-id:2573689251 --> @cromachina commented on GitHub (Jan 6, 2025): Simple patch for this issue on top of 8f33dfe4f17c6f4616bf273f615d5a42a76380cf if anyone wants to just get it to compile on their system with GCC: [patch.txt](https://github.com/user-attachments/files/18323169/patch.txt)
Author
Owner

@C0rn3j commented on GitHub (Jan 8, 2025):

#2089 was merged that fixes this, and #2027 was merged with the CI, this should happen no more :)

<!-- gh-comment-id:2577612744 --> @C0rn3j commented on GitHub (Jan 8, 2025): #2089 was merged that fixes this, and #2027 was merged with the CI, this should happen no more :)
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#709
No description provided.