Skip to content

Building

Douglas Kosovic edited this page May 25, 2017 · 21 revisions

This page will show all the required steps primarily on Ubuntu 16.04 (or later) to build and install NetworkManager-l2tp, although it has interspersed notes that are applicable to other Linux distributions and versions.

Note: the backslash characters \ that appear in the below examples are shell line continuation characters that are safe to copy and paste to the command-line.

Prerequisites

Issue the following on the command-line to install the prerequisite build-time and run-time packages :

sudo apt install \
build-essential \
git \
intltool \
libtool \
network-manager-dev \
libnm-util-dev \
libnm-glib-dev \
libnm-glib-vpn-dev \
libnm-gtk-dev \
libnm-dev \
libnma-dev \
ppp-dev \
libdbus-glib-1-dev \
libsecret-1-dev \
libgtk-3-dev \
libglib2.0-dev \
xl2tpd \
strongswan

Note: libnma is only available and needed on NetworkManager 1.2 and later based Linux distributions.

Obtain the source code

We'll use Git to obtain the latest copy of the source code and then cd into the top level directory (which the subsequent examples assume) :

git clone https://github.com/nm-l2tp/network-manager-l2tp.git
cd network-manager-l2tp

Note: if you are using a NetworkManager 0.9 or 1.0 based Linux distribution, switch to the nm-1-0 branch with the following:

git checkout nm-1-0 

Configuration

As mentioned in the README.md file, issue the following on Ubuntu (AMD64, i.e. x86-64):

./autogen.sh
./configure \
  --disable-static --prefix=/usr \
  --sysconfdir=/etc --libdir=/usr/lib/x86_64-linux-gnu \
  --libexecdir=/usr/lib/NetworkManager \
  --localstatedir=/var \
  --with-pppd-plugin-dir=/usr/lib/pppd/2.4.7

Note: if you are using 32bit Ubuntu, remove --libdir=/usr/lib/x86_64-linux-gnu from the above. Note: for other Linux distribution configure examples, see the README.md file.

Building

Issue the following :

make

Installation

Issue the following :

sudo make install
Clone this wiki locally