|
| 1 | +# JACK (for Rust) |
1 | 2 |
|
2 |
| -# Table of Contents |
| 3 | +Rust bindings for [JACK Audio Connection Kit](<https://jackaudio.org>). |
3 | 4 |
|
4 |
| -1. [Overview](#Overview-9s7h6d81ktj0) |
5 |
| -2. [Testing](#Testing-7y451e81ktj0) |
6 |
| - 1. [Possible Issues](#TestingPossibleIssues-8u551e81ktj0) |
| 5 | +| [](https://crates.io/crates/jack) | [](https://opensource.org/licenses/MIT) | |
| 6 | +|-----------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------| |
| 7 | +| [](https://docs.rs/jack) | [](https://github.com/RustAudio/rust-jack/actions/workflows/testing.yml) | |
| 8 | +| | [:heart: Sponsor](<https://github.com/sponsors/wmedrano>) | |
7 | 9 |
|
8 |
| -- [](https://opensource.org/licenses/MIT) |
9 |
| -- [](https://github.com/RustAudio/rust-jack/actions) |
10 |
| -- [](https://crates.io/crates/jack) |
11 |
| -- [](https://docs.rs/jack) |
| 10 | +## Using JACK |
12 | 11 |
|
13 | 12 |
|
14 |
| -<a id="Overview-9s7h6d81ktj0"></a> |
| 13 | +The JACK server is usually started by the user or system. Clients can request |
| 14 | +that the JACK server is started on demand when they connect, but this can be |
| 15 | +disabled by creating a client with the `NO_START_SERVER` option. |
15 | 16 |
|
16 |
| -# Overview |
17 |
| - |
18 |
| -Rust bindings for the [JACK Audio Connection Kit](<https://jackaudio.org>). These bindings work on every |
19 |
| -operating system that JACK does. |
20 |
| - |
21 |
| -The JACK server is usually started by the user or system. Clients can request that the JACK server is |
22 |
| -started on demand when they connect, but this can be disabled by the user and is the recommended |
23 |
| -configuration. |
24 |
| - |
25 |
| -- Linux and BSD users may install JACK1, JACK2, or Pipewire JACK from their |
26 |
| - system package manager. |
27 |
| -- Windows users may install JACK from the |
28 |
| - |
29 |
| -[official website](<http://jackaudio.org/downloads/>) or |
30 |
| -[Chocolatey](<https://community.chocolatey.org/packages/jack>). |
31 |
| - |
32 |
| -- macOS users may install JACK from the [official website](<http://jackaudio.org/downloads/>) or |
33 |
| - |
34 |
| -[Homebrew](<https://formulae.brew.sh/formula/jack>). |
35 |
| - |
36 |
| -[:heart: Sponsor](<https://github.com/sponsors/wmedrano>) |
| 17 | +- Linux and BSD users may install JACK1, JACK2 (preferred for low latency), or |
| 18 | + Pipewire JACK (preferred for ease of use) from their system package manager. |
| 19 | +- Windows users may install JACK from the [official |
| 20 | + website](<http://jackaudio.org/downloads/>) or [Chocolatey](<https://community.chocolatey.org/packages/jack>). |
| 21 | +- MacOS users may install JACK from the [official |
| 22 | + website](<http://jackaudio.org/downloads/>) or [Homebrew](<https://formulae.brew.sh/formula/jack>). |
37 | 23 |
|
38 | 24 | Refer to the [documentation](<https://docs.rs/jack/>) for details about the API, building, and packaging.
|
39 | 25 | Also take a look at the `examples` directory for usage.
|
40 | 26 |
|
41 | 27 |
|
42 |
| -<a id="Testing-7y451e81ktj0"></a> |
43 |
| - |
44 | 28 | # Testing
|
45 | 29 |
|
46 | 30 | Testing requires setting up a dummy server and running the tests using a single
|
| 31 | +thread. `rust-jack` automatically configures `cargo nextest` to use a single |
47 | 32 | thread.
|
48 | 33 |
|
49 | 34 | ```sh
|
50 | 35 | # Set up a dummy server for tests. The script is included in this repository.
|
51 | 36 | ./dummy_jack_server.sh &
|
52 |
| -# Run tests with limited concurrency. Optionally, `cargo nextest run` is set up |
53 |
| -# to run single threaded by default. |
54 |
| -RUST_TEST_THREADS=1 cargo test |
55 |
| - |
| 37 | +# Run tests |
| 38 | +cargo nextest run |
56 | 39 | ```
|
57 | 40 |
|
58 |
| -**Note**: We use a single thread for tests since too many client instantiations |
59 |
| -in short periods of time cause some unit tests to interact negatively with each |
60 |
| -other. Additionally the JACK server may become flaky. |
61 |
| - |
| 41 | +Note: If cargo nextest is not available, use `RUST_TEST_THREADS=1 cargo test` to |
| 42 | +run in single threaded mode. |
62 | 43 |
|
63 |
| -<a id="TestingPossibleIssues-8u551e81ktj0"></a> |
64 | 44 |
|
65 | 45 | ## Possible Issues
|
66 | 46 |
|
|
0 commit comments