Where should I put third-party libraries?

后端 未结 3 1801
慢半拍i
慢半拍i 2021-02-05 16:46

I contribute to a decent-sized C++ project with a number of dependencies. The problem is, the project contains the source of all of its dependencies (e.g. pcre, zlib, etc.). I w

3条回答
  •  野性不改
    2021-02-05 17:01

    I've seen groups do the following:

    • Separate internal code from external code (code they made vs external companies)
    • Separate their code from library code
    • Separate each program and each library
    • Check in a compiled version of their dependencies, so it isn't a part of their full build cycle (at least, not in some branches. Other branches might do a more complete build)

    Projects existed for each exe or library, in the directory with the exe/library.

    Solutions existed wherever the teams felt it would be beneficial, and binaries were often linked, rather than their projects included in the sub-solutions. Only a full build was guaranteed not to break on a fresh enlistment.

    Caveat emptor...

提交回复
热议问题