1 # ArrayFire Installer {#installing}
3 Installing ArrayFire couldn't be easier. Navigate to
4 https://arrayfire.com/download and download the installer for your architecture
5 and operating system. Although you could [build ArrayFire from
6 source](https://github.com/arrayfire/arrayfire), we recommend using our
7 installers as we have packaged together all of the necessary dependencies to
8 give you the best performance.
10 We provide installers for Windows, Linux, and macOS. There are two installers
11 for each operating system: one with graphics support and the other without
12 graphics support. Download the installer with graphics support if you would like
13 to be able to do high performance visualizations using our
14 [Forge](https://github.com/arrayfire/forge) library. Otherwise, download the
15 installer without graphics support.
17 Make sure you have the latest device drivers installed on your system before
18 using ArrayFire. If you are going to be targeting the CPU using ArrayFire’s
19 OpenCL backend, you will need to have the OpenCL **runtime** installed on your
20 system. Drivers and runtimes should be downloaded and installed from your device
23 # Install Instructions
29 ## <a name="Windows"></a> Windows
31 Prior to installing ArrayFire on Windows,
32 [download](https://www.microsoft.com/en-in/download/details.aspx?id=48145)
33 install the Visual Studio 2015 (x64) runtime libraries.
35 Once you have downloaded the ArrayFire installer, execute the installer as you
36 normally would on Windows. If you choose not to modify the path during the
37 installation procedure, you'll need to manually add ArrayFire to the path for
38 all users. Simply append `%AF_PATH%/lib` to the PATH variable so that the loader
39 can find ArrayFire DLLs.
41 For more information on using ArrayFire on Windows, visit the following
42 [page](http://arrayfire.org/docs/using_on_windows.htm).
44 ## <a name="Linux"></a> Linux
46 Once you have downloaded the ArrayFire installer, execute the installer from the
47 terminal as shown below. Set the `--prefix` argument to the directory you would
48 like to install ArrayFire to - we recommend `/opt`.
50 ./Arrayfire_*_Linux_x86_64.sh --include-subdir --prefix=/opt
52 Given sudo permissions, you can add the ArrayFire libraries via `ldconfig` like
55 echo /opt/arrayfire/lib > /etc/ld.so.conf.d/arrayfire.conf
58 Otherwise, you will need to set the `LD_LIBRARY_PATH` environment variable in
59 order to let your shared library loader find the ArrayFire libraries.
61 For more information on using ArrayFire on Linux, visit the following
62 [page](http://arrayfire.org/docs/using_on_linux.htm).
66 ArrayFire allows you to do high performance visualizations via our
67 [Forge](https://github.com/arrayfire/forge) library. On Linux, there are a few
68 dependencies you will need to install to enable graphics support:
72 GLU (OpenGL Utility Library)
74 We show how to install these dependencies on common Linux distributions:
76 __Debian, Ubuntu (14.04 and above), and other Debian derivatives__
78 apt install build-essential libfreeimage3 libfontconfig1 libglu1-mesa
80 __Fedora, Redhat, CentOS__
82 yum install freeimage fontconfig mesa-libGLU
85 ## <a name="macOS"></a> macOS
87 Once you have downloaded the ArrayFire installer, execute the installer by
88 either double clicking on the ArrayFire `pkg` file or running the following
89 command from your terminal:
91 sudo installer -pkg Arrayfire-*_OSX.pkg -target /
93 For more information on using ArrayFire on macOS, visit the following
94 [page](http://arrayfire.org/docs/using_on_osx.htm).
96 ## NVIDIA Tegra devices
98 ArrayFire is capable of running on TX1 and TX2 devices. The TK1 is no longer
101 Prior to installing ArrayFire, make sure you have the latest version of JetPack
102 (v2.3 and above) or L4T (v24.2 and above) on your device.
104 ### Tegra prerequisites
106 The following dependencies are required for Tegra devices:
108 sudo apt install libopenblas-dev liblapacke-dev
110 ## Testing installation
112 After ArrayFire is finished installing, we recommend building and running a few
113 of the provided examples to verify things are working as expected.
115 On Unix-like systems:
117 cp -r /opt/arrayfire/share/ArrayFire/examples /tmp/examples
121 cmake -DASSETS_DIR:PATH=/tmp ..
123 ./helloworld/helloworld_{cpu,cuda,opencl}
125 On Windows, open the CMakeLists.txt file from CMake-GUI and set `ASSETS_DIR`
126 variable to the parent folder of examples folder. Once the project is configured
127 and generated, you can build and run the examples from Visual Studio.
129 ## <a name="GettingHelp"></a> Getting help
131 * Google Groups: https://groups.google.com/forum/#!forum/arrayfire-users
132 * ArrayFire Services: [Consulting](https://arrayfire.com/consulting/) | [Support](https://arrayfire.com/support/) | [Training](https://arrayfire.com/training/)
133 * ArrayFire Blogs: http://arrayfire.com/blog/
134 * Email: <mailto:technical@arrayfire.com>