---
title: "Compiling programs"
date: "2014-12-02"
category: "terminal"
slug: "compiling-programs"
---

Accounts with [[is-terminal-access-available]] can compile and install custom programs. All custom programs must be installed under `/usr/local`.

## Language-Specific Notes

### C/C++

Set the install prefix during configuration:

```
./configure --prefix=/usr/local && make && make install
```

The prefix is handled by [autoconf](https://www.gnu.org/software/autoconf/) and [make/gmake](http://www.gnu.org/software/make/) as part of the [GNU toolchain](http://en.wikipedia.org/wiki/GNU_toolchain).

Some applications do not use autoconf and instead require [editing](https://www.freebsd.org/doc/en/books/porters-handbook/porting-prefix.html) `DESTDIR` or `PREFIX` directly in the bundled `Makefile`.

### PHP, Ruby, Python, Perl

These languages automatically install to the correct location without additional configuration.

## See Also

[[listening-ports]]
