Jump to content

How do I link a .so library that I want to use in my HDK plugin?


Recommended Posts

Hi everyone!

I recently started working with the HDK and have been trying to set my project up to use an external library, but I don't have a lot of experience with dependency management in C++. It seemed to me like setting something up with a cmake file was the way to go, but I'm having a hard time figuring out the best way to set something up to work with the Houdini environment. 

Is this something that is even possible, or am I going about this the wrong way?

Thanks! 

Link to comment
Share on other sites

The thing is simple if the libraries you're going to use have modern CMake support. It boils down to a series of commands:

find_package()

target_link_library()

This way CMake will take care of everything for you. It's de facto standard of dependency management in C++. If the library is oldie and not maintained so Cmake can't find it (and you can't provide proper FindXXX.cmake file to help it with it), this is where your journey begins. Depending on case it might be long one varied by a series of visits on stackovertflow with mutually excluding answers. Google it ("how to set up XXX lib with Cmake") or post here details. 

 

 

  • Like 1
Link to comment
Share on other sites

  • 2 weeks later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...