0% found this document useful (0 votes)
156 views2 pages

HCash Mining (Windows)

This document provides instructions for setting up and building a Go miner on Windows with CUDA or OpenCL/ADL support. It lists prerequisites like installing Go, Git, MinGW-w64 and CUDA/APP SDK. It also provides steps for setting environment variables, fetching dependencies, and building the miner project with CUDA, OpenCL, or OpenCL with ADL.

Uploaded by

Orange
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
156 views2 pages

HCash Mining (Windows)

This document provides instructions for setting up and building a Go miner on Windows with CUDA or OpenCL/ADL support. It lists prerequisites like installing Go, Git, MinGW-w64 and CUDA/APP SDK. It also provides steps for setting environment variables, fetching dependencies, and building the miner project with CUDA, OpenCL, or OpenCL with ADL.

Uploaded by

Orange
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 2

Windows

Pre-Requisites

 Download and install the official Go Windows binaries from https://golang.dl/


 Download and install Git for Windows from https://git-for-windows.github.io/
o Make sure to select the Git-Bash option when prompted
 Download the MinGW-w64 installer from https://sourceforge.net/projects/mingw-
w64/files/Toolchains targetting Win32/Personal Builds/mingw-builds/installer/
o Select the x64 toolchain and use defaults for the other questions
 Set the environment variable GOPATH to C:\Users\username\go
 Check that the GOROOT environment variable is set to C:\Go
o This should have been done by the Go installer
 Add the following locations to your PATH: C:\Users\username\go\bin;C:\Go\bin
 Add C:\Program Files\mingw-w64\x84_64-6.2.0-posix-seh-rt_v5-rev1\mingw64\bin to
your PATH (This is the latest release as of 2016-09-29)
 go get github.com/golang/dep/cmd/dep
o You should be able to type dep and get dep's usage display. If not, double check the steps
above
 go get github.com/HcashOrg/gominer
o Compilation will most likely fail which
can be safely ignored for now.
 Change to the gominer directory
o If using the Windows Command Prompt: cd
%GOPATH%/src/github.com/HcashOrg/gominer
o If using git-bash cd $GOPATH/src/github.com/HcashOrg/gominer
 Install dependencies via dep
o dep ensure

Build Instructions

CUDA

Pre-Requisites

 Download Microsoft Visual Studio 2013 from https://www.microsoft.com/en-


us/download/details.aspx?id=44914
 Add C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\bin to your PATH
 Install CUDA 7.0 from https://developer.nvidia.com/cuda-toolkit-70
 Add C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v7.0\bin to your PATH
Steps

 Using git-bash:
o cd $GOPATH/src/github.com/HcashOrg/gominer
o mingw32-make.exe
 Copy dependencies:
o copy obj/HcashOrg.dll .
o copy nvidia/NVSMI/nvml.dll .

OpenCL/ADL

Pre-Requisites

 Download AMD APP SDK v3.0 from http://developer.amd.com/tools-and-sdks/opencl-zone/amd-


accelerated-parallel-processing-app-sdk/
o Samples may be unselected from the install to save space as only the libraries and headers are
needed
 Copy or Move C:\Program Files (x86)\AMD APP SDK\3.0 to C:\appsdk
o Ensure the folders C:\appsdk\include and C:\appsdk\lib are populated
 Change to the library directory C:\appsdk\lib\x86_64
o cd C:\appsdk\lib\x86_64
 Copy and prepare the ADL library for linking
o copy c:\Windows\SysWOW64\atiadlxx.dll .
o gendef atiadlxx.dll
o dlltool --output-lib libatiadlxx.a --input-def atiadlxx.def

Steps

 For OpenCL:
o go build -tags opencl
 For OpenCL with AMD Device Library (ADL) support:
o go build -tags opencladl

You might also like