#!/usr/bin/env bash
#
# This file is generated by l2tdevtools update-dependencies.py any dependency
# related changes should be made in dependencies.ini.

# Exit on error.
set -e

# Dependencies for running dfvfs, alphabetized, one per line.
# This should not include packages only required for testing or development.
PYTHON2_DEPENDENCIES="libbde-python
                      libewf-python
                      libfsntfs-python
                      libfvde-python
                      libfwnt-python
                      libqcow-python
                      libsigscan-python
                      libsmdev-python
                      libsmraw-python
                      libvhdi-python
                      libvmdk-python
                      libvshadow-python
                      libvslvm-python
                      python-backports.lzma
                      python-crypto
                      python-dfdatetime
                      python-dtfabric
                      python-pysqlite2
                      python-pytsk3
                      python-yaml";

# Additional dependencies for running dfvfs tests, alphabetized,
# one per line.
TEST_DEPENDENCIES="python-mock";

# Additional dependencies for doing dfvfs development, alphabetized,
# one per line.
DEVELOPMENT_DEPENDENCIES="python-sphinx
                          pylint";

# Additional dependencies for doing dfvfs debugging, alphabetized,
# one per line.
DEBUG_DEPENDENCIES="libbde-dbg
                    libbde-python-dbg
                    libewf-dbg
                    libewf-python-dbg
                    libfsntfs-dbg
                    libfsntfs-python-dbg
                    libfvde-dbg
                    libfvde-python-dbg
                    libfwnt-dbg
                    libfwnt-python-dbg
                    libqcow-dbg
                    libqcow-python-dbg
                    libsigscan-dbg
                    libsigscan-python-dbg
                    libsmdev-dbg
                    libsmdev-python-dbg
                    libsmraw-dbg
                    libsmraw-python-dbg
                    libvhdi-dbg
                    libvhdi-python-dbg
                    libvmdk-dbg
                    libvmdk-python-dbg
                    libvshadow-dbg
                    libvshadow-python-dbg
                    libvslvm-dbg
                    libvslvm-python-dbg";

sudo add-apt-repository ppa:gift/dev -y
sudo apt-get update -q
sudo apt-get install -y ${PYTHON2_DEPENDENCIES}

if [[ "$*" =~ "include-debug" ]]; then
    sudo apt-get install -y ${DEBUG_DEPENDENCIES}
fi

if [[ "$*" =~ "include-development" ]]; then
    sudo apt-get install -y ${DEVELOPMENT_DEPENDENCIES}
fi

if [[ "$*" =~ "include-test" ]]; then
    sudo apt-get install -y ${TEST_DEPENDENCIES}
fi
