You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
# echo "deb [arch=arm64,riscv64,amd64] http://mirror.aarnet.edu.au/pub/ubuntu/ports/ jammy main" | sudo tee -a /etc/apt/sources.list
65
+
# echo "deb [arch=arm64,riscv64,amd64] http://mirror.aarnet.edu.au/pub/ubuntu/ports/ jammy-updates main" | sudo tee -a /etc/apt/sources.list
66
+
# echo "deb [arch=arm64,riscv64,amd64] http://mirror.aarnet.edu.au/pub/ubuntu/ports/ jammy universe" | sudo tee -a /etc/apt/sources.list
67
+
# echo "deb [arch=arm64,riscv64,amd64] http://mirror.aarnet.edu.au/pub/ubuntu/ports/ jammy-updates universe" | sudo tee -a /etc/apt/sources.list
68
+
# echo "deb [arch=arm64,riscv64,amd64] http://mirror.aarnet.edu.au/pub/ubuntu/ports/ jammy-security main restricted" | sudo tee -a /etc/apt/sources.list
69
+
# echo "deb [arch=arm64,riscv64,amd64] http://mirror.aarnet.edu.au/pub/ubuntu/ports/ jammy-security universe" | sudo tee -a /etc/apt/sources.list
70
+
# echo "deb [arch=arm64,riscv64,amd64] http://mirror.aarnet.edu.au/pub/ubuntu/ports/ jammy-security multiverse" | sudo tee -a /etc/apt/sources.list
71
+
echo "deb [arch=arm64,riscv64,armhf] http://ports.ubuntu.com/ubuntu-ports/ jammy main restricted universe" | sudo tee -a /etc/apt/sources.list
72
+
echo "deb [arch=arm64,riscv64,armhf] http://ports.ubuntu.com/ubuntu-ports/ jammy-updates main restricted universe" | sudo tee -a /etc/apt/sources.list
73
+
echo "deb [arch=arm64,riscv64,armhf] http://ports.ubuntu.com/ubuntu-ports/ jammy-backports main restricted universe" | sudo tee -a /etc/apt/sources.list
74
+
echo "deb [arch=arm64,riscv64,armhf] http://ports.ubuntu.com/ubuntu-ports/ jammy-security main restricted universe" | sudo tee -a /etc/apt/sources.list
Since v0.6, Midiex uses [Rustler Precompiled](https://dashbit.co/blog/rustler-precompiled) to provide precompiled binaries on the following platforms:
8
+
9
+
- Apple Mac:
10
+
- M-series: aarch64-apple-darwin
11
+
- x86-series: x86_64-apple-darwin
12
+
- Linux x86 based:
13
+
- x86_64-unknown-linux-gnu
14
+
- x86_64-unknown-linux-musl
15
+
- Linux ARM based:
16
+
- aarch64-unknown-linux-gnu
17
+
- aarch64-unknown-linux-musl
18
+
- Linux RISC-V based:
19
+
- riscv64gc-unknown-linux-gnu
20
+
- Windows x86 based:
21
+
- x86_64-pc-windows-msvc
22
+
- x86_64-pc-windows-gnu
23
+
24
+
For the above platforms you should not need Rust's build tools as Rustler will download Midiex's precompiled NIF for the correct platform.
25
+
26
+
### Forcing compilation
27
+
Should you wish to build your own binary of Midiex's Rust-based NIF on the above platforms, you can force that by setting the environmental `MIDIEX_BUILD` to `true` or `1`, e.g.:
28
+
29
+
```
30
+
export MIDIEX_BUILD=true
31
+
```
32
+
You'll need to have the Rust build toolchain installed (see below).
33
+
6
34
# Building Midiex
7
35
In most cases, the standard Rust build toolchain is all you need. That being said there may be additional packages that need to be installed on Linux distributions related to ALSA (Advanced Linux Sound Architecture) as well as compilation in general (pkg-config).
8
36
@@ -14,7 +42,4 @@ Additionally on Linux (currently tested on Ubuntu 22.04), you may need some addi
14
42
15
43
If using the apt package manager, you can install those via the terminal prompt with:
16
44
17
-
```sudo apt install libasound2-dev pkg-config.```
18
-
19
-
## Future - precompiled binaries
20
-
It is a goal of this project to migrate to [Rustler Precompiled](https://dashbit.co/blog/rustler-precompiled) so that the rust build tools don't have to be installed and the precompiled binaries of Midiex's Rust-based NIF is downloaded for the correct platform.
Copy file name to clipboardExpand all lines: README.md
+24-4Lines changed: 24 additions & 4 deletions
Original file line number
Diff line number
Diff line change
@@ -22,7 +22,7 @@ Using WinRT or Jack requires special feature flags enabled. See the [midir GitHu
22
22
The hot-plug support of MIDI devices on MacOS is made possible with with the Rust [coremidi](https://github.com/chris-zen/coremidi) library.
23
23
24
24
## Status
25
-
This library is currently under active development and it’s API is likely to change. It's been tested on MacOS only.
25
+
This library is currently under active development and it’s API is likely to change. It's been tested on MacOS only although it is currently building on Mac (M-series and x86), Linux (64-bit ARM, RISC-V and x86) and Windows (x86_64) with precompiled binary packages (see the Getting started section below).
26
26
27
27
## API
28
28
At it's most basic level, the core functions of Midiex are for:
Since v0.6, Midiex uses [Rustler Precompiled](https://dashbit.co/blog/rustler-precompiled) to provide precompiled binaries on the following platforms:
79
+
80
+
- Apple Mac:
81
+
- M-series: aarch64-apple-darwin
82
+
- x86-series: x86_64-apple-darwin
83
+
- Linux x86 based:
84
+
- x86_64-unknown-linux-gnu
85
+
- x86_64-unknown-linux-musl
86
+
- Linux ARM based:
87
+
- aarch64-unknown-linux-gnu
88
+
- aarch64-unknown-linux-musl
89
+
- Linux RISC-V based:
90
+
- riscv64gc-unknown-linux-gnu
91
+
- Windows x86 based:
92
+
- x86_64-pc-windows-msvc
93
+
- x86_64-pc-windows-gnu
94
+
95
+
This means you shouldn't need the Rust build tools for the above plaforms. Just add midiex as a dependency to your Elixir file and Rustler will download and install the correct binary.
96
+
77
97
### Rust build tools
78
-
If you don't already have Rust's build tools installed, you'll likely need to. See [BUILDING.md](BUILDING.md) for more information.
98
+
If you want to use Midiex on a different platform than those listed above, or want to force complication, you'll need to have Rust's build tools installed. See [BUILDING.md](BUILDING.md) for more information.
79
99
80
100
### Adding it to your Elixir project
81
101
The package can be installed by adding midiex to your list of dependencies in mix.exs:
0 commit comments