Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update INSTALL.md #667

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
59 changes: 45 additions & 14 deletions INSTALL.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,50 @@
# Installation
* [Dependencies](#dependencies)
* [OS X Notes](#os-x-notes)
* [FreeBSD](#freebsd)
* [Debian](#debian)
* [Fedora](#fedora)
* [Arch](#arch)
* [MacOS](#macos)
* [Windows](#windows)
* [Compiling](#compiling)
* [Dependencies](#dependencies)
* [Documentation](#documentation)
* [OS X Notes](#os-x-notes)
* [FreeBSD Notes](#freebsd-notes)
* [Notes](#notes)
* [Compilation variables](#compilation-variables)
* [Environment variables](#environment-variables)

## Dependencies

## FreeBSD
```
pkg install toxic
```

## Debian
```
sudo apt install toxic
```

## Fedora
No dnf repo, install from source

## Arch
```
sudo pacman -S toxic
```

## MacOS
Not in brew, install from source.

## Windows
Not supported.

## Compiling
```
make
sudo make install
```
### Dependencies
| Name | Needed by | Debian package |
|------------------------------------------------------|----------------------------|---------------------|
| [Tox Core](https://github.com/toktok/c-toxcore) | BASE | libtoxcore-dev |
Expand All @@ -25,18 +62,12 @@

<sup>1</sup>: see [Documentation](#documentation)

## Compiling
```
make
sudo make install
```

#### Documentation
### Documentation
Run `make doc` in the build directory after editing the asciidoc files to regenerate the manpages.<br />
**Note for developers**: asciidoc files and generated manpages will need to be committed together.<br />
**Note for everyone**: [asciidoc](http://asciidoc.org/index.html) (and this step) is only required for regenerating manpages when you modify them.

#### OS X Notes
### OS X Notes
Using [Homebrew](http://brew.sh):
```
brew install curl qrencode openal-soft freealut libconfig libpng
Expand All @@ -46,7 +77,7 @@ export PKG_CONFIG_PATH=/usr/local/opt/openal-soft/lib/pkgconfig
make
```

#### FreeBSD Notes
### FreeBSD Notes
To compile Toxic on FreeBSD you'll need to use `gmake` instead of `make`, and you may need to manually tell `pkg-config` where to find the toxcore library.
In order to build with audio/video support you'll need to install the [v4l_compat](https://www.freshports.org/multimedia/v4l_compat) port.

Expand All @@ -59,7 +90,7 @@ sudo -E gmake install

## Notes

#### Compilation variables
### Compilation variables
* You can add specific flags to the Makefile with `USER_CFLAGS=""` and `USER_LDFLAGS=""` passed as arguments to make, or as environment variables
* Default compile options can be overridden by using special variables:
* `DISABLE_X11=1` → Disable X11 support (needed for video and window focus tracking)
Expand All @@ -76,7 +107,7 @@ sudo -E gmake install

* `DESTDIR=""` Specifies the base install directory for binaries and data files (e.g.: DESTDIR="/tmp/build/pkg")

#### Environment variables
### Environment variables
* You can use the `CFLAGS` and `LDFLAGS` environment variables to add specific flags to the Makefile
* The `PREFIX` environment variable specifies a base install directory for binaries and data files. This is interchangeable with the `DESTDIR` variable, and is generally used by systems that have the `PREFIX` environment variable set by default.<br />
**Note**: `sudo` does not preserve user environment variables by default on some systems. See the `sudoers` manual for more information.