building as dll and include for c++

Hi.

I want to try using ITK for some c++ development.
I want to use it as any other external library I use (such as opencv i.e.)
Preferably- dll + lib + include
but also static libs + include is fine

I’m compiling in visual studio 2015
In CMAKE I run configure and generate (default options)
I then open the .sln in visual studio and build.
build is successful.
I get a lib folder with libraries.
I try building the INSTALL project as I usually do with other cmake projects but it fails
I don’t have an include directory

Thanks for any help

What is the error message?

We dropped support for VS2015 (toolset v140) with ITK 5.3, but you are probably using an earlier version as 5.3 should give you an error in the configure step.

Hi.
Thanks for the help.
I figured it out.
There might be a better a way to fix this.
The problem was that the install folder was defined in c:\program files
adding a new definition for the CMAKE_INSTALL_PREFIX didnt help.
After configuring, I changed the cmake files which had “c:\program files” in them (2 files I think, in the main directory and the eigen directory) to my desired install directory and it fixed the problem.

1 Like