I am trying to write (c/c++) code in Clion IDE. I need to add some shared library into my project. at this moment, I only want to run the main function, which will add all f
Use add_library if you are creating your own library from source files.
add_library
Use target_link_libraries if you are specifying that your target needs to link against a library from someone else.
target_link_libraries