Compiling optiminer for AMD GPUs (Ubuntu/Debian)

This tutorial illustrates how to compile the sgminer fork from Optiminer in order to start Crypto currency mining under a Ubuntu/Debian OS.

Since I took me a while to find all the necessary tools, components and instructions I documented the installation process in this tutorial.

Please let me know if something is not working for you.

Have fun and happy mining!


  • Install necessary base packages to later compile the miner software
apt-get install ocl-icd-opencl-dev libleveldb-dev libminiupnpc-dev libjsoncpp-dev git cmake libcryptopp-dev libleveldb-dev libjsoncpp-dev libjsonrpccpp-dev libboost-all-dev libgmp-dev libreadline-dev libcurl3 libcurl4-gnutls-dev opencl-headers mesa-common-dev libmicrohttpd-dev build-essential automake autoconf libssl-dev libncurses5-dev unzip
  • Download theĀ for or a newer version from [here]
  • Download the AMD-APP-SDKInstaller-v3.0.130.136-GA-linux64.tar.bz2 file or a newer version from [here]
  • Extract the AMD APP SDK and install it into /opt
tar jxvf AMD-APP-SDKInstaller-v3.0.130.136-GA-linux64.tar.bz2
./ --confirm
  • Extract and install the AMD ADL SDK into /opt as well
mkdir /opt/ADL_SDK_V10.2
unzip -d /opt/ADL_SDK_V10.2/
  • Finalize the tutorial with compiling sgminer
export CFLAGS="-O2 -Wall -march=native -I/opt/AMDAPPSDK-3.0/include:/opt/ADL_SDK_V10.2/include" LDFLAGS="-L/opt/AMDAPPSDK-3.0/lib/x86_64"
git clone --recursive && cd sgminer
cp /opt/ADL_SDK_V10.2/include/* ADL_SDK/
make -j4