source: CLRX/CLRadeonExtender/trunk/INSTALL @ 3835

Last change on this file since 3835 was 3835, checked in by matszpk, 14 months ago

CLRadeonExtender: Update README and INSTALL: add info about needed tools to build documentation.

File size: 4.6 KB
Line 
1-----------------------------------------------------------------------
2                               CLRadeonExtender
3-----------------------------------------------------------------------
4
51. Installation prerequisities.
6
7CLRadeonExtender doesn't require many libraries and dependencies.
8It can be installed on the 32-bit/64-bit machines.
9Currently, the OpenCL support for AMD Catalyst (for the OpenCL applications)
10is disabled by default (enablement is not recommended in current development
11stage).
12
13This package provides source code and requires:
14
15* C++11 compliant compiler (Clang++ or GCC 4.7 or later, MSVC 2015 or later)
16* any build system supported by CMake (GNU make, NMake, Visual Studio, ...)
17* CMake system (2.8 or later)
18* Threads support (for Linux, recommended NPTL)
19* Unix-like (Linux or BSD) system or Windows system
20
21Optionally for clwrapper (an OpenCL wrapper that replaces AMD Catalyst driver
22behaviour) requires:
23
24* libOpenCL.so or OpenCL.dll
25* OpenCL ICD (for example from AMD Catalyst driver)
26* AMD Catalyst driver or AMDGPU-PRO driver
27
28and documentation requires:
29
30* pod2man utility for Unix manuals
31* markdown_py utility for CLRX Documentation
32* Doxygen for CLRX API Documentation
33
34These utilities is working with the OpenCL kernel binaries compiled for the
35Radeon GPU's based on GCN 1.0/1.1/1.2 architecture. Any binaries compiled
36for older Radeons (VLIW architecture) has not been handled.
37
382. Compilation
39
40To build system you should create the build directory in source code package:
41
42  mkdir build
43
44and run:
45
46  cmake .. [cmake options]
47
48Optional CMake configuration options for build:
49
50CMAKE_BUILD_TYPE - type of build (Release, Debug, GCCSan, GCCSSP).
51CMAKE_INSTALL_PREFIX - prefix for installation (for example '/usr/local')
52BUILD_32BIT - build also 32-bit binaries
53BUILD_TESTS - build all tests
54BUILD_SAMPLES - build OpenCL samples
55BUILD_DOCUMENTATION - build project documentation (doxygen, unix manuals, user doc)
56BUILD_DOXYGEN - build doxygen documentation
57BUILD_MANUAL - build Unix manual pages
58BUILD_CLRXDOC - build CLRX user documentation
59BUILD_STATIC_EXE - build with statically linked executables
60GCC5CXX11NEWABI - build with new GCC5 C++11 ABI
61NO_STATIC - no static libraries
62NO_CLWRAPPER - do not build CLRXWrapper
63CPU_ARCH - target CPU architecture (in GCC parameter to -march, for MSVC
64  parameter to /arch:)
65OPENCL_DIST_DIR - an OpenCL directory distribution installation (optional)
66
67You can just add one or many of these options to cmake command:
68
69  cmake .. -DCMAKE_BUILD_TYPE=Release -DBUILD_TESTS=ON
70
71or for Microsoft Visual C++ (for NMake):
72
73  cmake .. -G "NMake Makefiles" [cmake configuration options]
74
75or for Microsoft Visual C++ (for same Visual Studio)
76
77  cmake .. -G "Visual Studio XXXXXX [arch]" [cmake configuration options]
78
79where XXXX - version of Visual Studio (7, 14 2015, ...).
80arch - architecture (Win64, ARM) (optional).
81
82After creating Makefiles scripts you can compile project:
83
84  make or make -jX - where X is number of processors.
85
86or (for NMake)
87
88  nmake
89
90or just execute build option in Visual Studio.
91
92After building you can check whether project is working (if you will build tests):
93
94  ctest
95 
962.1. Windows and MSVC
97
98CLRadeonExtender has been compiled under Windows 8.1 and Microsoft Visual Studio 2015
99Community version.
100
1013. Installation
102
103Installation is easy. Just run command:
104
105  make install
106
107or (for NMake)
108
109  nmake install
110 
1114. clwrapper
112
113CLWrapper integrates the CLRX assembler with the AMD Catalyst driver by using
114wrapper mechanism and embeds an assembler to AMD OpenCL implementation.
115Building an assembler programs will be possible by passing an '-xasm' option which
116should be appended to build options, like following example:
117
118clBuildProgram(program, num_devices, devices, "-xasm", NULL, NULL);
119
120Installation is easy. However, it requires some changes on an OpenCL configuration:
121
122Remove amdocl64.icd and/or amdocl32.icd (if 32-bit system)
123from directory '/etc/OpenCL/vendors'
124(before, we recommend to make backup that directory).
125Create the 'clrx.icd' file on /etc/OpenCL/vendors/ with content: 'libCLRXWrapper.so'.
126That's all. Now you can call an assembler through clBuildProgram on your applications.
127
128Important Attention: CLWrapper make some changes on the program environment and changes
129behaviour of the OpenCL routines. This is still the experimental stuff and
130we recommend to not using its on the deployed/production systems.
131
132DO NOT FORGET to revert these changes before uninstallation.
133
1345. Uninstallation
135
136In the build directory is the 'install_manifest.txt' file that contains all installed files.
137You can remove these files by using command:
138
139  rm -f `cat install_manifest.txt`
140
141DO NOT FORGET to keep 'build' directory after installation.
Note: See TracBrowser for help on using the repository browser.