Home > Software engineering >  Issue with installing Lua-cURL on LuaRocks
Issue with installing Lua-cURL on LuaRocks

Time:03-23

I'm trying to install Lua-cURL on LuaRocks, but get an error.

cURL Version: Windows 64 bit

cURL Download Link: (https://curl.se/windows/dl-7.82.0_1/curl-7.82.0_1-win64-mingw.zip)

Command:

luarocks install lua-curl CURL_DIR=C:\curl-7.82.0_1-win64-mingw

Error:

collect2.exe: error: ld returned 1 exit status

Error: Build error: Failed compiling module lcurl.dll

Command Output:

C:\WINDOWS\system32>luarocks install lua-curl CURL_DIR=C:\curl-7.82.0_1-win64-mingw
Installing https://luarocks.org/lua-curl-0.3.13-1.src.rock

lua-curl 0.3.13-1 depends on lua >= 5.1, < 5.5 (5.1-1 provided by VM)
C:\i686-6.4.0-release-win32-dwarf-rt_v5-rev0\mingw32\bin\gcc.exe -O2 -c -o src/l52util.o -IC:\Program Files (x86)\LuaRocks\include src/l52util.c -IC:\curl-7.82.0_1-win64-mingw/include
C:\i686-6.4.0-release-win32-dwarf-rt_v5-rev0\mingw32\bin\gcc.exe -O2 -c -o src/lceasy.o -IC:\Program Files (x86)\LuaRocks\include src/lceasy.c -IC:\curl-7.82.0_1-win64-mingw/include
C:\i686-6.4.0-release-win32-dwarf-rt_v5-rev0\mingw32\bin\gcc.exe -O2 -c -o src/lcerror.o -IC:\Program Files (x86)\LuaRocks\include src/lcerror.c -IC:\curl-7.82.0_1-win64-mingw/include
C:\i686-6.4.0-release-win32-dwarf-rt_v5-rev0\mingw32\bin\gcc.exe -O2 -c -o src/lchttppost.o -IC:\Program Files (x86)\LuaRocks\include src/lchttppost.c -IC:\curl-7.82.0_1-win64-mingw/include
C:\i686-6.4.0-release-win32-dwarf-rt_v5-rev0\mingw32\bin\gcc.exe -O2 -c -o src/lcurl.o -IC:\Program Files (x86)\LuaRocks\include src/lcurl.c -IC:\curl-7.82.0_1-win64-mingw/include
C:\i686-6.4.0-release-win32-dwarf-rt_v5-rev0\mingw32\bin\gcc.exe -O2 -c -o src/lcutils.o -IC:\Program Files (x86)\LuaRocks\include src/lcutils.c -IC:\curl-7.82.0_1-win64-mingw/include
C:\i686-6.4.0-release-win32-dwarf-rt_v5-rev0\mingw32\bin\gcc.exe -O2 -c -o src/lcmulti.o -IC:\Program Files (x86)\LuaRocks\include src/lcmulti.c -IC:\curl-7.82.0_1-win64-mingw/include
C:\i686-6.4.0-release-win32-dwarf-rt_v5-rev0\mingw32\bin\gcc.exe -O2 -c -o src/lcshare.o -IC:\Program Files (x86)\LuaRocks\include src/lcshare.c -IC:\curl-7.82.0_1-win64-mingw/include
C:\i686-6.4.0-release-win32-dwarf-rt_v5-rev0\mingw32\bin\gcc.exe -O2 -c -o src/lcmime.o -IC:\Program Files (x86)\LuaRocks\include src/lcmime.c -IC:\curl-7.82.0_1-win64-mingw/include
C:\i686-6.4.0-release-win32-dwarf-rt_v5-rev0\mingw32\bin\gcc.exe -O2 -c -o src/lcurlapi.o -IC:\Program Files (x86)\LuaRocks\include src/lcurlapi.c -IC:\curl-7.82.0_1-win64-mingw/include
C:\i686-6.4.0-release-win32-dwarf-rt_v5-rev0\mingw32\bin\gcc.exe -shared -o lcurl.dll src/l52util.o src/lceasy.o src/lcerror.o src/lchttppost.o src/lcurl.o src/lcutils.o src/lcmulti.o src/lcshare.o src/lcmime.o src/lcurlapi.o -LC:\curl-7.82.0_1-win64-mingw/lib -llibcurl -lws2_32 C:\Program Files (x86)\LuaRocks/lua5.1.lib -lMSVCR80
src/lceasy.o:lceasy.c:(.text 0xe2f): undefined reference to `_imp__curl_easy_setopt'
src/lceasy.o:lceasy.c:(.text 0x1ada): undefined reference to `_imp__curl_easy_init'
src/lceasy.o:lceasy.c:(.text 0x1d6d): undefined reference to `_imp__curl_easy_cleanup'
src/lceasy.o:lceasy.c:(.text 0x1de3): undefined reference to `_imp__curl_easy_upkeep'
src/lceasy.o:lceasy.c:(.text 0x1ea2): undefined reference to `_imp__curl_easy_perform'
src/lceasy.o:lceasy.c:(.text 0x1fe0): undefined reference to `_imp__curl_easy_unescape'
src/lceasy.o:lceasy.c:(.text 0x2003): undefined reference to `_imp__curl_free'
src/lceasy.o:lceasy.c:(.text 0x2088): undefined reference to `_imp__curl_easy_escape'
src/lceasy.o:lceasy.c:(.text 0x20a3): undefined reference to `_imp__curl_free'
src/lceasy.o:lceasy.c:(.text 0x2103): undefined reference to `_imp__curl_easy_reset'
src/lceasy.o:lceasy.c:(.text 0x2196): undefined reference to `_imp__curl_easy_pause'
src/lceasy.o:lceasy.c:(.text 0x2270): undefined reference to `_imp__curl_easy_getinfo'
src/lceasy.o:lceasy.c:(.text 0x2450): undefined reference to `_imp__curl_easy_getinfo'
src/lceasy.o:lceasy.c:(.text 0x2560): undefined reference to `_imp__curl_easy_getinfo'
src/lceasy.o:lceasy.c:(.text 0x26e0): undefined reference to `_imp__curl_easy_getinfo'
src/lceasy.o:lceasy.c:(.text 0x2701): undefined reference to `_imp__curl_slist_free_all'
src/lceasy.o:lceasy.c:(.text 0x2790): undefined reference to `_imp__curl_easy_getinfo'
src/lceasy.o:lceasy.c:(.text 0x28e1): undefined reference to `_imp__curl_easy_setopt'
src/lceasy.o:lceasy.c:(.text 0x29d3): undefined reference to `_imp__curl_easy_setopt'
src/lceasy.o:lceasy.c:(.text 0x2a73): undefined reference to `_imp__curl_easy_setopt'
src/lceasy.o:lceasy.c:(.text 0x2b13): undefined reference to `_imp__curl_easy_setopt'
src/lceasy.o:lceasy.c:(.text 0x2bb3): undefined reference to `_imp__curl_easy_setopt'
src/lceasy.o:lceasy.c:(.text 0x2c51): more undefined references to `_imp__curl_easy_setopt' follow
src/lceasy.o:lceasy.c:(.text 0x49a4): undefined reference to `_imp__curl_slist_free_all'
src/lceasy.o:lceasy.c:(.text 0x4ba1): undefined reference to `_imp__curl_easy_setopt'
src/lceasy.o:lceasy.c:(.text 0x4c54): undefined reference to `_imp__curl_easy_setopt'
src/lceasy.o:lceasy.c:(.text 0x4d0f): undefined reference to `_imp__curl_easy_setopt'
src/lceasy.o:lceasy.c:(.text 0x4fe4): undefined reference to `_imp__curl_easy_setopt'
src/lceasy.o:lceasy.c:(.text 0x5141): undefined reference to `_imp__curl_easy_setopt'
src/lceasy.o:lceasy.c:(.text 0x51ec): more undefined references to `_imp__curl_easy_setopt' follow
src/lceasy.o:lceasy.c:(.text 0x5e1f): undefined reference to `_imp__curl_slist_free_all'
src/lceasy.o:lceasy.c:(.text 0x5e3e): undefined reference to `_imp__curl_easy_setopt'
src/lceasy.o:lceasy.c:(.text 0x5e89): undefined reference to `_imp__curl_slist_free_all'
src/lceasy.o:lceasy.c:(.text 0x6077): undefined reference to `_imp__curl_easy_getinfo'
src/lceasy.o:lceasy.c:(.text 0x68e9): undefined reference to `_imp__curl_easy_setopt'
src/lceasy.o:lceasy.c:(.text 0x898d): undefined reference to `_imp__curl_easy_setopt'
src/lceasy.o:lceasy.c:(.text 0x8fae): undefined reference to `_imp__curl_easy_setopt'
src/lcerror.o:lcerror.c:(.text 0x1aa): undefined reference to `_imp__curl_easy_strerror'
src/lcerror.o:lcerror.c:(.text 0x1b7): undefined reference to `_imp__curl_multi_strerror'
src/lcerror.o:lcerror.c:(.text 0x1c5): undefined reference to `_imp__curl_share_strerror'
src/lchttppost.o:lchttppost.c:(.text 0x3a8): undefined reference to `_imp__curl_formfree'
src/lchttppost.o:lchttppost.c:(.text 0x512): undefined reference to `_imp__curl_formget'
src/lchttppost.o:lchttppost.c:(.text 0x5b7): undefined reference to `_imp__curl_formget'
src/lchttppost.o:lchttppost.c:(.text 0x644): undefined reference to `_imp__curl_formget'
src/lchttppost.o:lchttppost.c:(.text 0xa8f): undefined reference to `_imp__curl_formadd'
src/lchttppost.o:lchttppost.c:(.text 0xd99): undefined reference to `_imp__curl_formadd'
src/lchttppost.o:lchttppost.c:(.text 0xf18): undefined reference to `_imp__curl_slist_free_all'
src/lchttppost.o:lchttppost.c:(.text 0x105f): undefined reference to `_imp__curl_formadd'
src/lchttppost.o:lchttppost.c:(.text 0x118a): undefined reference to `_imp__curl_formadd'
src/lchttppost.o:lchttppost.c:(.text 0x1199): undefined reference to `_imp__curl_slist_free_all'
src/lchttppost.o:lchttppost.c:(.text 0x143f): undefined reference to `_imp__curl_formadd'
src/lchttppost.o:lchttppost.c:(.text 0x144e): undefined reference to `_imp__curl_slist_free_all'
src/lchttppost.o:lchttppost.c:(.text 0x154e): undefined reference to `_imp__curl_formadd'
src/lchttppost.o:lchttppost.c:(.text 0x16fb): undefined reference to `_imp__curl_formadd'
src/lchttppost.o:lchttppost.c:(.text 0x170a): undefined reference to `_imp__curl_slist_free_all'
src/lchttppost.o:lchttppost.c:(.text 0x1803): undefined reference to `_imp__curl_formadd'
src/lcurl.o:lcurl.c:(.text 0x358): undefined reference to `_imp__curl_easy_option_by_name'
src/lcurl.o:lcurl.c:(.text 0x3b0): undefined reference to `_imp__curl_easy_option_by_id'
src/lcurl.o:lcurl.c:(.text 0x490): undefined reference to `_imp__curl_easy_option_next'
src/lcurl.o:lcurl.c:(.text 0x4fa): undefined reference to `_imp__curl_version_info'
src/lcurl.o:lcurl.c:(.text 0x1105): undefined reference to `_imp__curl_version'
src/lcurl.o:lcurl.c:(.text 0x1666): undefined reference to `_imp__curl_global_init'
src/lcurl.o:lcurl.c:(.text 0x16e5): undefined reference to `_imp__curl_global_init'
src/lcutils.o:lcutils.c:(.text 0x5fa): undefined reference to `_imp__curl_slist_free_all'
src/lcutils.o:lcutils.c:(.text 0x704): undefined reference to `_imp__curl_slist_append'
src/lcmulti.o:lcmulti.c:(.text 0x43a): undefined reference to `_imp__curl_multi_remove_handle'
src/lcmulti.o:lcmulti.c:(.text 0x4fa): undefined reference to `_imp__curl_multi_init'
src/lcmulti.o:lcmulti.c:(.text 0x686): undefined reference to `_imp__curl_multi_cleanup'
src/lcmulti.o:lcmulti.c:(.text 0x830): undefined reference to `_imp__curl_multi_setopt'
src/lcmulti.o:lcmulti.c:(.text 0x8c0): undefined reference to `_imp__curl_multi_setopt'
src/lcmulti.o:lcmulti.c:(.text 0x981): undefined reference to `_imp__curl_multi_setopt'
src/lcmulti.o:lcmulti.c:(.text 0xab0): undefined reference to `_imp__curl_multi_setopt'
src/lcmulti.o:lcmulti.c:(.text 0xbe5): undefined reference to `_imp__curl_multi_setopt'
src/lcmulti.o:lcmulti.c:(.text 0xcba): undefined reference to `_imp__curl_multi_socket_action'
src/lcmulti.o:lcmulti.c:(.text 0xd7a): undefined reference to `_imp__curl_multi_timeout'
src/lcmulti.o:lcmulti.c:(.text 0xe42): undefined reference to `_imp__curl_multi_wait'
src/lcmulti.o:lcmulti.c:(.text 0xe9f): undefined reference to `_imp__curl_multi_timeout'
src/lcmulti.o:lcmulti.c:(.text 0x1134): undefined reference to `_imp__curl_multi_info_read'
src/lcmulti.o:lcmulti.c:(.text 0x1235): undefined reference to `_imp__curl_multi_remove_handle'
src/lcmulti.o:lcmulti.c:(.text 0x130a): undefined reference to `_imp__curl_multi_perform'
src/lcmulti.o:lcmulti.c:(.text 0x14a7): undefined reference to `_imp__curl_multi_add_handle'
src/lcshare.o:lcshare.c:(.text 0x7a): undefined reference to `_imp__curl_share_init'
src/lcshare.o:lcshare.c:(.text 0x1c5): undefined reference to `_imp__curl_share_cleanup'
src/lcshare.o:lcshare.c:(.text 0x261): undefined reference to `_imp__curl_share_setopt'
src/lcmime.o:lcmime.c:(.text 0x1de): undefined reference to `_imp__curl_mime_init'
src/lcmime.o:lcmime.c:(.text 0x42d): undefined reference to `_imp__curl_mime_subparts'
src/lcmime.o:lcmime.c:(.text 0x639): undefined reference to `_imp__curl_mime_free'
src/lcmime.o:lcmime.c:(.text 0x9bd): undefined reference to `_imp__curl_mime_addpart'
src/lcmime.o:lcmime.c:(.text 0xb06): undefined reference to `_imp__curl_mime_encoder'
src/lcmime.o:lcmime.c:(.text 0xbe6): undefined reference to `_imp__curl_mime_type'
src/lcmime.o:lcmime.c:(.text 0xcc6): undefined reference to `_imp__curl_mime_filename'
src/lcmime.o:lcmime.c:(.text 0xda6): undefined reference to `_imp__curl_mime_name'
src/lcmime.o:lcmime.c:(.text 0xe92): undefined reference to `_imp__curl_mime_headers'
src/lcmime.o:lcmime.c:(.text 0xeea): undefined reference to `_imp__curl_mime_headers'
src/lcmime.o:lcmime.c:(.text 0xef9): undefined reference to `_imp__curl_slist_free_all'
src/lcmime.o:lcmime.c:(.text 0x12b0): undefined reference to `_imp__curl_mime_type'
src/lcmime.o:lcmime.c:(.text 0x12d7): undefined reference to `_imp__curl_mime_name'
src/lcmime.o:lcmime.c:(.text 0x1302): undefined reference to `_imp__curl_mime_filename'
src/lcmime.o:lcmime.c:(.text 0x132f): undefined reference to `_imp__curl_mime_headers'
src/lcmime.o:lcmime.c:(.text 0x161e): undefined reference to `_imp__curl_mime_subparts'
src/lcmime.o:lcmime.c:(.text 0x16f8): undefined reference to `_imp__curl_mime_data'
src/lcmime.o:lcmime.c:(.text 0x17ef): undefined reference to `_imp__curl_mime_filedata'
src/lcurlapi.o:lcurlapi.c:(.text 0x26): undefined reference to `_imp__curl_url'
src/lcurlapi.o:lcurlapi.c:(.text 0x88): undefined reference to `_imp__curl_url_set'
src/lcurlapi.o:lcurlapi.c:(.text 0x190): undefined reference to `_imp__curl_url_get'
src/lcurlapi.o:lcurlapi.c:(.text 0x1a7): undefined reference to `_imp__curl_free'
src/lcurlapi.o:lcurlapi.c:(.text 0x1ed): undefined reference to `_imp__curl_free'
src/lcurlapi.o:lcurlapi.c:(.text 0x245): undefined reference to `_imp__curl_url_cleanup'
src/lcurlapi.o:lcurlapi.c:(.text 0x29d): undefined reference to `_imp__curl_url_dup'
src/lcurlapi.o:lcurlapi.c:(.text 0x34e): undefined reference to `_imp__curl_url_get'
src/lcurlapi.o:lcurlapi.c:(.text 0x367): undefined reference to `_imp__curl_free'
src/lcurlapi.o:lcurlapi.c:(.text 0x3bd): undefined reference to `_imp__curl_free'
src/lcurlapi.o:lcurlapi.c:(.text 0x5b7): undefined reference to `_imp__curl_url_set'
collect2.exe: error: ld returned 1 exit status

Error: Build error: Failed compiling module lcurl.dll

Any help would be highly appreciated, thanks.

CodePudding user response:

I found the issue, I needed the 32 bit cURL instead of the 64 bit.

cURL Windows 32 Bit Download: https://curl.se/windows/dl-7.82.0_1/curl-7.82.0_1-win32-mingw.zip

  • Related