sccn / lsl_archived

Multi-modal time-synched data transmission over local network

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

integrating 3rd party library updates into CMake/CI

dmedine opened this issue · comments

How? Programmatically, I mean.

I have some library updates from Brain Products and I'd like to get them into the build structure somehow. Are we still relying on the SCCN ftp to store the 3rd party dependencies?

Since none of us have access to SCCN's ftp anymore, it is time to move away from that. Github releases looks like it will work to me: https://help.github.com/articles/distributing-large-binaries/ https://help.github.com/articles/about-releases/ If that isn't good enough, I'd go to Amazon file hosting next. If there is a cost, I could take care of it.

If you're talking about storage, this is one of the great benefits of separating the repos.
https://github.com/labstreaminglayer/App-BrainProducts/
Create a release, then you can attach binaries in the release. This is outlined in the link from Matthew.

If you're talking about how to get CMake to download them, that's also pretty easy to do.
Use cmake ExternalProject_Add to create a target.

Then you have several ways to trigger that target.

  • You can trigger its download during configure (see here).
  • You can make your real target dependent on it using add_dependencies(${target} ${ext_name}) which will cause the external target to be executed (download, build if necessary) during the build phase of the ${target}.
    • You will have to tell developers to first attempt to build the executable to download the headers they need for proper development.
  • You can create a new target called something like "get-deps" that depends on the external target, then tell users to first call cmake --build . --target get-deps (or use the IDE equivalent of right-clicking on the get-deps target and building that).