I don’t understand if you suggest conan / vcpkg - I have no experience with either, so whatever works(?)
But there seems to be a problem with boost, if it’s the only problem, we include the headers only
Conan packages are all open source. There are hundreds of boost packages, all with different binaries. Other dependencies are the same. I was interested, since it’s cross-platform. We could use one package manager. I was wondering if anyone else had experience with it. After playing with it for a couple hours, I don’t think it will sole our problem well.
Vcpkg currently doesn’t have version control. Each version of vcpkg has a unique set of ports with a set version -
you have to install a certain version on vcpkg to get boost 1.65.1. CMake FindPackage breaks with boost 1.66.0, which is included in the latest vcpkg. I think vcpkg would be a good option for Windows, once it’s out of preview and has version control.
Basically, a package manager lite that we control. For Windows, we could do the vcpkg craziness to get the correct version, then export it to the repository. For Linux… would apt-get just work? Would we need to patch anything?
Good research, thanks!
I’m not happy with the results either.
This dependency situation is getting more nasty…
I’m inclining to say, for linux/osx use apt/brew install boost-headers1.58-dev ,…
and for Win we ship the binaries and unpack (ideally not build) them in the repo, the cmake’s file(DOWNLOAD …) is being used already in the repo, see external/*.cmake
Correct, wouldn’t we want to manage targets the binaries of all supported targets, albeit in a separate repository? New support could come in the form of a PR. That way, anyone on apple, unix, windows, etc. gets the same repositories, patches and everything. Like Conan’s approach, only nupic would be the user (e.g., ‘boost/1.66@nupic/stable’). CMake can then be conigured to download those binaries into the bin, based on the target triplet, which is pretty much nupic’s, file structure.
I’ll check it out… I thought we might want to just keep those in a separate repository.
+1 for that being in a separate repo (/just some cloud storage,…)
? not sure if there wouldn’t be conflicts , eg system boost vs ours. But the idea of binary deps for all targets and universal linking to that in Cmake is imho sound.
We had EXACTLY this approach down in the past, with nupic-platform-linux64,...@rhyolight do you recall why did we abandon it? Were there any caveats?
We abandoned those dependency repos because CI environments got more stable and we were able to declare more and more dependencies naturally as the project matured. At some point we stopped needing them.
@heilerm what if we stick to that too? Unix have typically good package capabilities, for Win we make the binary-deps repo as you suggest. If we see problems with either approach, we can shift to one, or the other solution?
When you add binaries to a repo, you’re making assumptions about the environment in which it can be run, therefore you’re also putting possible restrictions on it as well.
Best IMO would be not to have any binaries in any repositories. This may be unrealistic, but it is something to shoot for.
I think vcpkg will get there. We can even use it to build and export the dependencies we need, dealing with the versioning issue. Once it gets there, zero managed binaries. We will need some sort of manifest, though.
The C#, Python, and future projects might need a template in order to hook things up correctly, given any changes to CMake. But… do they even belong in this repository?
Still TODO:
Install
Tests
If you think any of this is wrong, or you want to try something else, let me know.