Author Topic: Compiling SpellChecker on linux  (Read 2038 times)

Offline BlueHazzard

  • Developer
  • Lives here!
  • *****
  • Posts: 2454
Re: Compiling SpellChecker on linux
« Reply #15 on: August 29, 2019, 11:50:13 pm »
I do not know why, but now i can not even compile the main project because of link library order:
Code: [Select]
g++ -shared -Ldevel30 .objs30/sdk/configmanager-revision.o .objs30/sdk/annoyingdialog.o .objs30/sdk/autodetectcompilers.o .objs30/sdk/base64.o .objs30/sdk/blockallocated.o .objs30/sdk/cbart_provider.o .objs30/sdk/cbauibook.o .objs30/sdk/cbcolourmanager.o .objs30/sdk/cbdebugger_interfaces.o .objs30/sdk/cbeditor.o .objs30/sdk/cbeditorprintout.o .objs30/sdk/cbexception.o .objs30/sdk/cbplugin.o .objs30/sdk/cbproject.o .objs30/sdk/cbstatusbar.o .objs30/sdk/cbstyledtextctrl.o .objs30/sdk/cbthreadpool.o .objs30/sdk/cbtreectrl.o .objs30/sdk/cbworkspace.o .objs30/sdk/ccmanager.o .objs30/sdk/compileoptionsbase.o .objs30/sdk/compiler.o .objs30/sdk/compilercommandgenerator.o .objs30/sdk/compilerfactory.o .objs30/sdk/compileroptions.o .objs30/sdk/compiletargetbase.o .objs30/sdk/configmanager.o .objs30/sdk/configurationpanel.o .objs30/sdk/configuretoolsdlg.o .objs30/sdk/confirmreplacedlg.o .objs30/sdk/crc32.o .objs30/sdk/debuggermanager.o .objs30/sdk/editarrayfiledlg.o .objs30/sdk/editarrayorderdlg.o .objs30/sdk/editarraystringdlg.o .objs30/sdk/editor_hooks.o .objs30/sdk/editorbase.o .objs30/sdk/editorcolourset.o .objs30/sdk/editorlexerloader.o .objs30/sdk/editormanager.o .objs30/sdk/editpairdlg.o .objs30/sdk/editpathdlg.o .objs30/sdk/edittooldlg.o .objs30/sdk/encodingdetector.o .objs30/sdk/externaldepsdlg.o .objs30/sdk/filefilters.o .objs30/sdk/filegroupsandmasks.o .objs30/sdk/filemanager.o .objs30/sdk/findreplacedlg.o .objs30/sdk/genericmultilinenotesdlg.o .objs30/sdk/globals.o .objs30/sdk/importers_globals.o .objs30/sdk/incremental_select_helper.o .objs30/sdk/infowindow.o .objs30/sdk/loggers.o .objs30/sdk/logmanager.o .objs30/sdk/macrosmanager.o .objs30/sdk/manager.o .objs30/sdk/menuitemsmanager.o .objs30/sdk/mozilla_chardet/src/CharDistribution.o .objs30/sdk/mozilla_chardet/src/JpCntx.o .objs30/sdk/mozilla_chardet/src/LangBulgarianModel.o .objs30/sdk/mozilla_chardet/src/LangCyrillicModel.o .objs30/sdk/mozilla_chardet/src/LangGreekModel.o .objs30/sdk/mozilla_chardet/src/LangHebrewModel.o .objs30/sdk/mozilla_chardet/src/LangHungarianModel.o .objs30/sdk/mozilla_chardet/src/LangThaiModel.o .objs30/sdk/mozilla_chardet/src/nsBig5Prober.o .objs30/sdk/mozilla_chardet/src/nsCharSetProber.o .objs30/sdk/mozilla_chardet/src/nsEscCharsetProber.o .objs30/sdk/mozilla_chardet/src/nsEscSM.o .objs30/sdk/mozilla_chardet/src/nsEUCJPProber.o .objs30/sdk/mozilla_chardet/src/nsEUCKRProber.o .objs30/sdk/mozilla_chardet/src/nsEUCTWProber.o .objs30/sdk/mozilla_chardet/src/nsGB2312Prober.o .objs30/sdk/mozilla_chardet/src/nsHebrewProber.o .objs30/sdk/mozilla_chardet/src/nsLatin1Prober.o .objs30/sdk/mozilla_chardet/src/nsMBCSGroupProber.o .objs30/sdk/mozilla_chardet/src/nsMBCSSM.o .objs30/sdk/mozilla_chardet/src/nsSBCharSetProber.o .objs30/sdk/mozilla_chardet/src/nsSBCSGroupProber.o .objs30/sdk/mozilla_chardet/src/nsSJISProber.o .objs30/sdk/mozilla_chardet/src/nsUniversalDetector.o .objs30/sdk/mozilla_chardet/src/nsUTF8Prober.o .objs30/sdk/multiselectdlg.o .objs30/sdk/newfromtemplatedlg.o .objs30/sdk/personalitymanager.o .objs30/sdk/pipedprocess.o .objs30/sdk/pluginmanager.o .objs30/sdk/pluginsconfigurationdlg.o .objs30/sdk/printing_types.o .objs30/sdk/projectbuildtarget.o .objs30/sdk/projectfile.o .objs30/sdk/projectfileoptionsdlg.o .objs30/sdk/projectlayoutloader.o .objs30/sdk/projectloader.o .objs30/sdk/projectloader_hooks.o .objs30/sdk/projectmanager.o .objs30/sdk/projectsfilemasksdlg.o .objs30/sdk/projecttemplateloader.o .objs30/sdk/scripting/bindings/sc_consts.o .objs30/sdk/scripting/bindings/sc_dialog.o .objs30/sdk/scripting/bindings/sc_globals.o .objs30/sdk/scripting/bindings/sc_io.o .objs30/sdk/scripting/bindings/sc_plugin.o .objs30/sdk/scripting/bindings/sc_progress.o .objs30/sdk/scripting/bindings/sc_util_dialogs.o .objs30/sdk/scripting/bindings/sc_wxtypes.o .objs30/sdk/scripting/bindings/scriptbindings.o .objs30/sdk/scriptingmanager.o .objs30/sdk/scriptsecuritywarningdlg.o .objs30/sdk/scrollingdialog.o .objs30/sdk/sdk_events.o .objs30/sdk/searchresultslog.o .objs30/sdk/selecttargetdlg.o .objs30/sdk/templatemanager.o .objs30/sdk/tinywxuni.o .objs30/sdk/toolsmanager.o .objs30/sdk/uservarmanager.o .objs30/sdk/workspaceloader.o .objs30/sdk/xtra_res.o  -o devel30/libcodeblocks.so -L/usr/lib/x86_64-linux-gnu -pthread   -lwx_gtk2u_aui-3.0 -lwx_gtk2u_propgrid-3.0 -lwx_gtk2u_xrc-3.0 -lwx_gtk2u_html-3.0 -lwx_gtk2u_qa-3.0 -lwx_gtk2u_adv-3.0 -lwx_gtk2u_core-3.0 -lwx_baseu_xml-3.0 -lwx_baseu_net-3.0 -lwx_baseu-3.0  -Wl,--no-undefined -lgdk-x11-2.0 -lpangocairo-1.0 -lpango-1.0 -lcairo -lgdk_pixbuf-2.0 -lgobject-2.0 -lglib-2.0  -ltxml -lsqplus -lsqstdlib -lsquirrel -lwxscintilla_cb
devel30/libwxscintilla_cb.a(ScintillaWX.o): In function `ScintillaWX::DoKeyDown(wxKeyEvent const&, bool*)':
/home/codeblocks/codeblocks/src/sdk/wxscintilla/src/ScintillaWX.cpp:1212: undefined reference to `gdk_display_get_default'
/home/codeblocks/codeblocks/src/sdk/wxscintilla/src/ScintillaWX.cpp:1212: undefined reference to `gdk_keymap_get_for_display'
/home/codeblocks/codeblocks/src/sdk/wxscintilla/src/ScintillaWX.cpp:1215: undefined reference to `gdk_keymap_lookup_key'

obviously -lgdk-x11-2.0 should be after -lwxscintilla_cb

Offline Pecan

  • Plugin developer
  • Lives here!
  • ****
  • Posts: 2165
Re: Compiling SpellChecker on linux
« Reply #16 on: August 30, 2019, 06:55:05 am »
I do not know why, but now i can not even compile the main project because of link library order:
Code: [Select]
g++ -shared -Ldevel30 .objs30/sdk/configmanager-revision.o .objs30/sdk/annoyingdialog.o .objs30/sdk/autodetectcompilers.o .objs30/sdk/base64.o .objs30/sdk/blockallocated.o .objs30/sdk/cbart_provider.o .objs30/sdk/cbauibook.o .objs30/sdk/cbcolourmanager.o .objs30/sdk/cbdebugger_interfaces.o .objs30/sdk/cbeditor.o .objs30/sdk/cbeditorprintout.o .objs30/sdk/cbexception.o .objs30/sdk/cbplugin.o .objs30/sdk/cbproject.o .objs30/sdk/cbstatusbar.o .objs30/sdk/cbstyledtextctrl.o .objs30/sdk/cbthreadpool.o .objs30/sdk/cbtreectrl.o .objs30/sdk/cbworkspace.o .objs30/sdk/ccmanager.o .objs30/sdk/compileoptionsbase.o .objs30/sdk/compiler.o .objs30/sdk/compilercommandgenerator.o .objs30/sdk/compilerfactory.o .objs30/sdk/compileroptions.o .objs30/sdk/compiletargetbase.o .objs30/sdk/configmanager.o .objs30/sdk/configurationpanel.o .objs30/sdk/configuretoolsdlg.o .objs30/sdk/confirmreplacedlg.o .objs30/sdk/crc32.o .objs30/sdk/debuggermanager.o .objs30/sdk/editarrayfiledlg.o .objs30/sdk/editarrayorderdlg.o .objs30/sdk/editarraystringdlg.o .objs30/sdk/editor_hooks.o .objs30/sdk/editorbase.o .objs30/sdk/editorcolourset.o .objs30/sdk/editorlexerloader.o .objs30/sdk/editormanager.o .objs30/sdk/editpairdlg.o .objs30/sdk/editpathdlg.o .objs30/sdk/edittooldlg.o .objs30/sdk/encodingdetector.o .objs30/sdk/externaldepsdlg.o .objs30/sdk/filefilters.o .objs30/sdk/filegroupsandmasks.o .objs30/sdk/filemanager.o .objs30/sdk/findreplacedlg.o .objs30/sdk/genericmultilinenotesdlg.o .objs30/sdk/globals.o .objs30/sdk/importers_globals.o .objs30/sdk/incremental_select_helper.o .objs30/sdk/infowindow.o .objs30/sdk/loggers.o .objs30/sdk/logmanager.o .objs30/sdk/macrosmanager.o .objs30/sdk/manager.o .objs30/sdk/menuitemsmanager.o .objs30/sdk/mozilla_chardet/src/CharDistribution.o .objs30/sdk/mozilla_chardet/src/JpCntx.o .objs30/sdk/mozilla_chardet/src/LangBulgarianModel.o .objs30/sdk/mozilla_chardet/src/LangCyrillicModel.o .objs30/sdk/mozilla_chardet/src/LangGreekModel.o .objs30/sdk/mozilla_chardet/src/LangHebrewModel.o .objs30/sdk/mozilla_chardet/src/LangHungarianModel.o .objs30/sdk/mozilla_chardet/src/LangThaiModel.o .objs30/sdk/mozilla_chardet/src/nsBig5Prober.o .objs30/sdk/mozilla_chardet/src/nsCharSetProber.o .objs30/sdk/mozilla_chardet/src/nsEscCharsetProber.o .objs30/sdk/mozilla_chardet/src/nsEscSM.o .objs30/sdk/mozilla_chardet/src/nsEUCJPProber.o .objs30/sdk/mozilla_chardet/src/nsEUCKRProber.o .objs30/sdk/mozilla_chardet/src/nsEUCTWProber.o .objs30/sdk/mozilla_chardet/src/nsGB2312Prober.o .objs30/sdk/mozilla_chardet/src/nsHebrewProber.o .objs30/sdk/mozilla_chardet/src/nsLatin1Prober.o .objs30/sdk/mozilla_chardet/src/nsMBCSGroupProber.o .objs30/sdk/mozilla_chardet/src/nsMBCSSM.o .objs30/sdk/mozilla_chardet/src/nsSBCharSetProber.o .objs30/sdk/mozilla_chardet/src/nsSBCSGroupProber.o .objs30/sdk/mozilla_chardet/src/nsSJISProber.o .objs30/sdk/mozilla_chardet/src/nsUniversalDetector.o .objs30/sdk/mozilla_chardet/src/nsUTF8Prober.o .objs30/sdk/multiselectdlg.o .objs30/sdk/newfromtemplatedlg.o .objs30/sdk/personalitymanager.o .objs30/sdk/pipedprocess.o .objs30/sdk/pluginmanager.o .objs30/sdk/pluginsconfigurationdlg.o .objs30/sdk/printing_types.o .objs30/sdk/projectbuildtarget.o .objs30/sdk/projectfile.o .objs30/sdk/projectfileoptionsdlg.o .objs30/sdk/projectlayoutloader.o .objs30/sdk/projectloader.o .objs30/sdk/projectloader_hooks.o .objs30/sdk/projectmanager.o .objs30/sdk/projectsfilemasksdlg.o .objs30/sdk/projecttemplateloader.o .objs30/sdk/scripting/bindings/sc_consts.o .objs30/sdk/scripting/bindings/sc_dialog.o .objs30/sdk/scripting/bindings/sc_globals.o .objs30/sdk/scripting/bindings/sc_io.o .objs30/sdk/scripting/bindings/sc_plugin.o .objs30/sdk/scripting/bindings/sc_progress.o .objs30/sdk/scripting/bindings/sc_util_dialogs.o .objs30/sdk/scripting/bindings/sc_wxtypes.o .objs30/sdk/scripting/bindings/scriptbindings.o .objs30/sdk/scriptingmanager.o .objs30/sdk/scriptsecuritywarningdlg.o .objs30/sdk/scrollingdialog.o .objs30/sdk/sdk_events.o .objs30/sdk/searchresultslog.o .objs30/sdk/selecttargetdlg.o .objs30/sdk/templatemanager.o .objs30/sdk/tinywxuni.o .objs30/sdk/toolsmanager.o .objs30/sdk/uservarmanager.o .objs30/sdk/workspaceloader.o .objs30/sdk/xtra_res.o  -o devel30/libcodeblocks.so -L/usr/lib/x86_64-linux-gnu -pthread   -lwx_gtk2u_aui-3.0 -lwx_gtk2u_propgrid-3.0 -lwx_gtk2u_xrc-3.0 -lwx_gtk2u_html-3.0 -lwx_gtk2u_qa-3.0 -lwx_gtk2u_adv-3.0 -lwx_gtk2u_core-3.0 -lwx_baseu_xml-3.0 -lwx_baseu_net-3.0 -lwx_baseu-3.0  -Wl,--no-undefined -lgdk-x11-2.0 -lpangocairo-1.0 -lpango-1.0 -lcairo -lgdk_pixbuf-2.0 -lgobject-2.0 -lglib-2.0  -ltxml -lsqplus -lsqstdlib -lsquirrel -lwxscintilla_cb
devel30/libwxscintilla_cb.a(ScintillaWX.o): In function `ScintillaWX::DoKeyDown(wxKeyEvent const&, bool*)':
/home/codeblocks/codeblocks/src/sdk/wxscintilla/src/ScintillaWX.cpp:1212: undefined reference to `gdk_display_get_default'
/home/codeblocks/codeblocks/src/sdk/wxscintilla/src/ScintillaWX.cpp:1212: undefined reference to `gdk_keymap_get_for_display'
/home/codeblocks/codeblocks/src/sdk/wxscintilla/src/ScintillaWX.cpp:1215: undefined reference to `gdk_keymap_lookup_key'

obviously -lgdk-x11-2.0 should be after -lwxscintilla_cb

See
http://forums.codeblocks.org/index.php/topic,23316.msg159468.html#msg159468

Your link errors look exactly like the above topic, and the suggested solution worked for me.

What happens if you remove wxscintilla from the list of libraries and put -lwxscintilla_cb before the `pkg-config` line? My guess is that this would fix the build.
« Last Edit: August 30, 2019, 07:00:18 am by Pecan »

Offline BlueHazzard

  • Developer
  • Lives here!
  • *****
  • Posts: 2454
Re: Compiling SpellChecker on linux
« Reply #17 on: August 30, 2019, 10:49:51 am »
So you probably hit also the spell checker errors? Why is mint and ubuntu so picky and centos seems to be not... I wanted to try arch, but had not the time to do it...
Anyway i think i will push the changes... After reading the gcc manual, i am pretty sure that the order of libraries is not conform to the gcc behavior and we should fix this..

Offline Pecan

  • Plugin developer
  • Lives here!
  • ****
  • Posts: 2165
Re: Compiling SpellChecker on linux
« Reply #18 on: August 31, 2019, 06:44:57 am »
So you probably hit also the spell checker errors? Why is mint and ubuntu so picky and centos seems to be not... I wanted to try arch, but had not the time to do it...
Anyway i think i will push the changes... After reading the gcc manual, i am pretty sure that the order of libraries is not conform to the gcc behavior and we should fix this..

For me, I don't believe this error has anything to do specifically with SpellChecker. I've never compiled, used or installed it.

Offline oBFusCATed

  • Developer
  • Lives here!
  • *****
  • Posts: 11931
    • Travis build status
Re: Compiling SpellChecker on linux
« Reply #19 on: September 01, 2019, 12:11:24 am »
The linking problems should be fixed in svn...
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]