commit: 000e1634a6110acd222dd4cfe01f37a652774da3 Author: Mattéo Rossillol‑‑Laruelle <beatussum <AT> protonmail <DOT> com> AuthorDate: Sun Jun 8 12:13:47 2025 +0000 Commit: Viorel Munteanu <ceamac <AT> gentoo <DOT> org> CommitDate: Sun Jun 8 12:26:20 2025 +0000 URL: https://gitweb.gentoo.org/repo/proj/guru.git/commit/?id=000e1634
net-im/gurk-rs: add 9999 Signed-off-by: Mattéo Rossillol‑‑Laruelle <beatussum <AT> protonmail.com> net-im/gurk-rs/gurk-rs-0.7.1.ebuild | 71 ++++++++++++++----------- net-im/gurk-rs/gurk-rs-9999.ebuild | 101 ++++++++++++++++++++++++++++++++++++ 2 files changed, 143 insertions(+), 29 deletions(-) diff --git a/net-im/gurk-rs/gurk-rs-0.7.1.ebuild b/net-im/gurk-rs/gurk-rs-0.7.1.ebuild index 4c9acf1798..0a6f5e38a5 100644 --- a/net-im/gurk-rs/gurk-rs-0.7.1.ebuild +++ b/net-im/gurk-rs/gurk-rs-0.7.1.ebuild @@ -5,30 +5,39 @@ EAPI=8 -declare -A GIT_CRATES=( - [curve25519-dalek-derive]='https://github.com/signalapp/curve25519-dalek;7c6d34756355a3566a704da84dce7b1c039a6572;curve25519-dalek-%commit%/curve25519-dalek-derive' - [curve25519-dalek]='https://github.com/signalapp/curve25519-dalek;7c6d34756355a3566a704da84dce7b1c039a6572;curve25519-dalek-%commit%/curve25519-dalek' - [libsignal-core]='https://github.com/signalapp/libsignal;e46841ea2c1ad03bc5113eba267ac1543689d031;libsignal-%commit%/rust/core' - [libsignal-protocol]='https://github.com/signalapp/libsignal;e46841ea2c1ad03bc5113eba267ac1543689d031;libsignal-%commit%/rust/protocol' - [libsignal-service]='https://github.com/whisperfish/libsignal-service-rs;f94d55bf8d742699024c26ca3965e85fc9946e23;libsignal-service-rs-%commit%' - [poksho]='https://github.com/signalapp/libsignal;e46841ea2c1ad03bc5113eba267ac1543689d031;libsignal-%commit%/rust/poksho' - [presage-store-sqlite]='https://github.com/whisperfish/presage;0da7b57746b827bfb310f98a10a29e73d508e742;presage-%commit%/presage-store-sqlite' - [presage]='https://github.com/whisperfish/presage;0da7b57746b827bfb310f98a10a29e73d508e742;presage-%commit%/presage' - [signal-crypto]='https://github.com/signalapp/libsignal;e46841ea2c1ad03bc5113eba267ac1543689d031;libsignal-%commit%/rust/crypto' - [zkcredential]='https://github.com/signalapp/libsignal;e46841ea2c1ad03bc5113eba267ac1543689d031;libsignal-%commit%/rust/zkcredential' - [zkgroup]='https://github.com/signalapp/libsignal;e46841ea2c1ad03bc5113eba267ac1543689d031;libsignal-%commit%/rust/zkgroup' -) +if [[ "${PV}" != "9999" ]]; then + declare -A GIT_CRATES=( + [curve25519-dalek-derive]='https://github.com/signalapp/curve25519-dalek;7c6d34756355a3566a704da84dce7b1c039a6572;curve25519-dalek-%commit%/curve25519-dalek-derive' + [curve25519-dalek]='https://github.com/signalapp/curve25519-dalek;7c6d34756355a3566a704da84dce7b1c039a6572;curve25519-dalek-%commit%/curve25519-dalek' + [libsignal-core]='https://github.com/signalapp/libsignal;e46841ea2c1ad03bc5113eba267ac1543689d031;libsignal-%commit%/rust/core' + [libsignal-protocol]='https://github.com/signalapp/libsignal;e46841ea2c1ad03bc5113eba267ac1543689d031;libsignal-%commit%/rust/protocol' + [libsignal-service]='https://github.com/whisperfish/libsignal-service-rs;f94d55bf8d742699024c26ca3965e85fc9946e23;libsignal-service-rs-%commit%' + [poksho]='https://github.com/signalapp/libsignal;e46841ea2c1ad03bc5113eba267ac1543689d031;libsignal-%commit%/rust/poksho' + [presage-store-sqlite]='https://github.com/whisperfish/presage;0da7b57746b827bfb310f98a10a29e73d508e742;presage-%commit%/presage-store-sqlite' + [presage]='https://github.com/whisperfish/presage;0da7b57746b827bfb310f98a10a29e73d508e742;presage-%commit%/presage' + [signal-crypto]='https://github.com/signalapp/libsignal;e46841ea2c1ad03bc5113eba267ac1543689d031;libsignal-%commit%/rust/crypto' + [zkcredential]='https://github.com/signalapp/libsignal;e46841ea2c1ad03bc5113eba267ac1543689d031;libsignal-%commit%/rust/zkcredential' + [zkgroup]='https://github.com/signalapp/libsignal;e46841ea2c1ad03bc5113eba267ac1543689d031;libsignal-%commit%/rust/zkgroup' + ) +fi inherit cargo check-reqs DESCRIPTION="Signal messenger client for terminal" HOMEPAGE="https://github.com/boxdot/gurk-rs/" -SRC_URI=" - https://github.com/boxdot/gurk-rs/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz - https://github.com/beatussum/gentoo-tarballs/releases/download/latest/gurk-${PV}-crates.tar.xz - ${CARGO_CRATE_URIS} -" +if [[ "${PV}" = "9999" ]]; then + inherit git-r3 + EGIT_REPO_URI="https://github.com/boxdot/gurk-rs.git" +else + SRC_URI=" + https://github.com/boxdot/gurk-rs/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz + https://github.com/beatussum/gentoo-tarballs/releases/download/latest/gurk-${PV}-crates.tar.xz + ${CARGO_CRATE_URIS} + " + + KEYWORDS="~amd64" +fi LICENSE="AGPL-3" @@ -47,7 +56,6 @@ LICENSE+=" " SLOT="0" -KEYWORDS="~amd64" DOCS=( CHANGELOG.md @@ -65,20 +73,25 @@ pkg_setup() { } src_unpack() { - cargo_src_unpack + if [[ "${PV}" = "9999" ]]; then + git-r3_src_unpack + cargo_live_src_unpack + else + cargo_src_unpack - local crate_patches + local crate_patches - for crate in curve25519-dalek{,-derive}; do - IFS=';' read -r crate_uri commit crate_dir host \ - <<< "${GIT_CRATES["${crate}"]}" + for crate in curve25519-dalek{,-derive}; do + IFS=';' read -r crate_uri commit crate_dir host \ + <<< "${GIT_CRATES["${crate}"]}" - : "${crate_dir:=${crate}-%commit%}" - crate_patches+="${crate} = { path = \"${WORKDIR}/${crate_dir//%commit%/${commit}}\" };;" - done + : "${crate_dir:=${crate}-%commit%}" + crate_patches+="${crate} = { path = \"${WORKDIR}/${crate_dir//%commit%/${commit}}\" };;" + done - printf -- "[patch.crates-io]\\n%s" "${crate_patches//;;/$'\n'}" \ - >> "${CARGO_HOME}/config.toml" + printf -- "[patch.crates-io]\\n%s" "${crate_patches//;;/$'\n'}" \ + >> "${CARGO_HOME}/config.toml" + fi } src_install() diff --git a/net-im/gurk-rs/gurk-rs-9999.ebuild b/net-im/gurk-rs/gurk-rs-9999.ebuild new file mode 100644 index 0000000000..0a6f5e38a5 --- /dev/null +++ b/net-im/gurk-rs/gurk-rs-9999.ebuild @@ -0,0 +1,101 @@ +# Copyright 1999-2025 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +# Autogenerated by pycargoebuild 0.15.0 + +EAPI=8 + +if [[ "${PV}" != "9999" ]]; then + declare -A GIT_CRATES=( + [curve25519-dalek-derive]='https://github.com/signalapp/curve25519-dalek;7c6d34756355a3566a704da84dce7b1c039a6572;curve25519-dalek-%commit%/curve25519-dalek-derive' + [curve25519-dalek]='https://github.com/signalapp/curve25519-dalek;7c6d34756355a3566a704da84dce7b1c039a6572;curve25519-dalek-%commit%/curve25519-dalek' + [libsignal-core]='https://github.com/signalapp/libsignal;e46841ea2c1ad03bc5113eba267ac1543689d031;libsignal-%commit%/rust/core' + [libsignal-protocol]='https://github.com/signalapp/libsignal;e46841ea2c1ad03bc5113eba267ac1543689d031;libsignal-%commit%/rust/protocol' + [libsignal-service]='https://github.com/whisperfish/libsignal-service-rs;f94d55bf8d742699024c26ca3965e85fc9946e23;libsignal-service-rs-%commit%' + [poksho]='https://github.com/signalapp/libsignal;e46841ea2c1ad03bc5113eba267ac1543689d031;libsignal-%commit%/rust/poksho' + [presage-store-sqlite]='https://github.com/whisperfish/presage;0da7b57746b827bfb310f98a10a29e73d508e742;presage-%commit%/presage-store-sqlite' + [presage]='https://github.com/whisperfish/presage;0da7b57746b827bfb310f98a10a29e73d508e742;presage-%commit%/presage' + [signal-crypto]='https://github.com/signalapp/libsignal;e46841ea2c1ad03bc5113eba267ac1543689d031;libsignal-%commit%/rust/crypto' + [zkcredential]='https://github.com/signalapp/libsignal;e46841ea2c1ad03bc5113eba267ac1543689d031;libsignal-%commit%/rust/zkcredential' + [zkgroup]='https://github.com/signalapp/libsignal;e46841ea2c1ad03bc5113eba267ac1543689d031;libsignal-%commit%/rust/zkgroup' + ) +fi + +inherit cargo check-reqs + +DESCRIPTION="Signal messenger client for terminal" +HOMEPAGE="https://github.com/boxdot/gurk-rs/" + +if [[ "${PV}" = "9999" ]]; then + inherit git-r3 + EGIT_REPO_URI="https://github.com/boxdot/gurk-rs.git" +else + SRC_URI=" + https://github.com/boxdot/gurk-rs/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz + https://github.com/beatussum/gentoo-tarballs/releases/download/latest/gurk-${PV}-crates.tar.xz + ${CARGO_CRATE_URIS} + " + + KEYWORDS="~amd64" +fi + +LICENSE="AGPL-3" + +# Dependent crate licenses +LICENSE+=" + AGPL-3 + Apache-2.0 + BSD-2 + BSD + Boost-1.0 + ISC + MIT + MPL-2.0 + Unicode-3.0 + ZLIB +" + +SLOT="0" + +DOCS=( + CHANGELOG.md + README.md + chat-qr.png + screenshot.png +) + +RUST_MIN_VER="1.85.0" +CHECKREQS_DISK_BUILD="2400M" + +pkg_setup() { + check-reqs_pkg_setup + rust_pkg_setup +} + +src_unpack() { + if [[ "${PV}" = "9999" ]]; then + git-r3_src_unpack + cargo_live_src_unpack + else + cargo_src_unpack + + local crate_patches + + for crate in curve25519-dalek{,-derive}; do + IFS=';' read -r crate_uri commit crate_dir host \ + <<< "${GIT_CRATES["${crate}"]}" + + : "${crate_dir:=${crate}-%commit%}" + crate_patches+="${crate} = { path = \"${WORKDIR}/${crate_dir//%commit%/${commit}}\" };;" + done + + printf -- "[patch.crates-io]\\n%s" "${crate_patches//;;/$'\n'}" \ + >> "${CARGO_HOME}/config.toml" + fi +} + +src_install() +{ + einstalldocs + cargo_src_install +}
