Skip to content

Commit 8fa26fe

Browse files
committed
fix(main/atuin): fix panicked: Expect rustls-platform-verifier to be initialized
- Fixes #28849 - Like #28631 and #28323, but for `atuin`
1 parent af5e5cb commit 8fa26fe

1 file changed

Lines changed: 18 additions & 0 deletions

File tree

packages/atuin/build.sh

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ TERMUX_PKG_LICENSE="MIT"
44
TERMUX_PKG_LICENSE_FILE="../../LICENSE"
55
TERMUX_PKG_MAINTAINER="@termux"
66
TERMUX_PKG_VERSION="18.12.1"
7+
TERMUX_PKG_REVISION=1
78
TERMUX_PKG_SRCURL="https://github.com/atuinsh/atuin/archive/refs/tags/v${TERMUX_PKG_VERSION}.tar.gz"
89
TERMUX_PKG_SHA256=8643a7df1e366e9ad3134514b9bcaf4d6440accb13c64340ec9ec1923d58eb6e
910
TERMUX_PKG_AUTO_UPDATE=true
@@ -24,6 +25,23 @@ termux_step_pre_configure() {
2425

2526
# clash with rust host build
2627
unset CFLAGS
28+
29+
cargo vendor
30+
find ./vendor \
31+
-mindepth 1 -maxdepth 1 -type d \
32+
! -wholename ./vendor/rustls-platform-verifier \
33+
-exec rm -rf '{}' \;
34+
35+
find vendor/rustls-platform-verifier -type f -print0 | \
36+
xargs -0 sed -i \
37+
-e 's|"android"|"disabling_this_because_it_is_for_building_an_apk"|g' \
38+
-e "s|ANDROID|DISABLING_THIS_BECAUSE_IT_IS_FOR_BUILDING_AN_APK|g" \
39+
-e 's|"linux"|"android"|g'
40+
41+
echo "" >> Cargo.toml
42+
echo '[patch.crates-io]' >> Cargo.toml
43+
echo 'rustls-platform-verifier = { path = "./vendor/rustls-platform-verifier" }' >> Cargo.toml
44+
2745
}
2846

2947
termux_step_post_make_install() {

0 commit comments

Comments
 (0)