[GH-ISSUE #845] [Linux] Failing to compile on Arch after imgui implementation #231

Closed
opened 2026-02-27 21:05:16 +03:00 by kerem · 3 comments
Owner

Originally created by @Caliel666 on GitHub (Sep 8, 2024).
Original GitHub issue: https://github.com/shadps4-emu/shadPS4/issues/845

using
cmake -S . -B build/ -DENABLE_QT_GUI=ON
cmake --build . --parallel$(nproc)

/shadPS4/src/imgui/renderer/imgui_core.cpp: In function ‘void ImGui::Core::Render(const vk::CommandBuffer&, Vulkan::Frame*)’:
/shadPS4/src/imgui/renderer/imgui_core.cpp:189:5: error: ambiguous overload for ‘operator=(operand types are ‘vk::Rect2D’ and ‘<brace-enclosed initializer list>’)
  189 |     };
      |     ^
In file included from /usr/include/vulkan/vulkan.hpp:8579,
                 from /shadPS4/src/video_core/renderer_vulkan/vk_common.h:17,
                 from /shadPS4/src/video_core/renderer_vulkan/vk_platform.h:11,
                 from /shadPS4/src/video_core/renderer_vulkan/vk_instance.h:9,
                 from /shadPS4/src/imgui/renderer/imgui_core.h:6,
                 from /shadPS4/src/imgui/renderer/imgui_core.cpp:9:
/usr/include/vulkan/vulkan_structs.hpp:8142:14: note: candidate: ‘vk::Rect2D& vk::Rect2D::operator=(const VkRect2D&)8142 |     Rect2D & operator=( VkRect2D const & rhs ) VULKAN_HPP_NOEXCEPT
      |              ^~~~~~~~
/usr/include/vulkan/vulkan_structs.hpp:8124:10: note: candidate: ‘constexpr vk::Rect2D& vk::Rect2D::operator=(const vk::Rect2D&)8124 |   struct Rect2D
      |          ^~~~~~
/usr/include/vulkan/vulkan_structs.hpp:8124:10: note: candidate: ‘constexpr vk::Rect2D& vk::Rect2D::operator=(vk::Rect2D&&)’
make[2]: *** [CMakeFiles/shadps4.dir/build.make:289: CMakeFiles/shadps4.dir/src/imgui/renderer/imgui_core.cpp.o] Error 1
make[2]: *** Waiting for unfinished jobs....
make[1]: *** [CMakeFiles/Makefile2:247: CMakeFiles/shadps4.dir/all] Error 2
make: *** [Makefile:136: all] Error 2

i made sure to update my system and install imgui from the AUR just in case

a bit unrelated but it also throws this warning

In file included from /shadPS4/externals/dear_imgui/imgui.h:64,
                 from /shadPS4/src/imgui/renderer/imgui_core.cpp:5:
/shadPS4/src/imgui/imgui_config.h:28:100: warning: backslash-newline at end of file
   28 | #define IM_VEC2_CLASS_EXTRA
Originally created by @Caliel666 on GitHub (Sep 8, 2024). Original GitHub issue: https://github.com/shadps4-emu/shadPS4/issues/845 using `cmake -S . -B build/ -DENABLE_QT_GUI=ON` `cmake --build . --parallel$(nproc)` ```shell /shadPS4/src/imgui/renderer/imgui_core.cpp: In function ‘void ImGui::Core::Render(const vk::CommandBuffer&, Vulkan::Frame*)’: /shadPS4/src/imgui/renderer/imgui_core.cpp:189:5: error: ambiguous overload for ‘operator=’ (operand types are ‘vk::Rect2D’ and ‘<brace-enclosed initializer list>’) 189 | }; | ^ In file included from /usr/include/vulkan/vulkan.hpp:8579, from /shadPS4/src/video_core/renderer_vulkan/vk_common.h:17, from /shadPS4/src/video_core/renderer_vulkan/vk_platform.h:11, from /shadPS4/src/video_core/renderer_vulkan/vk_instance.h:9, from /shadPS4/src/imgui/renderer/imgui_core.h:6, from /shadPS4/src/imgui/renderer/imgui_core.cpp:9: /usr/include/vulkan/vulkan_structs.hpp:8142:14: note: candidate: ‘vk::Rect2D& vk::Rect2D::operator=(const VkRect2D&)’ 8142 | Rect2D & operator=( VkRect2D const & rhs ) VULKAN_HPP_NOEXCEPT | ^~~~~~~~ /usr/include/vulkan/vulkan_structs.hpp:8124:10: note: candidate: ‘constexpr vk::Rect2D& vk::Rect2D::operator=(const vk::Rect2D&)’ 8124 | struct Rect2D | ^~~~~~ /usr/include/vulkan/vulkan_structs.hpp:8124:10: note: candidate: ‘constexpr vk::Rect2D& vk::Rect2D::operator=(vk::Rect2D&&)’ make[2]: *** [CMakeFiles/shadps4.dir/build.make:289: CMakeFiles/shadps4.dir/src/imgui/renderer/imgui_core.cpp.o] Error 1 make[2]: *** Waiting for unfinished jobs.... make[1]: *** [CMakeFiles/Makefile2:247: CMakeFiles/shadps4.dir/all] Error 2 make: *** [Makefile:136: all] Error 2 ``` i made sure to update my system and install imgui from the AUR just in case a bit unrelated but it also throws this warning ```shell In file included from /shadPS4/externals/dear_imgui/imgui.h:64, from /shadPS4/src/imgui/renderer/imgui_core.cpp:5: /shadPS4/src/imgui/imgui_config.h:28:100: warning: backslash-newline at end of file 28 | #define IM_VEC2_CLASS_EXTRA ```
kerem closed this issue 2026-02-27 21:05:16 +03:00
Author
Owner

@excited-bore commented on GitHub (Sep 8, 2024):

Same problem over here on manjaro
Could be related to older version of vulkan headers? (saw that shadps4 AUR package required vulkanheaders =<1:1.3.289
Currently only
vulkan-headers 1:1.3.285-1 on extra
vulkan-headers-git 1.3.288.r6.ge3c37e6-1 on AUR
are available from official/user repos)

<!-- gh-comment-id:2336843107 --> @excited-bore commented on GitHub (Sep 8, 2024): Same problem over here on manjaro Could be related to older version of vulkan headers? (saw that shadps4 AUR package required vulkanheaders =<1:1.3.289 Currently only vulkan-headers 1:1.3.285-1 on extra vulkan-headers-git 1.3.288.r6.ge3c37e6-1 on AUR are available from official/user repos)
Author
Owner

@Caliel666 commented on GitHub (Sep 8, 2024):

nah, that pr fixes the issue, and manjaro has older packages, 1.3.295 is on arch extra

<!-- gh-comment-id:2336843446 --> @Caliel666 commented on GitHub (Sep 8, 2024): nah, that pr fixes the issue, and manjaro has older packages, 1.3.295 is on arch extra
Author
Owner

@abouvier commented on GitHub (Sep 8, 2024):

vulkan-headers-git 1.3.288.r6.ge3c37e6-1 on AUR

-git packages are always on the last commit, you just have to build them.

<!-- gh-comment-id:2336844965 --> @abouvier commented on GitHub (Sep 8, 2024): > vulkan-headers-git 1.3.288.r6.ge3c37e6-1 on AUR `-git` packages are always on the last commit, you just have to build them.
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#231
No description provided.