Newer
Older
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
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
# Packaging
## Dependencies
The following dependencies are only required to build a package locally. It can be skipped during general development.
### Deb Packaging
The project uses [cargo-deb](https://crates.io/crates/cargo-deb) to build the Debian package.
```
cargo install cargo-deb
```
### AppImage Packaging
- The project uses [appimagetool](https://github.com/AppImage/appimagetool) for building the AppImage.
```
wget https://github.com/AppImage/appimagetool/releases/download/continuous/appimagetool-$(uname -m).AppImage -O $HOME/.local/bin/appimagetool
chmod +x $HOME/.local/bin/appimagetool
```
### DMG Packaging
- The project uses [create-dmg](https://github.com/create-dmg/create-dmg) to build DMG package for MacOS
```
brew install create-dmg
```
## Building
The repo contains a `Makefile` to help create the different supported packages.
## Deb Package
Ensure [dependencies](#deb-packaging) are installed.
- CLI
```
make package-cli-linux-deb-{target}
```
- GUI
```
make package-gui-linux-deb-{target}
```
Where `target` is the platform you are building for. Currently, the following targets have been tested:
- x86_64-unknown-linux-gnu
- aarch64-unknown-linux-gnu
- armv7-unknown-linux-gnueabihf
For different host/target pair, see [Cross Compilation](#cross-compilation)
## AppImage
Ensure [dependencies](#appimage-dependencies) are installed. AppImage is only supported for the GUI.
```
make package-gui-linux-appimage-{target}
```
Where `target` is the platform you are building for. Currently, the following targets have been tested:
- x86_64-unknown-linux-gnu
- aarch64-unknown-linux-gnu
- armv7-unknown-linux-gnueabihf
For different host/target pair, see [Cross Compilation](#cross-compilation)
## Linux Generic
Just a tarball of everything. Useful for creating packages that need to be maintained out of tree. Only supported for CLI for now.
```
make package-cli-linux-xz-{target}
```
Where `target` is the platform you are building for. Currently, the following targets have been tested:
- x86_64-unknown-linux-gnu
- aarch64-unknown-linux-gnu
- armv7-unknown-linux-gnueabihf
For different host/target pair, see [Cross Compilation](#cross-compilation)
## Windows Standalone Executable
- CLI
```
make package-cli-windows-zip-{target}
```
- GUI
```
make package-gui-windows-zip-{target}
```
Where `target` is the platform you are building for. Currently, the following targets have been tested:
- x86_64-pc-windows-gnu
For different host/target pair, see [Cross Compilation](#cross-compilation)
## MacOS DMG
Ensure [dependencies](#dmg-dependencies) are installed. DMG is only supported for the GUI.
```
make package-gui-darwin-dmg-{target}
```
Where `target` is the platform you are building for. Currently, the following targets have been tested:
- x86_64-apple-darwin
- aarch64-apple-darwin
- universal-apple-darwin
MacOS Package cannot be built on a non-MacOS host.
## MacOS Generic
Zipped package for CLI. Useful for creating out of tree packages. Only supported for CLI.
```
make package-cli-darwin-zip-{target}
```
Where `target` is the platform you are building for. Currently, the following targets have been tested:
- x86_64-apple-darwin
- aarch64-apple-darwin
- universal-apple-darwin
MacOS Package cannot be built on a non-MacOS host.
# Cross Compilation
Cross Compilation is not well supported at the moment. I have used [cross](https://github.com/cross-rs/cross) in the past with some success, but since most of Docker-in-Docker requires special runners on [openbeagle](https://openbeagle.org/), I ended up dropping cross.
It is still possible to try building the packages with [cross](https://github.com/cross-rs/cross) by setting the `RUST_BUILDER=cross` environment variable. PRs are welcome.