First install the Anchor dev tools. See book.anchor-lang.com.
Then, install and build all submodules.
make bootstrap
To build the program, run
anchor build
To test the program, run
anchor test
To run a localnet with all the required programs deployed, first build and then run
anchor localnet