Download source code from git repository$ git clone https://github.com/ethereum-mining/ethminer.git
Go to the source code directory$ cd ethminer
Create a build directory$ mkdir build; cd build
Configure the project with CMake$ cmake ..
If you have NVidia GPU(s), you need to add more options$ cmake .. -DETHASHCUDA=ON
Build the project using CMake Build Tool Mode$ cmake --build .
you are welcome!