BFG Miner project page: https://github.com/luke-jr/bfgminer
Bitcoin needs to be installed. Make sure dependencies, xcode etc. are installed: https://gist.github.com/luke-jr/7539234 (if you built Bitcoin on the same machine you should be fine).
$ git clone [email protected]:luke-jr/bfgminer.git
$ cd bfgminer
$ ./autogen.sh
$ ./configure --enable-cpumining
$ make
First start bitcoind
$ bitcoind --testnet
Then start the miner from the build
$ ./bfgminer -o http://localhost:18332 -u USERNAME -p PASSWORD --generate-to YOURBITCOINADDRESS --coinbase-sig "testnet > bcash" --cpu-threads 1 -S cpu:auto
Here is an easily digestable explanation of the interface: https://www.youtube.com/watch?v=FSjhwsuQTxM