Hi Ding. I don’t know, but this looks like it’s entirely in your ballcourt; library libssl (which SLiM does not use or reference) not found when loading libssh2 (which SLiM also does not use or reference). I don’t know why your system would even be looking at those libraries when building SLiM; I see libssh2 is in an anaconda3 folder, so maybe you’ve done some Anaconda setup that has modified your builds? I am not familiar with Anaconda, so I have no advice on that; maybe someone else on the list knows.
In any case, I would note that building SLiM at the command line on macOS is not recommended; building in Xcode is recommended on macOS because then you get all of the Xcode project settings that make an optimal macOS build. See the manual, chapter 2, for instructions on building in Xcode.
Good luck!
Cheers,
-B.
Benjamin C. Haller
Messer Lab
Cornell University