Bug 117360

Summary: Missing extern "C" for hspell include
Product: [Unmaintained] kdelibs Reporter: Adam Sampson <ats-kdebugs>
Component: kspellAssignee: Zack Rusin <zack>
Status: RESOLVED FIXED    
Severity: normal CC: doc.evans
Priority: NOR    
Version: unspecified   
Target Milestone: ---   
Platform: Compiled Sources   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:

Description Adam Sampson 2005-11-30 17:20:37 UTC
Version:            (using KDE KDE 3.5.0)
Installed from:    Compiled From Sources
Compiler:          gcc (GCC) 3.4.4 
OS:                Linux

In kspell_hspellclient.h, there's:

#include "hspell.h"

Since hspell is a C library, that causes the hspell plugin to fail to link with a load of unresolved symbol errors. It needs wrapping with extern "C", as kspell_hspelldict.h already does:

extern "C" {
#include "hspell.h"
}
Comment 1 Thiago Macieira 2005-12-06 17:07:17 UTC
SVN commit 486041 by thiago:

Fixing the bug in kspell's hspell plugin. Thanks to Jeff Manson for the patch.

BUG:117329,117722,117360


 M  +3 -0      kspell_hspellclient.h  


--- trunk/KDE/kdelibs/kspell2/plugins/hspell/kspell_hspellclient.h #486040:486041
@@ -25,7 +25,10 @@
 #include "client.h"
 #include <qobject.h>
 
+/* libhspell is a C library and it does not have #ifdef __cplusplus */
+extern "C" {
 #include "hspell.h"
+}
 
 namespace KSpell2 {
     class Dictionary;
Comment 2 John Layt 2009-02-12 23:08:59 UTC
*** Bug 177000 has been marked as a duplicate of this bug. ***