File: README.md

package info (click to toggle)
liblouis 3.36.0-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 86,248 kB
  • sloc: ansic: 37,162; makefile: 1,298; python: 772; lisp: 390; sh: 339; perl: 221; cpp: 21
file content (54 lines) | stat: -rw-r--r-- 1,909 bytes parent folder | download | duplicates (2)
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
54
# Liblouis Python ctypes bindings

These bindings allow you to use liblouis from within Python. The
package is called "louis". See the documentation included in the
module for usage instructions.

These bindings use `ctypes` to access the liblouis shared library. The
liblouis shared library needs to be located in the library search
path. In most cases, if liblouis has been installed in a standard
location on your system, this is already the case and the bindings
will work without any additional steps.

A standard `pyproject.toml` script is provided for installation
tasks. To install this package for system wide use, after installing
`liblouis` itself, switch to the `python` directory and run (as root):

``` python
sudo pip install .
```

Some tests are located in `tests`. Note that these require that
you have compiled `liblouis` with support for 32-bit Unicode
characters.  See the top-level README for instructions on this option.

Remain in the `python` directory and run the tests with the
following command.  If successful, output will be brief, and note
that some tests are designed to have "expected failures".

``` console
sudo python3 tests/test_louis.py
```

## Python Virtual Environment

If you have a Python virtual environment created with the
Python `venv` module, follow these instructions to make
the `louis` module available in your virtual environment.

*  If your Python is at version 3.12 or newer, the `distutils`
module is deprecated.  You can make it available via a PIP
package with a command in your virtual environment like
```console
pip3 install setuptools
```
*  First, make yourself root or super-user with an
`su` or `sudo -s` command.
*  Then, activate your virtual environment.
*  Now do as above, but without `sudo`, since you are
already root.
```console
python3 setup.py install
```
*  You can now run the tests, as above, from within
your virtual environemnt.