Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Building a GTK app with 11.0.1 #4052

Closed
GaryElshaw opened this issue Jul 6, 2024 · 10 comments
Closed

Building a GTK app with 11.0.1 #4052

GaryElshaw opened this issue Jul 6, 2024 · 10 comments

Comments

@GaryElshaw
Copy link

All of the various Transmission clients are compiling fine with the exception of GTK. Any help would be appreciated.

image

@vitaut
Copy link
Contributor

vitaut commented Jul 6, 2024

As the error says, mixing character (code unit) types is disallowed in {fmt}. In this case the format string is a char string and action_name is a Glib::ustring which uses a different code unit type. To fix this you'll need provide conversion from one to the other or a formatter that does the conversion.

@GaryElshaw
Copy link
Author

Is there a change i can report back to the team for future reference? All previous versions of fmt have been working fine.

@vitaut vitaut reopened this Jul 6, 2024
@vitaut
Copy link
Contributor

vitaut commented Jul 6, 2024

Reopening to investigate further since it worked in an earlier version. Could you provide a repro?

@vitaut
Copy link
Contributor

vitaut commented Jul 6, 2024

I managed to repro the issue: https://www.godbolt.org/z/cqdMPn6aP. The problem is that ustring is incorrectly detected as as std::string.

@Coeur
Copy link

Coeur commented Jul 6, 2024

Testing commit by commit, the build regression came exactly with 800a0bb by Viktor Zverovich on January 4, 2024.

@GaryElshaw
Copy link
Author

@vitaut Is this a change you think Transmission needs to address, or something for fmt to look at?

@vitaut
Copy link
Contributor

vitaut commented Jul 6, 2024

It's a bug in {fmt}, we shouldn't treat ustring as std::string. I'll submit a fix.

@GaryElshaw
Copy link
Author

Thank you!

@vitaut
Copy link
Contributor

vitaut commented Jul 6, 2024

Should be fixed in 7a8b54a. Could you verify it?

@Coeur
Copy link

Coeur commented Jul 6, 2024

Verified successful. Thank you. Sorry for only pointing this out after the 11.0.1 release instead of before.

@vitaut vitaut closed this as completed Jul 6, 2024
mtremer pushed a commit to ipfire/ipfire-2.x that referenced this issue Aug 15, 2024
- Update from version 11.0.1 to 11.0.2
- Update of rootfile
- Changelog
    11.0.2
	- Fixed compatibility with non-POSIX systems
	  (fmtlib/fmt#4054,
	  fmtlib/fmt#4060).
	- Fixed performance regressions when using `std::back_insert_iterator` with
	  `fmt::format_to` (fmtlib/fmt#4070).
	- Fixed handling of `std::generator` and move-only iterators
	  (fmtlib/fmt#4053,
	  fmtlib/fmt#4057). Thanks @Arghnews.
	- Made `formatter<std::string_view>::parse` work with types convertible to
	  `std::string_view` (fmtlib/fmt#4036,
	  fmtlib/fmt#4055). Thanks @Arghnews.
	- Made `volatile void*` formattable
	  (fmtlib/fmt#4049,
	  fmtlib/fmt#4056). Thanks @Arghnews.
	- Made `Glib::ustring` not be confused with `std::string`
	  (fmtlib/fmt#4052).
	- Made `fmt::context` iterator compatible with STL algorithms that rely on
	  iterator category (fmtlib/fmt#4079).

Signed-off-by: Adolf Belka <adolf.belka@ipfire.org>
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants