Building Pelago from source, and checking that it works, is described in the documentation.
Install Pelago