mirror of
https://github.com/chenxiaolong/avbroot.git
synced 2026-07-03 14:05:11 +02:00
Compare commits
3 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| e105efb6d3 | |||
| 2a7df104ed | |||
| 8e52a9cf8c |
@@ -19,6 +19,7 @@ jobs:
|
|||||||
# https://github.com/rust-lang/rust/issues/78210
|
# https://github.com/rust-lang/rust/issues/78210
|
||||||
RUSTFLAGS: -C strip=symbols -C target-feature=+crt-static
|
RUSTFLAGS: -C strip=symbols -C target-feature=+crt-static
|
||||||
TARGETS: ${{ join(matrix.artifact.targets, ' ') || matrix.artifact.name }}
|
TARGETS: ${{ join(matrix.artifact.targets, ' ') || matrix.artifact.name }}
|
||||||
|
ANDROID_API: ${{ matrix.artifact.android_api }}
|
||||||
strategy:
|
strategy:
|
||||||
fail-fast: false
|
fail-fast: false
|
||||||
matrix:
|
matrix:
|
||||||
@@ -33,6 +34,12 @@ jobs:
|
|||||||
- aarch64-apple-darwin
|
- aarch64-apple-darwin
|
||||||
- x86_64-apple-darwin
|
- x86_64-apple-darwin
|
||||||
combine: lipo
|
combine: lipo
|
||||||
|
# ubuntu-latest is not 24.04 yet and 22.04's qemu-user-static segfaults.
|
||||||
|
- os: ubuntu-24.04
|
||||||
|
name: aarch64-linux-android31
|
||||||
|
targets:
|
||||||
|
- aarch64-linux-android
|
||||||
|
android_api: '31'
|
||||||
steps:
|
steps:
|
||||||
- name: Check out repository
|
- name: Check out repository
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
@@ -40,6 +47,26 @@ jobs:
|
|||||||
# For git describe
|
# For git describe
|
||||||
fetch-depth: 0
|
fetch-depth: 0
|
||||||
|
|
||||||
|
- name: Install qemu-user-static
|
||||||
|
if: ${{ contains(matrix.artifact.name, 'android') }}
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
sudo apt-get -y update
|
||||||
|
sudo apt-get -y install qemu-user-static
|
||||||
|
|
||||||
|
- name: Set Android temporary directory
|
||||||
|
if: ${{ contains(matrix.artifact.name, 'android') }}
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
echo "TMPDIR=/tmp" >> "${GITHUB_ENV}"
|
||||||
|
|
||||||
|
- name: Install cargo-android
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
cargo install \
|
||||||
|
--git https://github.com/chenxiaolong/cargo-android \
|
||||||
|
--tag v0.1.1
|
||||||
|
|
||||||
- name: Get version
|
- name: Get version
|
||||||
id: get_version
|
id: get_version
|
||||||
shell: bash
|
shell: bash
|
||||||
@@ -63,7 +90,8 @@ jobs:
|
|||||||
shell: bash
|
shell: bash
|
||||||
run: |
|
run: |
|
||||||
for target in ${TARGETS}; do
|
for target in ${TARGETS}; do
|
||||||
cargo clippy --release --workspace --features static \
|
cargo android \
|
||||||
|
clippy --release --workspace --features static \
|
||||||
--target "${target}"
|
--target "${target}"
|
||||||
done
|
done
|
||||||
|
|
||||||
@@ -71,7 +99,8 @@ jobs:
|
|||||||
shell: bash
|
shell: bash
|
||||||
run: |
|
run: |
|
||||||
for target in ${TARGETS}; do
|
for target in ${TARGETS}; do
|
||||||
cargo build --release --workspace --features static \
|
cargo android \
|
||||||
|
build --release --workspace --features static \
|
||||||
--target "${target}"
|
--target "${target}"
|
||||||
done
|
done
|
||||||
|
|
||||||
@@ -79,7 +108,8 @@ jobs:
|
|||||||
shell: bash
|
shell: bash
|
||||||
run: |
|
run: |
|
||||||
for target in ${TARGETS}; do
|
for target in ${TARGETS}; do
|
||||||
cargo test --release --workspace --features static \
|
cargo android \
|
||||||
|
test --release --workspace --features static \
|
||||||
--target "${target}"
|
--target "${target}"
|
||||||
done
|
done
|
||||||
|
|
||||||
@@ -87,7 +117,8 @@ jobs:
|
|||||||
shell: bash
|
shell: bash
|
||||||
run: |
|
run: |
|
||||||
for target in ${TARGETS}; do
|
for target in ${TARGETS}; do
|
||||||
cargo run --release -p e2e --features static \
|
cargo android \
|
||||||
|
run --release -p e2e --features static \
|
||||||
--target "${target}" \
|
--target "${target}" \
|
||||||
-- test -a -c e2e/e2e.toml
|
-- test -a -c e2e/e2e.toml
|
||||||
done
|
done
|
||||||
|
|||||||
@@ -7,6 +7,10 @@
|
|||||||
to update the actual links at the bottom of the file.
|
to update the actual links at the bottom of the file.
|
||||||
-->
|
-->
|
||||||
|
|
||||||
|
### Version 3.2.3
|
||||||
|
|
||||||
|
* Add prebuilt binary for Android (aarch64) ([PR #304])
|
||||||
|
|
||||||
### Version 3.2.2
|
### Version 3.2.2
|
||||||
|
|
||||||
* Add new `--recompute-size` option to `avbroot avb pack` to automatically recompute the image size for resizable images ([Discussion #294], [PR #296])
|
* Add new `--recompute-size` option to `avbroot avb pack` to automatically recompute the image size for resizable images ([Discussion #294], [PR #296])
|
||||||
@@ -295,3 +299,4 @@ Behind-the-scenes changes:
|
|||||||
[PR #293]: https://github.com/chenxiaolong/avbroot/pull/293
|
[PR #293]: https://github.com/chenxiaolong/avbroot/pull/293
|
||||||
[PR #296]: https://github.com/chenxiaolong/avbroot/pull/296
|
[PR #296]: https://github.com/chenxiaolong/avbroot/pull/296
|
||||||
[PR #297]: https://github.com/chenxiaolong/avbroot/pull/297
|
[PR #297]: https://github.com/chenxiaolong/avbroot/pull/297
|
||||||
|
[PR #304]: https://github.com/chenxiaolong/avbroot/pull/304
|
||||||
|
|||||||
Generated
+4
-4
@@ -109,7 +109,7 @@ checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0"
|
|||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "avbroot"
|
name = "avbroot"
|
||||||
version = "3.2.2"
|
version = "3.2.3"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"anyhow",
|
"anyhow",
|
||||||
"assert_matches",
|
"assert_matches",
|
||||||
@@ -534,7 +534,7 @@ dependencies = [
|
|||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "e2e"
|
name = "e2e"
|
||||||
version = "3.2.2"
|
version = "3.2.3"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"anyhow",
|
"anyhow",
|
||||||
"avbroot",
|
"avbroot",
|
||||||
@@ -628,7 +628,7 @@ dependencies = [
|
|||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "fuzz"
|
name = "fuzz"
|
||||||
version = "3.2.2"
|
version = "3.2.3"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"avbroot",
|
"avbroot",
|
||||||
"honggfuzz",
|
"honggfuzz",
|
||||||
@@ -2068,7 +2068,7 @@ dependencies = [
|
|||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "xtask"
|
name = "xtask"
|
||||||
version = "3.2.2"
|
version = "3.2.3"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"anyhow",
|
"anyhow",
|
||||||
"clap",
|
"clap",
|
||||||
|
|||||||
+1
-1
@@ -4,7 +4,7 @@ members = ["avbroot", "e2e", "fuzz", "xtask"]
|
|||||||
resolver = "2"
|
resolver = "2"
|
||||||
|
|
||||||
[workspace.package]
|
[workspace.package]
|
||||||
version = "3.2.2"
|
version = "3.2.3"
|
||||||
license = "GPL-3.0-only"
|
license = "GPL-3.0-only"
|
||||||
edition = "2021"
|
edition = "2021"
|
||||||
repository = "https://github.com/chenxiaolong/avbroot"
|
repository = "https://github.com/chenxiaolong/avbroot"
|
||||||
|
|||||||
@@ -440,6 +440,16 @@ Debug builds work too, but they will run significantly slower (in the sha256 com
|
|||||||
|
|
||||||
By default, the executable links to the system's bzip2 and liblzma libraries, which are the only external libraries avbroot depends on. To compile and statically link these two libraries, pass in `--features static`.
|
By default, the executable links to the system's bzip2 and liblzma libraries, which are the only external libraries avbroot depends on. To compile and statically link these two libraries, pass in `--features static`.
|
||||||
|
|
||||||
|
### Android cross-compilation
|
||||||
|
|
||||||
|
To cross-compile for Android, install [cargo-android](https://github.com/chenxiaolong/cargo-android) and use the `cargo android` wrapper. To make a release build for aarch64, run:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
cargo android build --release --target aarch64-linux-android
|
||||||
|
```
|
||||||
|
|
||||||
|
It is possible to run the tests if the host is running Linux, qemu-user-static is installed, and the executable is built with `RUSTFLAGS=-C target-feature=+crt-static` and `--features static`.
|
||||||
|
|
||||||
## Verifying digital signatures
|
## Verifying digital signatures
|
||||||
|
|
||||||
First, save the public key to a file listing the keys to be trusted. This is the same key listed in [the author's profile](https://github.com/chenxiaolong/).
|
First, save the public key to a file listing the keys to be trusted. This is the same key listed in [the author's profile](https://github.com/chenxiaolong/).
|
||||||
|
|||||||
Reference in New Issue
Block a user