Building

Minimal Requirements

  • GNU C >= 5.1

  • GNU make >= 3.81

  • libtool

  • pkg-config

  • linux-headers

  • check1

  • sphinx2

  • doxygen2

  • breathe2

  • sphinx_rtd_theme2

  • latex3

1

Optional: needed only for userspace library tests

2(1,2,3,4)

Optional: needed only to build the documentation

3

Optional: needed only to build the pdf documentation

Development Requirements

The following dependencies are needed in case of development build:

  • autotools-dev

  • autoconf

  • automake

  • git

  • cppcheck4

4

Optional: needed only for userspace library static code analysis

Build

$ ./configure [OPTION]... [VAR=VALUE]... && make [TARGET]...

To assign environment variables (e.g., CC, CFLAGS…), specify them as VAR=VALUE. See below for descriptions of some of the useful variables.

Options

--enable-examples

Enable examples build

--enable-benchmark

Enable benchmark build

--enable-docs

Enable documentation build

--prefix=PREFIX

Install architecture-independent files in PREFIX; default to /usr/local

--exec-prefix=EPREFIX

Install architecture-dependent files in EPREFIX; default to PREFIX

--bindir=DIR

User executables; default to $EPREFIX/bin

--libdir=DIR

Object code libraries; default to $EPREFIX/lib

--includedir=DIR

C header files; default to $PREFIX/include

--datarootdir=DIR

Read-only architecture-independent data root; default to $PREFIX/share

--datadir=DIR

Read-only architecture-independent data; default to $DATAROOTDIR

--docdir=DIR

Documentation root; default to $DATAROOTDIR/doc/linux-ums

--htmldir=DIR

Html documentation; default to $DOCDIR

--pdfdir=DIR

Pdf documentation; default to $DOCDIR

--build=BUILD

Configure for building on BUILD; guessed by default

--host=HOST

Cross-compile to build programs to run on HOST; default to $BUILD

--enable-silent-rules

Less verbose build output (undo: make V=1)

--disable-silent-rules

Verbose build output (undo: make V=0)

Variables

Some influential environment variables:

CC

C compiler command

CFLAGS

C compiler flags

LDFLAGS

Linker flags

LIBS

Libraries to pass to the linker

CPPFLAGS

C preprocessor flags

LT_SYS_LIBRARY_PATH

User-defined run-time library search path.

CPP

C preprocessor

Targets

check

Run code check

html

Build the html documentation

pdf

Build the pdf documentation

install

Install into the system

installcheck

Install tests into the system

uninstall

Uninstall from the system

clean

Delete all files in the current directory that are normally created by building the program

distclean

Delete all files in the current directory that are created by configuring or building the program

Minimal installation steps

$ ./configure
$ make
$ make check
$ sudo make install
$ sudo ldconfig
$ sudo modprobe ums