M1 macbook vscode c++连接SQL server报错

M1 macbook vscode c++报错

Undefined symbols for architecture arm64:
"_SQLAllocHandle", referenced from:
_main in test2-1c554c.o
"_SQLConnect", referenced from:
_main in test2-1c554c.o
"_SQLFreeHandle", referenced from:
_main in test2-1c554c.o
"_SQLSetEnvAttr", referenced from:
_main in test2-1c554c.o
ld: symbol(s) not found for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)

c++连接SQL server时报错求解

你对应的 SQL Server 依赖库不对,也是在 M1 上重新编译的吗