forked from VOLTTRON/volttron
-
Notifications
You must be signed in to change notification settings - Fork 0
/
README
53 lines (36 loc) · 1.97 KB
/
README
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
EXTERNAL DEPENDENCIES
A few external dependencies are required to bootstrap the development
environment: essential build tools (gcc, make, autodev-tools, etc.), python
development files (headers), and openssl. On Debian-based systems, these can
all be installed with the following command:
$ sudo apt-get install build-essential python-dev openssl libssl-dev libevent-dev
Please note that if you wish to use cryptographic authentication or
point-to-point encryption, libsodium must also be installed.
However, libsodium is not currently in the official Ubuntu or Debian
repositories, so it must be installed manually or from an unofficial
repository, such as https://launchpad.net/~shnatsel/+archive/dnscrypt.
libsodium source code is found at https://github.com/jedisct1/libsodium.
On Arch Linux, the following command will install the dependencies:
$ sudo pacman -S base-devel python2 openssl libssl-dev libsodium
BUILDING A DEVELOPMENT ENVIRONMENT
To create a development environment, just execute the following in the
project root directory:
$ python2.7 bootstrap.py
That's it! You can now start an interpreter that includes volttron in the
Python path using env/bin/python or run Volttron using env/bin/volttron. The
bootstrap script will also create env/bin/activate which can be sourced to
setup a developer environment with the appropriate paths set. It also creates
a deactivate function to revert the settings.
$ . env/bin/activate
(volttron)$ echo $PATH
... do development work
(volttron)$ deactivate
$ echo $PATH
To update the scripts after modifying setup.py or after a repository update,
use the following command:
$ env/bin/python bootstrap.py
The bootstrap script creates a virtual Python environment, using virtualenv,
and installs volttron as an editable (or developer mode) package using pip.
ADDING PYTHON DEPENDENCIES
To add project dependencies, add the dependent package to the
install_requires list in setup.py and run `env/bin/python bootstrap.py`