Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build process improvements to facilitate offline builds #441

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

Cimbali
Copy link

@Cimbali Cimbali commented Nov 23, 2023

I have a build process where the system is required to be offline (I think it’s the case for many distros package building?). While it’s easy enough to vendor all the go and vcpkg dependencies, I’m proposing 2 changes here in the build configuration which change nothing to the current process but greatly facilitate building offline.

  1. Enable cmake to not download googletests from cmake but instead look for it on the system. This is also setting INSTALL_GTEST to OFF to avoid installing test files.
  2. Stop cmake from looking for a vcpkg binary during CMake as it’s only used before in build.sh/build.ps1. As long as the dependent libraries are found (downloaded from build scripts, or in my case vendored) no additional checks are needed. Similarly I moved the toolchain file definition to said build script.

Requires renaming to proper dependency name and adding FIND_PACKAGE_ARGS
argument

This allows to avoid downloading on offline build systems.
Also don’t include googletest framework in install bundle (!)
Allows to simplify vendoring for offline build. Toolchain configuration
set from build scripts where vcpkg is already used.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant