Installing wildboar#

There are a few options to install wildboar:

Install the latest release#

Binary distributions are built for MacOS, GNU/Linux and Windows.

pip install wildboar

If you are on a system where users don’t have write accesses to the location of Python packages, the distribution can be installed in the user directory.

pip install --user wildboar

To avoid conflicts with already installed packages, it is strongly recommended to install the package in a virtual environment.

python3 -m venv .venv # create a virtual environment in the folder .venv
source .venv/bin/activate
pip install wildboar

Note

For Debian based distributions python3-venv must be installed for virtual environments to work.

apt install python3-venv

Note

For users of MacOS it is recommended to install python using Homebrew

brew install python

Note

For users of Windows it is recommended to use Anaconda or Miniconda. wildboar is still installed using pip

Build and compile from source#

Building from source is required to use the latest features or to work on new features or pull requests.

  1. Use Git to checkout the latest version

    git clone --depth 10 https://github.com/isaksamsten/wildboar.git
    
  1. Install a c-compiler for Windows, MacOS or GNU/Linux

  2. Optionally create a new virtual environment.

  3. Install the required Python-packages using pip

    pip install -r requirements.txt
    
  4. Build the project in editable mode to ease development

    pip install --verbose --no-build-isolation --editable .
    

    Note

    The environment variable WILDBOAR_BUILD is used to control arguments to the build environment. Setting WILDBOAR_BUILD=optimized can build a version optimized for the current processor architecture.

Platform specific instructions#

Windows#

First install Build tools for Visual Studio 2019

Note

You do not need to install Visual Studio 2019. You only need the Build Tools for Visual Studio 2019, under All downloads -> Tools for Visual Studio 2019.

For 64-bit Python, configure the build environment by running the following commands in cmd console.

SET DISTUTILS_USE_SDK=1
"C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\VC\Auxiliary\Build\vcvarsall.bat" x64

Note

Replace the path with the install path of Visual Studio Build tools.

MacOS#

Install the MacOS command line tools

xcode-select --install

GNU/Linux#

Install build dependencies for Debian-based operating systems, e.g. Ubuntu:

apt install build-essential python3-dev python3-pip