Building Envoy isn't all that hard. We have to use Bazel / Bazelisk for the process. Here are the steps summarized for quick reference:
cd ~/Downloads
wget https://github.com/bazelbuild/bazelisk/releases/latest/download/bazelisk-linux-amd64:
sudo mv ~/Downloads/bazelisk-linux-amd64 /usr/local/bin/bazel
sudo chmod +x /usr/local/bin/bazel
Install / upgrade some local packages:
sudo apt install autoconf libtool curl patch python3-pip unzip virtualenv
Download Envoy source code:
mkdir -p github.com/envoyproxy
git clone https://amukherj@github.com/envoyproxy/envoy
Download and install clang+llvm:
wget https://github.com/llvm/llvm-project/releases/download/llvmorg-16.0.0/clang+llvm-16.0.0-x86_64-linux-gnu-ubuntu-18.04.tar.xz
tar xf -C tools clang+llvm-16.0.0-x86_64-linux-gnu-ubuntu-18.04.tar.xz
ln -s clang+llvm-16.0.0-x86_64-linux-gnu-ubuntu-18.04 ~/devel/tools/clang+llvm
Install additional go utilities:
go install github.com/bazelbuild/buildtools/buildifier@latest
export BUILDIFIER_BIN=/home/amukher1/devel/go/bin/buildifier
go install github.com/bazelbuild/buildtools/buildozer@latest
export BUILDOZER_BIN=/home/amukher1/devel/go/bin/buildozer
Build the code. This step can take well over an hour, depending on your machine resources.
bazel build envoy
Read more!