Tina
Tina

Reputation: 31

Handling “dyld: lazy symbol binding failed: Symbol not found” error when compiling C++ code on Mac

Mac version: Mac Sierra Version 10.12.5 gcc version: 4.8.5

The error message shown when compiling C++ code in terminal is as below: dyld: lazy symbol binding failed: Symbol not found: __ZNSt8__detail15_List_node_base7_M_hookEPS0_
Referenced from: /Users/tina/Documents/pimsa-master/samples/endophenotype/../../analyzer (which was built for Mac OS X 10.12)
Expected in: /usr/lib/libstdc++.6.dylib

Upvotes: 1

Views: 2088

Answers (1)

Tina
Tina

Reputation: 31

Thanks for the help, one of my friends helped me to figure it out. There are two gcc (g++) on my computer, one is installed with anaconda, the other one is in the required location. Since I accidentally set anaconda in front of the other location in the bashfile, it did not work. Now it is fixed by placing the required location in front of anaconda in the bashfile.

Upvotes: 1

Related Questions