|
1 |
| -Install |
2 |
| ------------ |
| 1 | +Installation |
| 2 | +============ |
3 | 3 |
|
4 |
| -Linux (Debian) |
5 |
| -^^^^^^^^^^^^^^ |
| 4 | +``xmlsec`` is available on PyPI: |
6 | 5 |
|
7 | 6 | .. code-block:: bash
|
8 | 7 |
|
9 |
| - apt-get install libxml2-dev libxmlsec1-dev libxmlsec1-openssl |
10 |
| - pip install xmlsec |
| 8 | + pip install xmlsec |
11 | 9 |
|
| 10 | +Depending on your OS, you may need to install the required native |
| 11 | +libraries first: |
12 | 12 |
|
13 |
| -Note: There is no required version of libxml2 for ubuntu precise, |
14 |
| -so need to download and install it manually. |
| 13 | +Linux (Debian) |
| 14 | +-------------- |
15 | 15 |
|
16 | 16 | .. code-block:: bash
|
17 | 17 |
|
18 |
| - wget http://xmlsoft.org/sources/libxml2-2.9.1.tar.gz |
19 |
| - tar -xvf libxml2-2.9.1.tar.gz |
20 |
| - cd libxml2-2.9.1 |
21 |
| - ./configure && make && make install |
| 18 | + apt-get install libxml2-dev libxmlsec1-dev libxmlsec1-openssl |
| 19 | +
|
| 20 | +.. note:: There is no required version of LibXML2 for Ubuntu Precise, |
| 21 | + so you need to download and install it manually: |
| 22 | + |
| 23 | + .. code-block:: bash |
| 24 | +
|
| 25 | + wget http://xmlsoft.org/sources/libxml2-2.9.1.tar.gz |
| 26 | + tar -xvf libxml2-2.9.1.tar.gz |
| 27 | + cd libxml2-2.9.1 |
| 28 | + ./configure && make && make install |
22 | 29 |
|
23 | 30 |
|
24 | 31 | Linux (CentOS)
|
25 |
| -^^^^^^^^^^^^^^ |
| 32 | +-------------- |
26 | 33 |
|
27 | 34 | .. code-block:: bash
|
28 | 35 |
|
29 |
| - yum install libxml2-devel xmlsec1-devel xmlsec1-openssl-devel libtool-ltdl-devel |
30 |
| - pip install xmlsec |
| 36 | + yum install libxml2-devel xmlsec1-devel xmlsec1-openssl-devel libtool-ltdl-devel |
| 37 | +
|
| 38 | +
|
| 39 | +Linux (Fedora) |
| 40 | +-------------- |
| 41 | + |
| 42 | +.. code-block:: bash |
| 43 | +
|
| 44 | + dnf install libxml2-devel xmlsec1-devel xmlsec1-openssl-devel libtool-ltdl-devel |
31 | 45 |
|
32 | 46 |
|
33 | 47 | Mac
|
34 |
| -^^^ |
| 48 | +--- |
35 | 49 |
|
36 | 50 | .. code-block:: bash
|
37 | 51 |
|
38 |
| - xcode-select --install |
39 |
| - brew upgrade |
40 |
| - brew install libxml2 libxmlsec1 pkg-config |
41 |
| - pip install xmlsec |
| 52 | + xcode-select --install |
| 53 | + brew upgrade |
| 54 | + brew install libxml2 libxmlsec1 pkg-config |
42 | 55 |
|
43 | 56 |
|
| 57 | +Alpine |
| 58 | +------ |
44 | 59 |
|
45 |
| -Windows (Wheel) |
46 |
| -^^^^^^^^^^^^^^^ |
| 60 | +.. code-block:: bash |
47 | 61 |
|
48 |
| -#. Download appropriate binary wheels from `appveyor <https://ci.appveyor.com/project/bgaifullin/python-xmlsec>`_ (see build`s artifacts). |
| 62 | + apk add build-base libressl libffi-dev libressl-dev libxslt-dev libxml2-dev xmlsec-dev xmlsec |
49 | 63 |
|
50 |
| -#. Install downloaded wheel |
51 | 64 |
|
52 |
| - .. code-block:: bash |
| 65 | +Troubleshooting |
| 66 | +*************** |
53 | 67 |
|
54 |
| - pip install <downloaded wheel filename> |
| 68 | +Mac |
| 69 | +--- |
55 | 70 |
|
| 71 | +If you get any fatal errors about missing ``.h`` files, update your |
| 72 | +``C_INCLUDE_PATH`` environment variable to include the appropriate |
| 73 | +files from the ``libxml2`` and ``libxmlsec1`` libraries. |
56 | 74 |
|
57 |
| -Windows (pip) |
58 |
| -^^^^^^^^^^^^^ |
59 | 75 |
|
60 |
| -#. Configure build environment, see `wiki.python.org <https://wiki.python.org/moin/WindowsCompilers>`_ for more details. |
| 76 | +Windows |
| 77 | +------- |
| 78 | + |
| 79 | +Starting with 1.3.7, prebuilt wheels are available for Windows, |
| 80 | +so running ``pip install xmlsec`` should suffice. If you want |
| 81 | +to build from source: |
61 | 82 |
|
62 |
| -#. Install from pip |
| 83 | +#. Configure build environment, see `wiki.python.org <https://wiki.python.org/moin/WindowsCompilers>`_ for more details. |
63 | 84 |
|
64 |
| - .. code-block:: bash |
| 85 | +#. Install from source dist: |
65 | 86 |
|
66 |
| - pip install xmlsec |
| 87 | + .. code-block:: bash |
67 | 88 |
|
| 89 | + pip install xmlsec --no-binary=xmlsec |
0 commit comments