Skip to content

reef: Fix FTBFS on gcc 13#52119

Merged
yuriw merged 3 commits intoceph:reeffrom
cbodley:wip-61380-reef
Jun 23, 2023
Merged

reef: Fix FTBFS on gcc 13#52119
yuriw merged 3 commits intoceph:reeffrom
cbodley:wip-61380-reef

Conversation

@cbodley
Copy link
Copy Markdown
Contributor

@cbodley cbodley commented Jun 19, 2023

backport tracker: https://tracker.ceph.com/issues/61380


backport of #50438
parent tracker: https://tracker.ceph.com/issues/58477

this backport was staged using ceph-backport.sh version 16.0.0.6848
find the latest version at https://github.com/ceph/ceph/blob/main/src/script/ceph-backport.sh

tserong added 2 commits June 19, 2023 14:51
This is based on 0024-gcc-13.patch from https://tracker.ceph.com/issues/58477
but with an extra #include <cstdint> to avoid dropping std:: prefixes on
integer types.

Fixes: https://tracker.ceph.com/issues/58477
Signed-off-by: Tim Serong <tserong@suse.com>
(cherry picked from commit 796ce63)
Without this the build will fail on gcc 13 with errors like:

src/osd/scrubber/scrub_backend.cc:1309:14: error: call of overloaded 'format_to(std::back_insert_iterator<fmt::v9::basic_memory_buffer<char> >, const char [35], const char*, const uint64_t&, const uint64_t&, pg_shard_t&)' is ambiguous
  1309 |     format_to(std::back_inserter(out),
       |     ~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~
  1310 |               "{}size {} != size {} from shard {}",
       |               ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  1311 |               sep(error),
       |               ~~~~~~~~~~~
  1312 |               candidate.size,
       |               ~~~~~~~~~~~~~~~
  1313 |               auth.size,
       |               ~~~~~~~~~~
  1314 |               auth_shard);
       |               ~~~~~~~~~~~
 /usr/include/fmt/core.h:3233:17: note: candidate: 'OutputIt fmt::v9::format_to(OutputIt, format_string<T ...>, T&& ...) [with OutputIt = std::back_insert_iterator<basic_memory_buffer<char> >; T = {const char*, const long unsigned int&, const long unsigned int&, pg_shard_t&}; typename std::enable_if<detail::is_output_iterator<OutputIt, char>::value, int>::type <anonymous> = 0; format_string<T ...> = basic_format_string<char, const char*, const long unsigned int&, const long unsigned int&, pg_shard_t&>]'
 3233 | FMT_INLINE auto format_to(OutputIt out, format_string<T...> fmt, T&&... args)
      |                 ^~~~~~~~~
 /usr/include/c++/13/format:3761:5: note: candidate: '_Out std::format_to(_Out, format_string<_Args ...>, _Args&& ...) [with _Out = back_insert_iterator<fmt::v9::basic_memory_buffer<char> >; _Args = {const char*, const long unsigned int&, const long unsigned int&, pg_shard_t&}; format_string<_Args ...> = basic_format_string<char, const char*, const long unsigned int&, const long unsigned int&, pg_shard_t&>]'
  3761 |     format_to(_Out __out, format_string<_Args...> __fmt, _Args&&... __args)
       |     ^~~~~~~~~

Fixes: https://tracker.ceph.com/issues/58477
Signed-off-by: Tim Serong <tserong@suse.com>
(cherry picked from commit 1ae8eb6)
@cbodley cbodley requested review from a team as code owners June 19, 2023 18:51
@cbodley cbodley added this to the reef milestone Jun 19, 2023
Signed-off-by: Casey Bodley <cbodley@redhat.com>
(cherry picked from commit 87cd542)
@cbodley
Copy link
Copy Markdown
Contributor Author

cbodley commented Jun 19, 2023

@rzarzynski note that this includes the rocksdb submodule update from #51737 in addition to the commits from #50438

https://tracker.ceph.com/issues/58477 is also tagged for quincy backport, but i'm not planning to touch rocksdb there

@idryomov
Copy link
Copy Markdown
Contributor

https://tracker.ceph.com/issues/58477 is also tagged for quincy backport, but i'm not planning to touch rocksdb there

@cbodley I see that it was me who tagged it for quincy backport and I think I did that based on

ceph-17.2.5 fails to build without the attached patch

in the description of the tracker. Does that not concern rocksdb in case of quincy?

Copy link
Copy Markdown
Contributor

@idryomov idryomov left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM but if we are including #51737 here I'm missing a reason for not including it in the quincy PR too. From a quick look, both rockdb fixups would apply on ceph-quincy-v6.15.5-1 cleanly (it seems like the submodule hasn't been rolled forward in quincy to include ceph/rocksdb#43 either BTW).

Need @rzarzynski to weigh in here.

bazaah added a commit to bazaah/aur-ceph that referenced this pull request Jun 23, 2023
bazaah added a commit to bazaah/aur-ceph that referenced this pull request Jun 23, 2023
Note we fixed the rocksdb paths for ceph:

  s|([ab]/)|$1src/rocksdb/|g

Upstream-ref: ceph/ceph#52119
Upstream-ref: ceph/rocksdb#44
@yuriw yuriw merged commit 0be7852 into ceph:reef Jun 23, 2023
@bazaah bazaah mentioned this pull request Jun 23, 2023
16 tasks
bazaah added a commit to bazaah/aur-ceph that referenced this pull request Jul 3, 2023
Note we fixed the rocksdb paths for ceph:

  s|([ab]/)|$1src/rocksdb/|g

Upstream-ref: ceph/ceph#52119
Upstream-ref: ceph/rocksdb#44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants