I have pulled paho-mqtt-C library repo and followed given instruction to build and install the same. 
However, whenever I am trying to run one of the sample, I am getting following error.
Supriyas-MacBook-Air:samples supriyajagtap$ ./MQTTClient_publish
dyld: Library not loaded: libpaho-mqtt3c.so.1
  Referenced from: /Users/supriyajagtap/Documents/IOT_Client/paho.mqtt.c/build/output/samples/./MQTTClient_publish
  Reason: image not found
Abort trap: 6
 I googled for the same, and tried all possible solutions given on different forums, but no luck. 
I also copied one of the sample file code in another project and tried building the same. Getting following errors, at the time of linking.
Undefined symbols for architecture x86_64:
  "_MQTTAsync_connect", referenced from:
      _myconnect in paho_c_pub.o
      _connectionLost in paho_c_pub.o
  "_MQTTAsync_createWithOptions", referenced from:
      _main in paho_c_pub.o
  "_MQTTAsync_destroy", referenced from:
      _main in paho_c_pub.o
  "_MQTTAsync_disconnect", referenced from:
      _main in paho_c_pub.o
  "_MQTTAsync_send", referenced from:
      _main in paho_c_pub.o
  "_MQTTAsync_setCallbacks", referenced from:
      _main in paho_c_pub.o
ld: symbol(s) not found for architecture x86_64
 
I want to write my own mqtt client using paho-c apis, however I need to test the existing functionality, especially SSL support provided by the library, before implementing the same.
Am I missing any step here. Any help would be highly appreciated.  
--