Jump to content
syst3m_ERROR

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! 

Share this post


Link to post
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

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×