** Changed in: libvoikko (Ubuntu)
Status: New => In Progress
** Changed in: libvoikko (Ubuntu)
Importance: Undecided => Medium
** Changed in: libvoikko (Ubuntu)
Assignee: (unassigned) => Alessandro Astone (aleasto)
** Changed in: libvoikko (Ubuntu)
Milestone: None => ubuntu-25.04
--
You received this bug notification because you are a member of Desktop
Packages, which is subscribed to libvoikko in Ubuntu.
https://bugs.launchpad.net/bugs/2104913
Title:
libvoikko violates C++ ODR rule making it fail to compile witih LTO
Status in libvoikko package in Ubuntu:
In Progress
Bug description:
As reported upstream: https://github.com/voikko/corevoikko/issues/62
The public header voikko.h declares some opaque data types, such as
struct VoikkoGrammarError, struct VoikkoHandle, struct
voikko_mor_analysis.
In the implementations however, the type names are under namespaces,
or even use different names.
Here's one example error from gcc 14.2.0 and CXXFLAGS="-flto=auto":
./voikko.h:309:6: error: 'voikkoFreeGrammarError' violates the C++ One
Definition Rule [-Werror=odr]
309 | void voikkoFreeGrammarError(struct VoikkoGrammarError * error);
| ^
grammar/interface.cpp:116:19: note: type mismatch in parameter 1
116 | VOIKKOEXPORT void voikkoFreeGrammarError(VoikkoGrammarError * error) {
| ^
./grammar/VoikkoGrammarError.hpp:40:7: note: type name
'libvoikko::grammar::VoikkoGrammarError' should match type name
'VoikkoGrammarError'
40 | class VoikkoGrammarError {
| ^
./voikko.h:242:8: note: the incompatible type is defined here
242 | struct VoikkoGrammarError;
| ^
grammar/interface.cpp:116:19: note: 'voikkoFreeGrammarError' was previously
declared here
116 | VOIKKOEXPORT void voikkoFreeGrammarError(VoikkoGrammarError * error) {
| ^
https://launchpadlibrarian.net/783617753/buildlog_ubuntu-plucky-
amd64.libvoikko_4.3.2-1build1_BUILDING.txt.gz
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/libvoikko/+bug/2104913/+subscriptions
--
Mailing list: https://launchpad.net/~desktop-packages
Post to : [email protected]
Unsubscribe : https://launchpad.net/~desktop-packages
More help : https://help.launchpad.net/ListHelp