Spout

Spout2 with VCPKG?

Hi,

I recently incorporated spout2 into a project and our package manager of choice is VCPKG. There were some components missing from the build pipeline to make this work out of the box, namely the CMakeLists.txt you provide does not support installing and there were a few issues with building outside of visual studio.
I’ve made everything work for us now using the patching system to apply patches to your source before building it, however it strikes me that this might be of interest to other developers as well so I’m asking if this is something you would like me to make a bit more general and create pull requests for?

The changes that I foresee would be isolated to the CMake build pipeline and specifically involve creating install targets and possibly isolating some file-copying to “Visual Studio Only”. Install targets are of benefit for general development as well and is not isolated to VCPKG package-management.

Best,
Joakim

Hi Joakim,

thanks very much for the offer to make your work more general for people to use. I don’t have any experience with VCPKG, and I am not certain what would be involved but I would like to learn more about it. We can use the Beta branch for pull requests and development work.

But first I am keen to know what the issues were with building using CMake outside of Visual Studio as well as any changes that you found necessary in the source code. Could this be a first step perhaps?

Would your proposal be something else on top of these things?

Hi,

Using the beta branch sounds like a good idea, I’ll make the changes and submit pull requests as soon as I have time and you can review the changes from there :slight_smile:
I’ll try to keep the pull requests small & isolated feature-wise.

I’ve only really tested with the static library but the main issue I ran into were that there are some copying of output files being done as a ‘post-build’ step and there were problems with the paths. First it was hardcoded to use ‘Release’ folder and hence the builds fail in debug mode, secondly the file structure in itself (/Debug/Release) is Visual studio specific as other build systems output to only.

I don’t foresee my proposal changing anything outside of what I stated in my original post, unless I run into issues with the dynamic library or the C-library.

Best,
Joakim

That sounds like it could be a mistake with the Visual Studio solution/project file. I will look into it as soon as I can.

Small steps is a good idea. I am not certain of what is involved but I look forward to finding out.