Open ystyle opened 1 year ago
mingw可能是可以的,但是编译脚本估计要自己改改 如果要用cuda的话,似乎只能用vs
没启用cuda, 编译到webui就报错了。 这时生成的main.exe 运行不了
以下是编译日志
lxy52@YSTYLE-PC MINGW64 /d/Code/C++/fastllm/build
$ cmake .. -DUSE_CUDA=OFF
-- USE_CUDA: OFF
-- PYTHON_API: OFF
-- CMAKE_CXX_FLAGS -pthread --std=c++17 -O2 -march=native
-- Configuring done
-- Generating done
-- Build files have been written to: D:/Code/C++/fastllm/build
lxy52@YSTYLE-PC MINGW64 /d/Code/C++/fastllm/build
$ make -j
[ 3%] Building CXX object CMakeFiles/fastllm.dir/src/fastllm.cpp.obj
[[ 1144%%]] [BB[ 21%] Building CXX object CMakeFiles/fauus[[[tildildliilnnmgg. dCCiXXrXX/ s orocbb/jjdeeecvctit c CCeM.Macakkpepe.FFob
j
[iiles[[[[l/e sf/3444fa52%26a%]s%]%s t] ]tl l lB Blu muBB m2i[u_iu_litlitdlodloidoidoiilnnlnnsggsgg. . dCCdCCiXXiXXrXXrXX/ /osbojb
ej osrce boctcrjb/ tcejme /CCoccdMMattedak vekeCCiMeFMlcaFki.lceaeeipskF.lp/eice.fFlpsoaiep/bslt.fjseloab/slm.dir
sjf//t
1fslalstllamsrm_tc.tl/dolmimood_rlet/slos.sord/lcics/rh.m/adostidrgrecl/l/ms.msrco/cpdl/pelm.looasmdb/aejc.lh
c4pp.o[ sa[[b2j15% 5/t b5
7%]] [0g a673%2[ %6]8s0%%]% ]Bl7%]ellm.cpp.m .oBcbupijpl
.doibnjg
CXX object CMakeFiles/fastllm_tools.dir/src/models]%5/3 B Bu ]]B%6uuBi llau]7iiulB Bmi %lBiduuBal]lduliiiud. diidnlliicppnligddlniB.gd
iidgnuoniCCnni nibgjXXggg gl X
X C CndCC XCXCXgiX ooXXXXXnXXbbX g jjeoCoo oo ecbXbbCbboctjXjjXjjbt e eeXeej Ccocc cceCMtbttottcMa j b takCeCCjCe keMcatCMcCeMFMk M
atFMaiaeCak iaklkFekeelkeeMiFlCFeFesaFielisiF/kiMsel/eifela/slfslaFekfeea/esis/aFssfstl/ffi/ta/lesatlflsflsasleassam/_tllt/tssftlmmlflttl
ol_.ldlallomt.oimr.mlamdosl/d_st.oltmsis_idosl.rrttri/.ldc/lolrsdmi/slos/ri.rmrml.scrd/oc_sdr//isd/t.icesrr/dodr/xrecseov/fecl/rilisac/.m
crs/rsumco/c.scrtopdmedt/codpeosile/re.ld/rlxd.losec/meecsb/lpt.ocp/jmsucvoppm.o//uilp
oosbctcs.sbsapoe/osj.surssb.c
ed.ecvpplprjcip/l.c/
c.cmoppeop.bpy.bucj.
oj/ptcb
cpopjp
op..luoosdbb.ejvcj
ip
cpe..ocbpjp
.obj
[ 71%] Linking CXX [s h7a1r%e]d lBiubirlatr yt alrigbefta stflalsmt_ltololsm.d
ll
[ 75%] Building CXX object [[ 88C22%%]] BBMuuaiiklleddFiiinnlgeg sC /XCwXXe Xbo uboijb.ejdceitr /CcMetax akCmeMpFalikele/Fewisle/emsba/
uiqinu/.awdneitbr.u/dimi.arci/pntp.o.cooplbpsj./
osbrjc/
quant.cpp.obj
[ 85%] Building CXX object CMakeFiles/benchmark.dir/example/benchmark/benchmark.cpp.obj
Error copying file "D:/Code/C++/fastllm/build/fastllm_tools.dll" to "D:/Code/C++/fastllm/build/tools/fastllm_pytools/.".
make[2]: *** [CMakeFiles/fastllm_tools.dir/build.make:247: libfastllm_tools.dll] Error 1
make[2]: *** Deleting file 'libfastllm_tools.dll'
make[1]: *** [CMakeFiles/Makefile2:223: CMakeFiles/fastllm_tools.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
[ 89%] Linking CXX executable main.exe
[ 92%] Linking CXX executable quant.exe
[ 92%] Built target main
[ 92%] Built target quant
[ 96%] Linking CXX executable benchmark.exe
[ 96%] Built target benchmark
[100%] Linking CXX executable webui.exe
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text+0x162): undefined reference to `__imp_WSACleanup'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text+0x212): undefined reference to `__imp_select'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib22default_socket_optionsEy[_ZN7httplib22default_socket_optionsEy]+0xa): undefined refer
ence to `__imp_setsockopt'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib6detail12SocketStream4readEPcy[_ZN7httplib6detail12SocketStream4readEPcy]+0xa2): undefi
ned reference to `__imp_select'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib6detail12SocketStream4readEPcy[_ZN7httplib6detail12SocketStream4readEPcy]+0x12f): undef
ined reference to `__imp_recv'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib6detail12SocketStream4readEPcy[_ZN7httplib6detail12SocketStream4readEPcy]+0x173): undef
ined reference to `__imp_recv'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib6detail12SocketStream5writeEPKcy[_ZN7httplib6detail12SocketStream5writeEPKcy]+0x4e): un
defined reference to `__imp_select'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib6detail12SocketStream5writeEPKcy[_ZN7httplib6detail12SocketStream5writeEPKcy]+0x11c): u
ndefined reference to `__imp_recv'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib6detail12SocketStream5writeEPKcy[_ZN7httplib6detail12SocketStream5writeEPKcy]+0x171): u
ndefined reference to `__imp_send'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZNK7httplib6detail12SocketStream22get_remote_ip_and_portERNSt7__cxx1112basic_stringIcSt11char_tra
itsIcESaIcEEERi[_ZNK7httplib6detail12SocketStream22get_remote_ip_and_portERNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERi]+0x2c):
undefined reference to `__imp_getpeername'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZNK7httplib6detail12SocketStream22get_remote_ip_and_portERNSt7__cxx1112basic_stringIcSt11char_tra
itsIcESaIcEEERi[_ZNK7httplib6detail12SocketStream22get_remote_ip_and_portERNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERi]+0x5c):
undefined reference to `__imp_ntohs'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZNK7httplib6detail12SocketStream22get_remote_ip_and_portERNSt7__cxx1112basic_stringIcSt11char_tra
itsIcESaIcEEERi[_ZNK7httplib6detail12SocketStream22get_remote_ip_and_portERNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERi]+0xa6):
undefined reference to `__imp_getnameinfo'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZNK7httplib6detail12SocketStream21get_local_ip_and_portERNSt7__cxx1112basic_stringIcSt11char_trai
tsIcESaIcEEERi[_ZNK7httplib6detail12SocketStream21get_local_ip_and_portERNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERi]+0x2c): u
ndefined reference to `__imp_getsockname'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZNK7httplib6detail12SocketStream21get_local_ip_and_portERNSt7__cxx1112basic_stringIcSt11char_trai
tsIcESaIcEEERi[_ZNK7httplib6detail12SocketStream21get_local_ip_and_portERNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERi]+0x5c): u
ndefined reference to `__imp_ntohs'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZNK7httplib6detail12SocketStream21get_local_ip_and_portERNSt7__cxx1112basic_stringIcSt11char_trai
tsIcESaIcEEERi[_ZNK7httplib6detail12SocketStream21get_local_ip_and_portERNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERi]+0xa6): u
ndefined reference to `__imp_getnameinfo'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib10ClientImplD0Ev[_ZN7httplib10ClientImplD0Ev]+0x3a): undefined reference to `__imp_shut
down'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib10ClientImplD0Ev[_ZN7httplib10ClientImplD0Ev]+0x4a): undefined reference to `__imp_clos
esocket'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib10ClientImplD1Ev[_ZN7httplib10ClientImplD1Ev]+0x3a): undefined reference to `__imp_shut
down'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib10ClientImplD1Ev[_ZN7httplib10ClientImplD1Ev]+0x4a): undefined reference to `__imp_clos
esocket'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib6detail11select_readEyxx[_ZN7httplib6detail11select_readEyxx]+0x12): undefined referenc
e to `__imp_select'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib6detail12select_writeEyxx[_ZN7httplib6detail12select_writeEyxx]+0x12): undefined refere
nce to `__imp_select'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZNK7httplib6detail12SocketStream11is_writableEv[_ZNK7httplib6detail12SocketStream11is_writableEv]
+0x50): undefined reference to `__imp_recv'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib6detail26wait_until_socket_is_readyEyxx[_ZN7httplib6detail26wait_until_socket_is_readyE
yxx]+0x78): undefined reference to `__imp_select'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib6detail26wait_until_socket_is_readyEyxx[_ZN7httplib6detail26wait_until_socket_is_readyE
yxx]+0xde): undefined reference to `__WSAFDIsSet'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib6detail26wait_until_socket_is_readyEyxx[_ZN7httplib6detail26wait_until_socket_is_readyE
yxx]+0xed): undefined reference to `__WSAFDIsSet'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib6detail26wait_until_socket_is_readyEyxx[_ZN7httplib6detail26wait_until_socket_is_readyE
yxx]+0x124): undefined reference to `__imp_getsockopt'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib6detail6WSInitC1Ev[_ZN7httplib6detail6WSInitC1Ev]+0x1a): undefined reference to `__imp_
WSAStartup'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib6Server15listen_internalEv[_ZN7httplib6Server15listen_internalEv]+0xa3): undefined refe
rence to `__imp_select'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib6Server15listen_internalEv[_ZN7httplib6Server15listen_internalEv]+0xdb): undefined refe
rence to `__imp_accept'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib6Server15listen_internalEv[_ZN7httplib6Server15listen_internalEv]+0x10d): undefined ref
erence to `__imp_setsockopt'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib6Server15listen_internalEv[_ZN7httplib6Server15listen_internalEv]+0x428): undefined ref
erence to `__imp_closesocket'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib6detail13create_socketIZNS0_20create_client_socketERKNSt7__cxx1112basic_stringIcSt11cha
r_traitsIcESaIcEEES9_iibSt8functionIFvyEExxxxxxS9_RNS_5ErrorEEUlyR8addrinfoE_EEyS9_S9_iiibSC_T_[_ZN7httplib6detail13create_socketIZNS0_20
create_client_socketERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES9_iibSt8functionIFvyEExxxxxxS9_RNS_5ErrorEEUlyR8addrinfoE_EEy
S9_S9_iiibSC_T_]+0x1bf): undefined reference to `__imp_getaddrinfo'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib6detail13create_socketIZNS0_20create_client_socketERKNSt7__cxx1112basic_stringIcSt11cha
r_traitsIcESaIcEEES9_iibSt8functionIFvyEExxxxxxS9_RNS_5ErrorEEUlyR8addrinfoE_EEyS9_S9_iiibSC_T_[_ZN7httplib6detail13create_socketIZNS0_20
create_client_socketERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES9_iibSt8functionIFvyEExxxxxxS9_RNS_5ErrorEEUlyR8addrinfoE_EEy
S9_S9_iiibSC_T_]+0x1dc): undefined reference to `__imp_WSASocketW'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib6detail13create_socketIZNS0_20create_client_socketERKNSt7__cxx1112basic_stringIcSt11cha
r_traitsIcESaIcEEES9_iibSt8functionIFvyEExxxxxxS9_RNS_5ErrorEEUlyR8addrinfoE_EEyS9_S9_iiibSC_T_[_ZN7httplib6detail13create_socketIZNS0_20
create_client_socketERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES9_iibSt8functionIFvyEExxxxxxS9_RNS_5ErrorEEUlyR8addrinfoE_EEy
S9_S9_iiibSC_T_]+0x1e3): undefined reference to `__imp_ioctlsocket'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib6detail13create_socketIZNS0_20create_client_socketERKNSt7__cxx1112basic_stringIcSt11cha
r_traitsIcESaIcEEES9_iibSt8functionIFvyEExxxxxxS9_RNS_5ErrorEEUlyR8addrinfoE_EEyS9_S9_iiibSC_T_[_ZN7httplib6detail13create_socketIZNS0_20
create_client_socketERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES9_iibSt8functionIFvyEExxxxxxS9_RNS_5ErrorEEUlyR8addrinfoE_EEy
S9_S9_iiibSC_T_]+0x26c): undefined reference to `__imp_connect'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib6detail13create_socketIZNS0_20create_client_socketERKNSt7__cxx1112basic_stringIcSt11cha
r_traitsIcESaIcEEES9_iibSt8functionIFvyEExxxxxxS9_RNS_5ErrorEEUlyR8addrinfoE_EEyS9_S9_iiibSC_T_[_ZN7httplib6detail13create_socketIZNS0_20
create_client_socketERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES9_iibSt8functionIFvyEExxxxxxS9_RNS_5ErrorEEUlyR8addrinfoE_EEy
S9_S9_iiibSC_T_]+0x297): undefined reference to `__imp_setsockopt'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib6detail13create_socketIZNS0_20create_client_socketERKNSt7__cxx1112basic_stringIcSt11cha
r_traitsIcESaIcEEES9_iibSt8functionIFvyEExxxxxxS9_RNS_5ErrorEEUlyR8addrinfoE_EEyS9_S9_iiibSC_T_[_ZN7httplib6detail13create_socketIZNS0_20
create_client_socketERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES9_iibSt8functionIFvyEExxxxxxS9_RNS_5ErrorEEUlyR8addrinfoE_EEy
S9_S9_iiibSC_T_]+0x344): undefined reference to `__imp_freeaddrinfo'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib6detail13create_socketIZNS0_20create_client_socketERKNSt7__cxx1112basic_stringIcSt11cha
r_traitsIcESaIcEEES9_iibSt8functionIFvyEExxxxxxS9_RNS_5ErrorEEUlyR8addrinfoE_EEyS9_S9_iiibSC_T_[_ZN7httplib6detail13create_socketIZNS0_20
create_client_socketERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES9_iibSt8functionIFvyEExxxxxxS9_RNS_5ErrorEEUlyR8addrinfoE_EEy
S9_S9_iiibSC_T_]+0x3c2): undefined reference to `__imp_WSAGetLastError'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib6detail13create_socketIZNS0_20create_client_socketERKNSt7__cxx1112basic_stringIcSt11cha
r_traitsIcESaIcEEES9_iibSt8functionIFvyEExxxxxxS9_RNS_5ErrorEEUlyR8addrinfoE_EEyS9_S9_iiibSC_T_[_ZN7httplib6detail13create_socketIZNS0_20
create_client_socketERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES9_iibSt8functionIFvyEExxxxxxS9_RNS_5ErrorEEUlyR8addrinfoE_EEy
S9_S9_iiibSC_T_]+0x3de): undefined reference to `__imp_closesocket'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib6detail13create_socketIZNS0_20create_client_socketERKNSt7__cxx1112basic_stringIcSt11cha
r_traitsIcESaIcEEES9_iibSt8functionIFvyEExxxxxxS9_RNS_5ErrorEEUlyR8addrinfoE_EEyS9_S9_iiibSC_T_[_ZN7httplib6detail13create_socketIZNS0_20
create_client_socketERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES9_iibSt8functionIFvyEExxxxxxS9_RNS_5ErrorEEUlyR8addrinfoE_EEy
S9_S9_iiibSC_T_]+0x3f9): undefined reference to `__imp_freeaddrinfo'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib6detail13create_socketIZNS0_20create_client_socketERKNSt7__cxx1112basic_stringIcSt11cha
r_traitsIcESaIcEEES9_iibSt8functionIFvyEExxxxxxS9_RNS_5ErrorEEUlyR8addrinfoE_EEyS9_S9_iiibSC_T_[_ZN7httplib6detail13create_socketIZNS0_20
create_client_socketERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES9_iibSt8functionIFvyEExxxxxxS9_RNS_5ErrorEEUlyR8addrinfoE_EEy
S9_S9_iiibSC_T_]+0x435): undefined reference to `__imp_setsockopt'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib6detail13create_socketIZNS0_20create_client_socketERKNSt7__cxx1112basic_stringIcSt11cha
r_traitsIcESaIcEEES9_iibSt8functionIFvyEExxxxxxS9_RNS_5ErrorEEUlyR8addrinfoE_EEyS9_S9_iiibSC_T_[_ZN7httplib6detail13create_socketIZNS0_20
create_client_socketERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES9_iibSt8functionIFvyEExxxxxxS9_RNS_5ErrorEEUlyR8addrinfoE_EEy
S9_S9_iiibSC_T_]+0x465): undefined reference to `__imp_setsockopt'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib6detail13create_socketIZNS0_20create_client_socketERKNSt7__cxx1112basic_stringIcSt11cha
r_traitsIcESaIcEEES9_iibSt8functionIFvyEExxxxxxS9_RNS_5ErrorEEUlyR8addrinfoE_EEyS9_S9_iiibSC_T_[_ZN7httplib6detail13create_socketIZNS0_20
create_client_socketERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES9_iibSt8functionIFvyEExxxxxxS9_RNS_5ErrorEEUlyR8addrinfoE_EEy
S9_S9_iiibSC_T_]+0x47c): undefined reference to `__imp_socket'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib6detail13create_socketIZNKS_6Server20create_server_socketERKNSt7__cxx1112basic_stringIc
St11char_traitsIcESaIcEEEiiSt8functionIFvyEEEUlyR8addrinfoE_EEySA_SA_iiibSD_T_[_ZN7httplib6detail13create_socketIZNKS_6Server20create_ser
ver_socketERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEiiSt8functionIFvyEEEUlyR8addrinfoE_EEySA_SA_iiibSD_T_]+0x198): undefined
reference to `__imp_getaddrinfo'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib6detail13create_socketIZNKS_6Server20create_server_socketERKNSt7__cxx1112basic_stringIc
St11char_traitsIcESaIcEEEiiSt8functionIFvyEEEUlyR8addrinfoE_EEySA_SA_iiibSD_T_[_ZN7httplib6detail13create_socketIZNKS_6Server20create_ser
ver_socketERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEiiSt8functionIFvyEEEUlyR8addrinfoE_EEySA_SA_iiibSD_T_]+0x1b5): undefined
reference to `__imp_WSASocketW'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib6detail13create_socketIZNKS_6Server20create_server_socketERKNSt7__cxx1112basic_stringIc
St11char_traitsIcESaIcEEEiiSt8functionIFvyEEEUlyR8addrinfoE_EEySA_SA_iiibSD_T_[_ZN7httplib6detail13create_socketIZNKS_6Server20create_ser
ver_socketERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEiiSt8functionIFvyEEEUlyR8addrinfoE_EEySA_SA_iiibSD_T_]+0x1bc): undefined
reference to `__imp_bind'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib6detail13create_socketIZNKS_6Server20create_server_socketERKNSt7__cxx1112basic_stringIc
St11char_traitsIcESaIcEEEiiSt8functionIFvyEEEUlyR8addrinfoE_EEySA_SA_iiibSD_T_[_ZN7httplib6detail13create_socketIZNKS_6Server20create_ser
ver_socketERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEiiSt8functionIFvyEEEUlyR8addrinfoE_EEySA_SA_iiibSD_T_]+0x1c3): undefined
reference to `__imp_closesocket'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib6detail13create_socketIZNKS_6Server20create_server_socketERKNSt7__cxx1112basic_stringIc
St11char_traitsIcESaIcEEEiiSt8functionIFvyEEEUlyR8addrinfoE_EEySA_SA_iiibSD_T_[_ZN7httplib6detail13create_socketIZNKS_6Server20create_ser
ver_socketERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEiiSt8functionIFvyEEEUlyR8addrinfoE_EEySA_SA_iiibSD_T_]+0x246): undefined
reference to `__imp_listen'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib6detail13create_socketIZNKS_6Server20create_server_socketERKNSt7__cxx1112basic_stringIc
St11char_traitsIcESaIcEEEiiSt8functionIFvyEEEUlyR8addrinfoE_EEySA_SA_iiibSD_T_[_ZN7httplib6detail13create_socketIZNKS_6Server20create_ser
ver_socketERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEiiSt8functionIFvyEEEUlyR8addrinfoE_EEySA_SA_iiibSD_T_]+0x255): undefined
reference to `__imp_freeaddrinfo'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib6detail13create_socketIZNKS_6Server20create_server_socketERKNSt7__cxx1112basic_stringIc
St11char_traitsIcESaIcEEEiiSt8functionIFvyEEEUlyR8addrinfoE_EEySA_SA_iiibSD_T_[_ZN7httplib6detail13create_socketIZNKS_6Server20create_ser
ver_socketERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEiiSt8functionIFvyEEEUlyR8addrinfoE_EEySA_SA_iiibSD_T_]+0x2dd): undefined
reference to `__imp_freeaddrinfo'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib6detail13create_socketIZNKS_6Server20create_server_socketERKNSt7__cxx1112basic_stringIc
St11char_traitsIcESaIcEEEiiSt8functionIFvyEEEUlyR8addrinfoE_EEySA_SA_iiibSD_T_[_ZN7httplib6detail13create_socketIZNKS_6Server20create_ser
ver_socketERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEiiSt8functionIFvyEEEUlyR8addrinfoE_EEySA_SA_iiibSD_T_]+0x315): undefined
reference to `__imp_setsockopt'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib6detail13create_socketIZNKS_6Server20create_server_socketERKNSt7__cxx1112basic_stringIc
St11char_traitsIcESaIcEEEiiSt8functionIFvyEEEUlyR8addrinfoE_EEySA_SA_iiibSD_T_[_ZN7httplib6detail13create_socketIZNKS_6Server20create_ser
ver_socketERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEiiSt8functionIFvyEEEUlyR8addrinfoE_EEySA_SA_iiibSD_T_]+0x345): undefined
reference to `__imp_setsockopt'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib6detail13create_socketIZNKS_6Server20create_server_socketERKNSt7__cxx1112basic_stringIc
St11char_traitsIcESaIcEEEiiSt8functionIFvyEEEUlyR8addrinfoE_EEySA_SA_iiibSD_T_[_ZN7httplib6detail13create_socketIZNKS_6Server20create_ser
ver_socketERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEiiSt8functionIFvyEEEUlyR8addrinfoE_EEySA_SA_iiibSD_T_]+0x35c): undefined
reference to `__imp_socket'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib6Server13bind_internalERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEii[_ZN7htt
plib6Server13bind_internalERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEii]+0x1c4): undefined reference to `__imp_getsockname'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib6Server13bind_internalERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEii[_ZN7htt
plib6Server13bind_internalERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEii]+0x1f0): undefined reference to `__imp_ntohs'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib6Server24process_and_close_socketEy[_ZN7httplib6Server24process_and_close_socketEy]+0x9
e): undefined reference to `__imp_select'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib6Server24process_and_close_socketEy[_ZN7httplib6Server24process_and_close_socketEy]+0x1
14): undefined reference to `__imp_shutdown'
D:/Application/msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/12.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: CMakeFiles/webui.dir/obj
ects.a(webui.cpp.obj):webui.cpp:(.text$_ZN7httplib6Server24process_and_close_socketEy[_ZN7httplib6Server24process_and_close_socketEy]+0x1
1d): undefined reference to `__imp_closesocket'
collect2.exe: error: ld returned 1 exit status
make[2]: *** [CMakeFiles/webui.dir/build.make:116: webui.exe] Error 1
make[1]: *** [CMakeFiles/Makefile2:171: CMakeFiles/webui.dir/all] Error 2
make: *** [Makefile:91: all] Error 2
httplib的问题,可以去httplib下看看有没有类似的issue.
我也用的mingw,我连build都没成功。输入完build的命令后就一直在等,没有任何输出
不能直接用msys2或mingw64吗