Get the latest `infer-osx-vXX.tar.xz` from [infer releases](https://github.com/facebook/infer/releases) and run the commands below in your terminal to install Infer.
```bash
tar xf infer-osx-vXX.tar.xz
# this assumes you use bash, adapt to your needs in case you use
Get the latest `infer-linux64-vXX.tar.xz` from [infer releases](https://github.com/facebook/infer/releases) and run the commands below in your terminal to install Infer.
```bash
tar xf infer-linux64-vXX.tar.xz
# this assumes you use bash, adapt to your needs in case you use
To analyse C and ObjC, Infer requires clang and the [facebook-clang-plugin](https://github.com/facebook/facebook-clang-plugins). If you wish to analyse only Java/Android code, then you could skip these dependencies. Details below.
If you do not require support for the C/Objective C analysis in Infer, and only wish to analyse Java files, continue with these instructions. By the way, Java 1.8 is not supported.
```bash
cd infer
make -C infer java
export PATH=`pwd`/infer/bin:$PATH
```
To compile support for both Java and C/Objective C, do this instead.
```bash
cd infer
./update-fcp.sh && ../facebook-clang-plugin/clang/setup.sh && ./compile-fcp.sh # go have a coffee :)
make -C infer
export PATH=`pwd`/infer/bin:$PATH
```
###Linux
These instructions were tested on Linux (64 Bit), on the following distributions: Debian 7, Ubuntu 14.04 and Ubuntu 12.04.4 LTS.
./opam init --comp=4.01.0 #(then say 'y' to the final question)
eval `./opam config env`
./opam install sawja.1.5 atdgen.1.5.0 javalib.2.3 extlib.1.5.4 #(then say 'y' to the question)
```
If you do not require support for the C/Objective C analysis in Infer, and only wish to analyse Java files, continue with these instructions. By the way, Java 1.8 is not supported.
```bash
cd infer
make -C infer java
export PATH=`pwd`/infer/bin:$PATH
```
To compile support for both Java and C/Objective C, do this instead. If your distribution is Ubuntu 12.04.4 LTS, you need to install `gcc 4.8` and `g++ 4.8` as well. Follow the following instructions to do that. You may skip this step in other distributions.