How to install cpp libraries with Bazel
Background
I wanted to install RE2
but, to install with make
command(explained on RE2 README.md) on Mac takes a lot of time after changing installation config several times.
and failed to install on linux for building x86 ‘.so’ file
What is Bazel
Bazel is a high-performance build and test tool developed by Google. It is designed to support large-scale software projects across multiple languages and platforms. Bazel allows developers to efficiently manage and build complex codebases by using caching, parallel execution, and sandboxing. It supports languages like C++, Java, Python, and more, and is known for its speed, scalability, and reproducibility of builds. Bazel can handle dependencies automatically and works well in environments with frequent code changes, making it ideal for large, distributed teams.
install
https://bazel.build/install
brew install bazel
How to build RE2
it contains bazel config files.
bazel build //:re2