library libzstd is missing in mysql (macos monterey m1 pro)

When i compile the c program with mysql i get the next error:

ld: library not found for -lzstd
clang: error: linker command failed with exit code 1 (use -v to see invocation)

So i use the zstd (that i installed) directory link in my command line

gcc parking.o -o parking.exe `mysql_config --libs` -L/opt/homebrew/Cellar/zstd/1.5.2/lib

It creates the .exe but when i launch it i get

How can i solve it ? Need help please.

Don’t add the .exe extension to your executables. That’s not the convention on Unix-y systems, including macOS, and it’s likely that this is causing confusion here.

If you run your tool from the command line, what do you see?

% ./packing

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

library libzstd is missing in mysql (macos monterey m1 pro)
 
 
Q