"Undefined reference" errors in building FileZilla

Moderator: Project members

Post Reply
Message
Author
test
500 Command not understood
Posts: 3
Joined: 2020-03-24 06:36

"Undefined reference" errors in building FileZilla

#1 Post by test » 2020-03-26 13:14

I am trying to compile FileZilla3 in my Windows system by following https://wiki.filezilla-project.org/Comp ... er_Windows

These are the steps to be followed in the MSys2 terminal:

Code: Select all

cd ~/filezilla
autoreconf -i
./configure --with-pugixml=builtin
make
make install
I have successfully done the first 3 steps

On executing "make" command, I get many "undefined reference" errors as follows:
(Portion of output on "make")

Code: Select all

C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/9.3.0/../../../../x86_64-w64-mingw32/bin/ld.exe: filezilla-dndobjects.o: in function `CShellExtensionInterface::CShellExtensionInterface()':
C:\Users\...\filezilla\src\interface/dndobjects.cpp:104: undefined reference to `__imp_CoCreateInstance'
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/9.3.0/../../../../x86_64-w64-mingw32/bin/ld.exe: filezilla-dndobjects.o: in function `CShellExtensionInterface::~CShellExtensionInterface()':
C:\Users\...\filezilla\src\interface/dndobjects.cpp:125: undefined reference to `__imp_CoFreeUnusedLibraries'
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/9.3.0/../../../../x86_64-w64-mingw32/bin/ld.exe: filezilla-file_utils.o: in function `GetDownloadDir()':
C:\Users\...\filezilla\src\interface/file_utils.cpp:391: undefined reference to `__imp_CoTaskMemFree'
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/9.3.0/../../../../x86_64-w64-mingw32/bin/ld.exe: filezilla-LocalListView.o: in function `CLocalListView::DisplayShares(wxString)':
C:\Users\...\filezilla\src\interface/LocalListView.cpp:680: undefined reference to `NetShareEnum'
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/9.3.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:\Users\...\filezilla\src\interface/LocalListView.cpp:706: undefined reference to `NetApiBufferFree'
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/9.3.0/../../../../x86_64-w64-mingw32/bin/ld.exe: filezilla-LocalTreeView.o: in function `CLocalTreeView::GetSpecialFolder(int, int&, int&)':
C:\Users\...\filezilla\src\interface/LocalTreeView.cpp:1008: undefined reference to `__imp_CoTaskMemFree'
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/9.3.0/../../../../x86_64-w64-mingw32/bin/ld.exe: filezilla-QueueView.o: in function `CQueueView::ActionAfter(bool)':
C:\Users\...\filezilla\src\interface/QueueView.cpp:2758: undefined reference to `SetSuspendState'
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/9.3.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:\Users\...\filezilla\src\interface/QueueView.cpp:2758: undefined reference to `SetSuspendState'
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/9.3.0/../../../../x86_64-w64-mingw32/bin/ld.exe: filezilla-volume_enumerator.o: in function `CVolumeDescriptionEnumeratorThread::GetDriveLabel(std::__cxx11::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> > const&)':
C:\Users\...\filezilla\src\interface/volume_enumerator.cpp:75: undefined reference to `WNetGetConnectionW'
collect2.exe: error: ld returned 1 exit status
make[4]: *** [Makefile:1106: filezilla.exe] Error 1
make[4]: Leaving directory '/c/Users/.../filezilla/src/interface'
I don't know how to resolve this.

Thanks

User avatar
botg
Site Admin
Posts: 32700
Joined: 2004-02-23 20:49
First name: Tim
Last name: Kosse
Contact:

Re: "Undefined reference" errors in building FileZilla

#2 Post by botg » 2020-03-27 08:09

Unfortunately the log is incomplete.

test
500 Command not understood
Posts: 3
Joined: 2020-03-24 06:36

Re: "Undefined reference" errors in building FileZilla

#3 Post by test » 2020-03-27 19:28

Hello

Please find the complete log after executing "make" as follows:

Code: Select all

Making all in .
make[1]: Entering directory '/c/Users/.../filezilla'
make[1]: Nothing to be done for 'all-am'.
make[1]: Leaving directory '/c/Users/.../filezilla'
Making all in src
make[1]: Entering directory '/c/Users/.../filezilla/src'
Making all in include
make[2]: Entering directory '/c/Users/.../filezilla/src/include'
make  all-am
make[3]: Entering directory '/c/Users/.../filezilla/src/include'
make[3]: Leaving directory '/c/Users/.../filezilla/src/include'
make[2]: Leaving directory '/c/Users/.../filezilla/src/include'
Making all in engine
make[2]: Entering directory '/c/Users/.../filezilla/src/engine'
make  all-am
make[3]: Entering directory '/c/Users/.../filezilla/src/engine'
make[3]: Nothing to be done for 'all-am'.
make[3]: Leaving directory '/c/Users/.../filezilla/src/engine'
make[2]: Leaving directory '/c/Users/.../filezilla/src/engine'
Making all in pugixml
make[2]: Entering directory '/c/Users/.../filezilla/src/pugixml'
make[2]: Nothing to be done for 'all'.
make[2]: Leaving directory '/c/Users/.../filezilla/src/pugixml'
Making all in interface
make[2]: Entering directory '/c/Users/.../filezilla/src/interface'
make  all-recursive
make[3]: Entering directory '/c/Users/.../filezilla/src/interface'
Making all in resources
make[4]: Entering directory '/c/Users/.../filezilla/src/interface/resources'
Making all in blukis
make[5]: Entering directory '/c/Users/.../filezilla/src/interface/resources/blukis'
make[5]: Nothing to be done for 'all'.
make[5]: Leaving directory '/c/Users/.../filezilla/src/interface/resources/blukis'
Making all in classic
make[5]: Entering directory '/c/Users/.../filezilla/src/interface/resources/classic'
make[5]: Nothing to be done for 'all'.
make[5]: Leaving directory '/c/Users/.../filezilla/src/interface/resources/classic'
Making all in cyril
make[5]: Entering directory '/c/Users/.../filezilla/src/interface/resources/cyril'
Making all in 16x16
make[6]: Entering directory '/c/Users/.../filezilla/src/interface/resources/cyril/16x16'
make[6]: Nothing to be done for 'all'.
make[6]: Leaving directory '/c/Users/.../filezilla/src/interface/resources/cyril/16x16'
make[6]: Entering directory '/c/Users/.../filezilla/src/interface/resources/cyril'
make[6]: Nothing to be done for 'all-am'.
make[6]: Leaving directory '/c/Users/.../filezilla/src/interface/resources/cyril'
make[5]: Leaving directory '/c/Users/.../filezilla/src/interface/resources/cyril'
Making all in default
make[5]: Entering directory '/c/Users/.../filezilla/src/interface/resources/default'
make[5]: Nothing to be done for 'all'.
make[5]: Leaving directory '/c/Users/.../filezilla/src/interface/resources/default'
Making all in flatzilla
make[5]: Entering directory '/c/Users/.../filezilla/src/interface/resources/flatzilla'
make[5]: Nothing to be done for 'all'.
make[5]: Leaving directory '/c/Users/.../filezilla/src/interface/resources/flatzilla'
Making all in lone
make[5]: Entering directory '/c/Users/.../filezilla/src/interface/resources/lone'
make[5]: Nothing to be done for 'all'.
make[5]: Leaving directory '/c/Users/.../filezilla/src/interface/resources/lone'
Making all in minimal
make[5]: Entering directory '/c/Users/.../filezilla/src/interface/resources/minimal'
make[5]: Nothing to be done for 'all'.
make[5]: Leaving directory '/c/Users/.../filezilla/src/interface/resources/minimal'
Making all in opencrystal
make[5]: Entering directory '/c/Users/.../filezilla/src/interface/resources/opencrystal'
make[5]: Nothing to be done for 'all'.
make[5]: Leaving directory '/c/Users/.../filezilla/src/interface/resources/opencrystal'
Making all in sun
make[5]: Entering directory '/c/Users/.../filezilla/src/interface/resources/sun'
make[5]: Nothing to be done for 'all'.
make[5]: Leaving directory '/c/Users/.../filezilla/src/interface/resources/sun'
Making all in tango
make[5]: Entering directory '/c/Users/.../filezilla/src/interface/resources/tango'
make[5]: Nothing to be done for 'all'.
make[5]: Leaving directory '/c/Users/.../filezilla/src/interface/resources/tango'
make[5]: Entering directory '/c/Users/.../filezilla/src/interface/resources'
make[5]: Nothing to be done for 'all-am'.
make[5]: Leaving directory '/c/Users/.../filezilla/src/interface/resources'
make[4]: Leaving directory '/c/Users/.../filezilla/src/interface/resources'
Making all in .
make[4]: Entering directory '/c/Users/.../filezilla/src/interface'
/bin/sh ../../libtool  --tag=CXX   --mode=link g++ -std=c++17 -I/c/Users/.../prefix/lib/wx/include/msw-unicode-3.0 -I/c/Users/.../prefix/include/wx-3.0 -D_FILE_OFFSET_BITS=64 -DWXUSINGDLL -D__WXMSW__ -g -O2 -Wall ../engine/libengine.a -LC:/Users/.../prefix/lib -lfilezilla -lws2_32 ../../src/pugixml/libpugixml.a  -L/c/Users/.../prefix/lib   -Wl,--subsystem,windows -mwindows -lwx_mswu_aui-3.0 -lwx_mswu_xrc-3.0 -lwx_mswu_adv-3.0 -lwx_mswu_core-3.0 -lwx_baseu_xml-3.0 -lwx_baseu-3.0    -LC:/Users/.../prefix/lib -lsqlite3    -Wl,--dynamicbase -Wl,--nxcompat -o filezilla.exe filezilla-aboutdialog.o filezilla-asksavepassworddialog.o filezilla-asyncrequestqueue.o filezilla-aui_notebook_ex.o filezilla-auto_ascii_files.o filezilla-bookmarks_dialog.o filezilla-buildinfo.o filezilla-chmoddialog.o filezilla-clearprivatedata.o filezilla-cmdline.o filezilla-commandqueue.o filezilla-conditionaldialog.o filezilla-context_control.o filezilla-customheightlistctrl.o filezilla-defaultfileexistsdlg.o filezilla-dialogex.o filezilla-dndobjects.o filezilla-dragdropmanager.o filezilla-drop_target_ex.o filezilla-edithandler.o filezilla-encoding_converter.o filezilla-export.o filezilla-fileexistsdlg.o filezilla-filelistctrl.o filezilla-filelist_statusbar.o filezilla-FileZilla.o filezilla-filter.o filezilla-filter_conditions_dialog.o filezilla-filteredit.o filezilla-file_utils.o filezilla-fzputtygen_interface.o filezilla-graphics.o filezilla-import.o filezilla-inputdialog.o filezilla-ipcmutex.o filezilla-led.o filezilla-listctrlex.o filezilla-listingcomparison.o filezilla-list_search_panel.o filezilla-local_recursive_operation.o filezilla-locale_initializer.o filezilla-LocalListView.o filezilla-LocalTreeView.o filezilla-loginmanager.o filezilla-Mainfrm.o filezilla-manual_transfer.o filezilla-menu_bar.o filezilla-msgbox.o filezilla-netconfwizard.o filezilla-Options.o filezilla-power_management.o filezilla-queue.o filezilla-queue_storage.o filezilla-QueueView.o filezilla-queueview_failed.o filezilla-queueview_successful.o filezilla-quickconnectbar.o filezilla-recentserverlist.o filezilla-recursive_operation.o filezilla-recursive_operation_status.o filezilla-remote_recursive_operation.o filezilla-RemoteListView.o filezilla-RemoteTreeView.o filezilla-search.o filezilla-serverdata.o settings/filezilla-optionspage.o settings/filezilla-optionspage_connection.o settings/filezilla-optionspage_connection_active.o settings/filezilla-optionspage_connection_ftp.o settings/filezilla-optionspage_connection_passive.o settings/filezilla-optionspage_connection_sftp.o settings/filezilla-optionspage_dateformatting.o settings/filezilla-optionspage_debug.o settings/filezilla-optionspage_edit.o settings/filezilla-optionspage_edit_associations.o settings/filezilla-optionspage_fileexists.o settings/filezilla-optionspage_filelists.o settings/filezilla-optionspage_filetype.o settings/filezilla-optionspage_ftpproxy.o settings/filezilla-optionspage_interface.o settings/filezilla-optionspage_language.o settings/filezilla-optionspage_logging.o settings/filezilla-optionspage_passwords.o settings/filezilla-optionspage_proxy.o settings/filezilla-optionspage_sizeformatting.o settings/filezilla-optionspage_themes.o settings/filezilla-optionspage_transfer.o settings/filezilla-optionspage_updatecheck.o settings/filezilla-settingsdialog.o filezilla-sftp_crypt_info_dlg.o filezilla-sitemanager.o filezilla-sitemanager_dialog.o filezilla-sitemanager_site.o filezilla-sizeformatting.o filezilla-speedlimits_dialog.o filezilla-splitter.o filezilla-state.o filezilla-statusbar.o filezilla-statuslinectrl.o filezilla-StatusView.o filezilla-systemimagelist.o filezilla-textctrlex.o filezilla-themeprovider.o filezilla-timeformatting.o filezilla-toolbar.o filezilla-treectrlex.o filezilla-updater.o filezilla-update_dialog.o filezilla-verifycertdialog.o filezilla-verifyhostkeydialog.o filezilla-view.o filezilla-viewheader.o filezilla-volume_enumerator.o filezilla-welcome_dialog.o filezilla-window_state_manager.o filezilla-wrapengine.o filezilla-wxfilesystem_blob_handler.o filezilla-xh_text_ex.o filezilla-xmlfunctions.o filezilla-xrc_helper.o filezilla-overlay.o
libtool: link: g++ -std=c++17 -I/c/Users/.../prefix/lib/wx/include/msw-unicode-3.0 -I/c/Users/.../prefix/include/wx-3.0 -D_FILE_OFFSET_BITS=64 -DWXUSINGDLL -D__WXMSW__ -g -O2 -Wall -Wl,--subsystem -Wl,windows -mwindows -Wl,--dynamicbase -Wl,--nxcompat -o .libs/filezilla.exe filezilla-aboutdialog.o filezilla-asksavepassworddialog.o filezilla-asyncrequestqueue.o filezilla-aui_notebook_ex.o filezilla-auto_ascii_files.o filezilla-bookmarks_dialog.o filezilla-buildinfo.o filezilla-chmoddialog.o filezilla-clearprivatedata.o filezilla-cmdline.o filezilla-commandqueue.o filezilla-conditionaldialog.o filezilla-context_control.o filezilla-customheightlistctrl.o filezilla-defaultfileexistsdlg.o filezilla-dialogex.o filezilla-dndobjects.o filezilla-dragdropmanager.o filezilla-drop_target_ex.o filezilla-edithandler.o filezilla-encoding_converter.o filezilla-export.o filezilla-fileexistsdlg.o filezilla-filelistctrl.o filezilla-filelist_statusbar.o filezilla-FileZilla.o filezilla-filter.o filezilla-filter_conditions_dialog.o filezilla-filteredit.o filezilla-file_utils.o filezilla-fzputtygen_interface.o filezilla-graphics.o filezilla-import.o filezilla-inputdialog.o filezilla-ipcmutex.o filezilla-led.o filezilla-listctrlex.o filezilla-listingcomparison.o filezilla-list_search_panel.o filezilla-local_recursive_operation.o filezilla-locale_initializer.o filezilla-LocalListView.o filezilla-LocalTreeView.o filezilla-loginmanager.o filezilla-Mainfrm.o filezilla-manual_transfer.o filezilla-menu_bar.o filezilla-msgbox.o filezilla-netconfwizard.o filezilla-Options.o filezilla-power_management.o filezilla-queue.o filezilla-queue_storage.o filezilla-QueueView.o filezilla-queueview_failed.o filezilla-queueview_successful.o filezilla-quickconnectbar.o filezilla-recentserverlist.o filezilla-recursive_operation.o filezilla-recursive_operation_status.o filezilla-remote_recursive_operation.o filezilla-RemoteListView.o filezilla-RemoteTreeView.o filezilla-search.o filezilla-serverdata.o settings/filezilla-optionspage.o settings/filezilla-optionspage_connection.o settings/filezilla-optionspage_connection_active.o settings/filezilla-optionspage_connection_ftp.o settings/filezilla-optionspage_connection_passive.o settings/filezilla-optionspage_connection_sftp.o settings/filezilla-optionspage_dateformatting.o settings/filezilla-optionspage_debug.o settings/filezilla-optionspage_edit.o settings/filezilla-optionspage_edit_associations.o settings/filezilla-optionspage_fileexists.o settings/filezilla-optionspage_filelists.o settings/filezilla-optionspage_filetype.o settings/filezilla-optionspage_ftpproxy.o settings/filezilla-optionspage_interface.o settings/filezilla-optionspage_language.o settings/filezilla-optionspage_logging.o settings/filezilla-optionspage_passwords.o settings/filezilla-optionspage_proxy.o settings/filezilla-optionspage_sizeformatting.o settings/filezilla-optionspage_themes.o settings/filezilla-optionspage_transfer.o settings/filezilla-optionspage_updatecheck.o settings/filezilla-settingsdialog.o filezilla-sftp_crypt_info_dlg.o filezilla-sitemanager.o filezilla-sitemanager_dialog.o filezilla-sitemanager_site.o filezilla-sizeformatting.o filezilla-speedlimits_dialog.o filezilla-splitter.o filezilla-state.o filezilla-statusbar.o filezilla-statuslinectrl.o filezilla-StatusView.o filezilla-systemimagelist.o filezilla-textctrlex.o filezilla-themeprovider.o filezilla-timeformatting.o filezilla-toolbar.o filezilla-treectrlex.o filezilla-updater.o filezilla-update_dialog.o filezilla-verifycertdialog.o filezilla-verifyhostkeydialog.o filezilla-view.o filezilla-viewheader.o filezilla-volume_enumerator.o filezilla-welcome_dialog.o filezilla-window_state_manager.o filezilla-wrapengine.o filezilla-wxfilesystem_blob_handler.o filezilla-xh_text_ex.o filezilla-xmlfunctions.o filezilla-xrc_helper.o filezilla-overlay.o ../engine/libengine.a -LC:/Users/.../prefix/lib /c/Users/.../prefix/lib/libfilezilla.dll.a -L=C:/Users/.../prefix/lib -L/c/Users/.../prefix/lib -L==C:/Users/.../prefix/lib /c/Users/.../prefix/lib/libgnutls.dll.a -lnettle -lhogweed /c/Users/.../prefix/lib/libgmp.dll.a -lcrypt32 -lintl -lws2_32 ../../src/pugixml/libpugixml.a -lwx_mswu_aui-3.0 -lwx_mswu_xrc-3.0 -lwx_mswu_adv-3.0 -lwx_mswu_core-3.0 -lwx_baseu_xml-3.0 -lwx_baseu-3.0 /c/Users/.../prefix/lib/libsqlite3.dll.a -lz -L/c/Users/.../prefix/lib
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/9.3.0/../../../../x86_64-w64-mingw32/bin/ld.exe: filezilla-dndobjects.o: in function `CShellExtensionInterface::CShellExtensionInterface()':
C:\Users\...\filezilla\src\interface/dndobjects.cpp:104: undefined reference to `__imp_CoCreateInstance'
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/9.3.0/../../../../x86_64-w64-mingw32/bin/ld.exe: filezilla-dndobjects.o: in function `CShellExtensionInterface::~CShellExtensionInterface()':
C:\Users\...\filezilla\src\interface/dndobjects.cpp:125: undefined reference to `__imp_CoFreeUnusedLibraries'
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/9.3.0/../../../../x86_64-w64-mingw32/bin/ld.exe: filezilla-file_utils.o: in function `GetDownloadDir()':
C:\Users\...\filezilla\src\interface/file_utils.cpp:391: undefined reference to `__imp_CoTaskMemFree'
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/9.3.0/../../../../x86_64-w64-mingw32/bin/ld.exe: filezilla-LocalListView.o: in function `CLocalListView::DisplayShares(wxString)':
C:\Users\...\filezilla\src\interface/LocalListView.cpp:680: undefined reference to `NetShareEnum'
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/9.3.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:\Users\...\filezilla\src\interface/LocalListView.cpp:706: undefined reference to `NetApiBufferFree'
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/9.3.0/../../../../x86_64-w64-mingw32/bin/ld.exe: filezilla-LocalTreeView.o: in function `CLocalTreeView::GetSpecialFolder(int, int&, int&)':
C:\Users\...\filezilla\src\interface/LocalTreeView.cpp:1008: undefined reference to `__imp_CoTaskMemFree'
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/9.3.0/../../../../x86_64-w64-mingw32/bin/ld.exe: filezilla-QueueView.o: in function `CQueueView::ActionAfter(bool)':
C:\Users\...\filezilla\src\interface/QueueView.cpp:2758: undefined reference to `SetSuspendState'
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/9.3.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:\Users\...\filezilla\src\interface/QueueView.cpp:2758: undefined reference to `SetSuspendState'
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/9.3.0/../../../../x86_64-w64-mingw32/bin/ld.exe: filezilla-volume_enumerator.o: in function `CVolumeDescriptionEnumeratorThread::GetDriveLabel(std::__cxx11::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> > const&)':
C:\Users\...\filezilla\src\interface/volume_enumerator.cpp:75: undefined reference to `WNetGetConnectionW'
collect2.exe: error: ld returned 1 exit status
make[4]: *** [Makefile:1106: filezilla.exe] Error 1
make[4]: Leaving directory '/c/Users/.../filezilla/src/interface'
make[3]: *** [Makefile:3058: all-recursive] Error 1
make[3]: Leaving directory '/c/Users/.../filezilla/src/interface'
make[2]: *** [Makefile:959: all] Error 2
make[2]: Leaving directory '/c/Users/.../filezilla/src/interface'
make[1]: *** [Makefile:433: all-recursive] Error 1
make[1]: Leaving directory '/c/Users/.../filezilla/src'
make: *** [Makefile:614: all-recursive] Error 1

User avatar
botg
Site Admin
Posts: 32700
Joined: 2004-02-23 20:49
First name: Tim
Last name: Kosse
Contact:

Re: "Undefined reference" errors in building FileZilla

#4 Post by botg » 2020-03-28 13:53

Did you use the wrong shell when running configure? Configure needs be be run from the MinGW-64 shell, not the plain MSys2 one.

Post Reply