title: How to use .so library in C++ with Clion and Cmake?
body: <p>There is <a href="https://stackoverflow.com/questions/33639775/clion-cmake-how-to-add-library-so">a question</a> about this already, but the asker was either doing some more complicated then me, or the posted answer assumed too much background knowledge for me to understand.</p>
  
  <p>I am trying to use the following library: <a href="https://github.com/samehkamaleldin/socket.cpp" rel="nofollow noreferrer">https://github.com/samehkamaleldin/socket.cpp</a>
  .</p>
  
  <p>I downloaded the library from github and built it. I then placed the resulting <code>.so</code> file in the same directory as <code>main.cpp</code>, like this:</p>
  
  <p><a href="https://i.stack.imgur.com/hZv1j.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/hZv1j.png" alt="Screenshot"></a></p>
  
  <p>However, I'm not sure what to do from here, from my research, I need to use the command <code>target_link_libraries</code>, but I'm not sure what to pass in for each parameter. </p>