OpenImageIO
OpenImageIO copied to clipboard
[FEATURE REQUEST] CMake Subdirectory Support
Is your feature request related to a problem? Please describe.
In my projects, I prefer to have all the dependencies as submodules, which are then included in the projects CMake build system by add_subdirectory
. However, it seems that this does not work with oiio.
I think that this is due to lines such as 128, where it requires oiio to be built in CMAKE_BINARY_DIR
, which may not be the case if it is in a subdirectory.
Describe the solution you'd like
Reconfiguration of the CMake files such that they do not rely directly on CMAKE_BINARY_DIR
, but instead use CMAKE_CURRENT_BINARY_DIR
, so that the project can be compiled as a dependency of other projects.
I'm not sure how to test this and know that I've done it correctly.
If you know what needs to be done, I don't suppose you'd be willing to take a stab at it and submit a PR?
At the moment I don't have the time to take a stab at it (I can try in a few weeks). But I made a repository which I would expect to compile successfully (https://github.com/Nedra1998/oiio_test). However, I am unable to compile this repo on my machine.
If this is just an issue with my system please let me know.