mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2026-11-22 10:57:07 -08:00
535 lines
11 KiB
Bash
535 lines
11 KiB
Bash
# Copyright 2024-2026 Gentoo Authors
|
|
# Distributed under the terms of the GNU General Public License v2
|
|
|
|
# Autogenerated by pycargoebuild 0.15.0
|
|
|
|
EAPI=8
|
|
|
|
CRATES="
|
|
adler2@2.0.1
|
|
aho-corasick@1.1.5
|
|
allocator-api2@0.2.21
|
|
android_system_properties@0.1.5
|
|
anstream@0.6.21
|
|
anstream@1.0.0
|
|
anstyle-lossy@1.1.4
|
|
anstyle-parse@0.2.7
|
|
anstyle-parse@1.0.0
|
|
anstyle-query@1.1.4
|
|
anstyle-svg@0.1.11
|
|
anstyle-wincon@3.0.10
|
|
anstyle@1.0.14
|
|
anyhow@1.0.104
|
|
ar_archive_writer@0.5.3
|
|
arc-swap@1.9.2
|
|
argfile@1.0.0
|
|
arrayvec@0.7.8
|
|
attribute-derive-macro@0.10.3
|
|
attribute-derive@0.10.3
|
|
autocfg@1.5.0
|
|
bit-set@0.8.0
|
|
bit-vec@0.8.0
|
|
bitflags@1.3.2
|
|
bitflags@2.13.1
|
|
bitvec@1.1.1
|
|
block-buffer@0.10.4
|
|
block2@0.6.2
|
|
boxcar@0.2.14
|
|
bstr@1.13.1
|
|
bumpalo@3.19.0
|
|
camino@1.2.5
|
|
castaway@0.2.4
|
|
cc@1.2.65
|
|
cfg-if@1.0.4
|
|
cfg_aliases@0.2.1
|
|
chacha20@0.10.0
|
|
char_str@0.0.4
|
|
chrono@0.4.44
|
|
clap@4.6.6
|
|
clap_builder@4.6.6
|
|
clap_complete@4.5.58
|
|
clap_complete_command@0.6.1
|
|
clap_complete_nushell@4.5.8
|
|
clap_derive@4.6.4
|
|
clap_lex@1.0.0
|
|
clearscreen@4.0.6
|
|
collection_literals@1.0.2
|
|
colorchoice@1.0.4
|
|
colored@3.1.1
|
|
compact_str@0.10.0
|
|
console@0.16.4
|
|
core-foundation-sys@0.8.7
|
|
countme@3.0.1
|
|
cpufeatures@0.2.17
|
|
cpufeatures@0.3.0
|
|
crc32fast@1.5.0
|
|
crossbeam-channel@0.5.15
|
|
crossbeam-deque@0.8.6
|
|
crossbeam-epoch@0.9.18
|
|
crossbeam-queue@0.3.12
|
|
crossbeam-utils@0.8.21
|
|
crossbeam@0.8.4
|
|
crypto-common@0.1.6
|
|
ctrlc@3.5.2
|
|
dashmap@6.2.1
|
|
datatest-stable@0.3.3
|
|
defmt-macros@1.1.0
|
|
defmt-parser@1.0.0
|
|
defmt@1.1.0
|
|
derive-where@1.6.0
|
|
diff@0.1.13
|
|
digest@0.10.7
|
|
dirs-sys@0.5.0
|
|
dirs@6.0.0
|
|
dispatch2@0.3.0
|
|
displaydoc@0.2.5
|
|
drop_bomb@0.1.5
|
|
dunce@1.0.5
|
|
dyn-clone@1.0.20
|
|
either@1.15.0
|
|
encode_unicode@1.0.0
|
|
equivalent@1.0.2
|
|
errno@0.3.14
|
|
escape8259@0.5.3
|
|
escargot@0.5.15
|
|
etcetera@0.11.0
|
|
fancy-regex@0.14.0
|
|
fastrand@2.3.0
|
|
filetime@0.2.29
|
|
find-msvc-tools@0.1.9
|
|
flate2@1.1.2
|
|
fnv@1.0.7
|
|
foldhash@0.1.5
|
|
foldhash@0.2.0
|
|
form_urlencoded@1.2.2
|
|
fs-err@3.3.0
|
|
fsevent-sys@4.1.0
|
|
funty@2.0.0
|
|
futures-core@0.3.32
|
|
futures-task@0.3.32
|
|
futures-util@0.3.32
|
|
gen-lsp-types@0.11.0
|
|
generic-array@0.14.7
|
|
get-size-derive2@0.11.0
|
|
get-size2@0.11.0
|
|
getopts@0.2.24
|
|
getrandom@0.2.16
|
|
getrandom@0.3.4
|
|
getrandom@0.4.2
|
|
glob@0.3.4
|
|
globset@0.4.20
|
|
hashbrown@0.14.5
|
|
hashbrown@0.15.5
|
|
hashbrown@0.17.1
|
|
hashlink@0.12.0
|
|
heck@0.5.0
|
|
html-escape@0.2.13
|
|
iana-time-zone-haiku@0.1.2
|
|
iana-time-zone@0.1.64
|
|
icu_collections@2.2.0
|
|
icu_locale_core@2.2.0
|
|
icu_normalizer@2.2.0
|
|
icu_normalizer_data@2.2.0
|
|
icu_properties@2.2.0
|
|
icu_properties_data@2.2.0
|
|
icu_provider@2.2.0
|
|
id-arena@2.3.0
|
|
idna@1.1.0
|
|
idna_adapter@1.2.1
|
|
ignore@0.4.33
|
|
indexmap@2.14.2
|
|
indicatif@0.18.6
|
|
indoc@2.0.7
|
|
inotify-sys@0.1.5
|
|
inotify@0.11.0
|
|
insta-cmd@0.7.0
|
|
insta@1.48.0
|
|
interpolator@0.5.0
|
|
intrusive-collections@0.10.1
|
|
inventory@0.3.24
|
|
is-macro@0.3.8
|
|
is_terminal_polyfill@1.70.1
|
|
itertools@0.15.0
|
|
itoa@1.0.15
|
|
jiff-core@0.1.0
|
|
jiff-static@0.2.35
|
|
jiff-tzdb-platform@0.1.3
|
|
jiff-tzdb@0.1.4
|
|
jiff@0.2.35
|
|
jobserver@0.1.34
|
|
jod-thread@1.0.0
|
|
js-sys@0.3.100
|
|
kqueue-sys@1.0.4
|
|
kqueue@1.1.1
|
|
lazy_static@1.5.0
|
|
leb128fmt@0.1.0
|
|
libc@0.2.189
|
|
libredox@0.1.10
|
|
libtest-mimic@0.8.1
|
|
libz-rs-sys@0.5.5
|
|
linux-raw-sys@0.12.1
|
|
litemap@0.8.0
|
|
lock_api@0.4.14
|
|
log@0.4.34
|
|
lsp-server@0.10.0
|
|
manyhow-macros@0.11.4
|
|
manyhow@0.11.4
|
|
matchers@0.2.0
|
|
matchit@0.9.2
|
|
memchr@2.8.3
|
|
memoffset@0.9.1
|
|
minimal-lexical@0.2.1
|
|
miniz_oxide@0.8.9
|
|
mio@1.0.4
|
|
newtype-uuid@1.3.2
|
|
nix@0.31.2
|
|
nom@7.1.3
|
|
normalize-line-endings@0.3.0
|
|
notify-types@2.0.0
|
|
notify@8.2.0
|
|
nu-ansi-term@0.50.1
|
|
num-traits@0.2.19
|
|
objc2-encode@4.1.0
|
|
objc2@0.6.3
|
|
object@0.39.1
|
|
once_cell@1.21.4
|
|
once_cell_polyfill@1.70.1
|
|
option-ext@0.2.0
|
|
ordermap@1.2.1
|
|
os_pipe@1.2.2
|
|
os_str_bytes@7.1.1
|
|
parking_lot@0.12.5
|
|
parking_lot_core@0.9.12
|
|
path-slash@0.2.1
|
|
pathdiff@0.2.3
|
|
pep440_rs@0.7.3
|
|
percent-encoding@2.3.2
|
|
pest@2.8.2
|
|
pest_derive@2.8.2
|
|
pest_generator@2.8.2
|
|
pest_meta@2.8.2
|
|
phf@0.11.3
|
|
phf_codegen@0.11.3
|
|
phf_generator@0.11.3
|
|
phf_shared@0.11.3
|
|
pin-project-lite@0.2.16
|
|
pkg-config@0.3.32
|
|
portable-atomic-util@0.2.4
|
|
portable-atomic@1.13.1
|
|
potential_utf@0.1.3
|
|
ppv-lite86@0.2.21
|
|
pretty_assertions@1.4.1
|
|
prettyplease@0.2.37
|
|
proc-macro-error-attr2@2.0.0
|
|
proc-macro-error2@2.0.1
|
|
proc-macro-utils@0.10.0
|
|
proc-macro2@1.0.107
|
|
psm@0.1.32
|
|
quick-junit@0.6.1
|
|
quick-xml@0.41.0
|
|
quickcheck@1.1.0
|
|
quickcheck_macros@1.2.0
|
|
quote-use-macros@0.8.4
|
|
quote-use@0.8.4
|
|
quote@1.0.47
|
|
r-efi@5.3.0
|
|
r-efi@6.0.0
|
|
radium@0.7.0
|
|
rand@0.10.2
|
|
rand@0.8.5
|
|
rand_chacha@0.3.1
|
|
rand_core@0.10.0
|
|
rand_core@0.6.4
|
|
rayon-core@1.13.0
|
|
rayon@1.12.0
|
|
redox_syscall@0.5.17
|
|
redox_users@0.5.2
|
|
ref-cast-impl@1.0.25
|
|
ref-cast@1.0.25
|
|
regex-automata@0.4.18
|
|
regex-syntax@0.8.11
|
|
regex@1.13.1
|
|
ron@0.12.0
|
|
rustc-hash@2.1.3
|
|
rustc-stable-hash@0.1.2
|
|
rustix@1.1.5
|
|
rustversion@1.0.22
|
|
ryu@1.0.20
|
|
salsa-macro-rules@0.28.5
|
|
salsa-macros@0.28.5
|
|
salsa@0.28.5
|
|
same-file@1.0.6
|
|
schemars@1.2.2
|
|
schemars_derive@1.2.2
|
|
scopeguard@1.2.0
|
|
seahash@4.1.0
|
|
semver@1.0.27
|
|
serde@1.0.229
|
|
serde_core@1.0.229
|
|
serde_derive@1.0.229
|
|
serde_derive_internals@0.30.0
|
|
serde_json@1.0.151
|
|
serde_spanned@1.1.1
|
|
serde_test@1.0.177
|
|
sha2@0.10.9
|
|
sharded-slab@0.1.7
|
|
shellexpand@3.1.2
|
|
shlex@2.0.1
|
|
similar@2.7.0
|
|
similar@3.2.0
|
|
siphasher@1.0.1
|
|
slab@0.4.12
|
|
smallvec@1.15.2
|
|
snapbox-macros@1.0.0
|
|
snapbox@1.0.0
|
|
stable_deref_trait@1.2.0
|
|
stacker@0.1.25
|
|
static_assertions@1.1.0
|
|
strip-ansi-escapes@0.2.1
|
|
strsim@0.11.1
|
|
strum@0.28.0
|
|
strum_macros@0.28.0
|
|
supports-hyperlinks@3.2.0
|
|
syn@2.0.119
|
|
syn@3.0.4
|
|
synstructure@0.13.2
|
|
tap@1.0.1
|
|
tempfile@3.27.0
|
|
terminal_size@0.4.4
|
|
terminfo@0.9.0
|
|
test-case-core@3.3.1
|
|
test-case-macros@3.3.1
|
|
test-case@3.3.1
|
|
thin-vec@0.2.19
|
|
thiserror-impl@2.0.20
|
|
thiserror@2.0.20
|
|
thread_local@1.1.9
|
|
tikv-jemalloc-sys@0.6.1+5.3.0-1-ge13ca993e8ccb9ba9847cc330696e02839f328f7
|
|
tikv-jemallocator@0.6.1
|
|
tinystr@0.8.3
|
|
tinyvec@1.10.0
|
|
tinyvec_macros@0.1.1
|
|
toml@1.1.4+spec-1.1.0
|
|
toml_datetime@1.1.1+spec-1.1.0
|
|
toml_parser@1.1.3+spec-1.1.0
|
|
toml_writer@1.1.2+spec-1.1.0
|
|
tracing-attributes@0.1.31
|
|
tracing-core@0.1.36
|
|
tracing-flame@0.2.0
|
|
tracing-subscriber@0.3.23
|
|
tracing@0.1.44
|
|
typed-path@0.12.3
|
|
typeid@1.0.3
|
|
typenum@1.18.0
|
|
ucd-trie@0.1.7
|
|
unicode-ident@1.0.24
|
|
unicode-normalization@0.1.24
|
|
unicode-width@0.2.2
|
|
unicode-xid@0.2.6
|
|
unicode_names2@1.3.0
|
|
unicode_names2_generator@1.3.0
|
|
unit-prefix@0.5.1
|
|
unscanny@0.1.0
|
|
url@2.5.8
|
|
utf8-width@0.1.7
|
|
utf8_iter@1.0.4
|
|
utf8parse@0.2.2
|
|
uuid@1.26.0
|
|
version-ranges@0.1.1
|
|
version_check@0.9.5
|
|
vte@0.14.1
|
|
wait-timeout@0.2.1
|
|
walkdir@2.5.0
|
|
wasi@0.11.1+wasi-snapshot-preview1
|
|
wasip2@1.0.1+wasi-0.2.4
|
|
wasip3@0.4.0+wasi-0.3.0-rc-2026-01-06
|
|
wasm-bindgen-macro-support@0.2.123
|
|
wasm-bindgen-macro@0.2.123
|
|
wasm-bindgen-shared@0.2.123
|
|
wasm-bindgen@0.2.123
|
|
wasm-encoder@0.244.0
|
|
wasm-metadata@0.244.0
|
|
wasmparser@0.244.0
|
|
web-time@1.1.0
|
|
which@8.0.6
|
|
wild@2.2.1
|
|
winapi-util@0.1.11
|
|
windows-core@0.62.0
|
|
windows-implement@0.60.0
|
|
windows-interface@0.59.1
|
|
windows-link@0.1.3
|
|
windows-link@0.2.1
|
|
windows-result@0.4.0
|
|
windows-strings@0.5.0
|
|
windows-sys@0.52.0
|
|
windows-sys@0.59.0
|
|
windows-sys@0.60.2
|
|
windows-sys@0.61.0
|
|
windows-targets@0.52.6
|
|
windows-targets@0.53.3
|
|
windows_aarch64_gnullvm@0.52.6
|
|
windows_aarch64_gnullvm@0.53.0
|
|
windows_aarch64_msvc@0.52.6
|
|
windows_aarch64_msvc@0.53.0
|
|
windows_i686_gnu@0.52.6
|
|
windows_i686_gnu@0.53.0
|
|
windows_i686_gnullvm@0.52.6
|
|
windows_i686_gnullvm@0.53.0
|
|
windows_i686_msvc@0.52.6
|
|
windows_i686_msvc@0.53.0
|
|
windows_x86_64_gnu@0.52.6
|
|
windows_x86_64_gnu@0.53.0
|
|
windows_x86_64_gnullvm@0.52.6
|
|
windows_x86_64_gnullvm@0.53.0
|
|
windows_x86_64_msvc@0.52.6
|
|
windows_x86_64_msvc@0.53.0
|
|
winnow@1.0.0
|
|
wit-bindgen-core@0.51.0
|
|
wit-bindgen-rust-macro@0.51.0
|
|
wit-bindgen-rust@0.51.0
|
|
wit-bindgen@0.46.0
|
|
wit-bindgen@0.51.0
|
|
wit-component@0.244.0
|
|
wit-parser@0.244.0
|
|
writeable@0.6.2
|
|
wyz@0.5.1
|
|
yansi@1.0.1
|
|
yoke-derive@0.8.2
|
|
yoke@0.8.2
|
|
zerocopy-derive@0.8.27
|
|
zerocopy@0.8.27
|
|
zerofrom-derive@0.1.6
|
|
zerofrom@0.1.6
|
|
zerotrie@0.2.4
|
|
zerovec-derive@0.11.3
|
|
zerovec@0.11.6
|
|
zip@8.6.0
|
|
zlib-rs@0.5.5
|
|
zmij@1.0.10
|
|
zstd-safe@7.2.4
|
|
zstd-sys@2.0.16+zstd.1.5.7
|
|
zstd@0.13.3
|
|
"
|
|
|
|
RUST_MIN_VER="1.97.0"
|
|
|
|
inherit shell-completion cargo
|
|
|
|
DESCRIPTION="An extremely fast Python type checker and language server, written in Rust"
|
|
HOMEPAGE="
|
|
https://docs.astral.sh/ty/
|
|
https://github.com/astral-sh/ty
|
|
"
|
|
SRC_URI="
|
|
${CARGO_CRATE_URIS}
|
|
https://github.com/astral-sh/ty/releases/download/${PV}/source.tar.gz -> ${P}.tar.gz
|
|
"
|
|
|
|
S=${WORKDIR}/${P}/ruff/crates/ty
|
|
|
|
LICENSE="MIT"
|
|
# Dependent crate licenses
|
|
LICENSE+="
|
|
Apache-2.0 Apache-2.0-with-LLVM-exceptions BSD CC0-1.0 ISC MIT
|
|
MPL-2.0 Unicode-3.0 Unicode-DFS-2016 WTFPL-2 ZLIB
|
|
"
|
|
SLOT="0"
|
|
KEYWORDS="~amd64"
|
|
|
|
RDEPEND="
|
|
!elibc_musl? ( !elibc_Darwin? ( !elibc_bionic? ( dev-libs/jemalloc:= ) ) )
|
|
app-arch/zstd
|
|
"
|
|
DEPEND="
|
|
${RDEPEND}
|
|
"
|
|
|
|
QA_FLAGS_IGNORED="usr/bin/.*"
|
|
|
|
src_prepare() {
|
|
default
|
|
|
|
# Experimental cruft cleaner. These crates are not used by the ruff binary,
|
|
# and when they are removed in the git repo, the lockfile is regenerated
|
|
# and gets quite a bit smaller. Hence pycargoebuild also produces much
|
|
# smaller CRATES= variables. Less for the user to download, fewer distfiles
|
|
# to mirror.
|
|
pushd .. >/dev/null || die
|
|
rm -r ruff{,_{benchmark,dev,graph,linter,markdown,mdtest,python_{index,semantic},server,workspace}} \
|
|
ruff_python_*_integration_tests \
|
|
ty_completion_{bench,eval} \
|
|
*_wasm || die
|
|
|
|
# tests that hang in the ebuild environment
|
|
rm ruff_annotate_snippets/tests/examples.rs || die
|
|
|
|
popd > /dev/null || die
|
|
}
|
|
|
|
src_unpack() {
|
|
# The upstream source is a git submodule, and their source tarball has no
|
|
# leading directory. So we reimplement src_unpack by changing directory for
|
|
# exactly one archive.
|
|
mkdir -p "${WORKDIR}/${P}" || die
|
|
|
|
for archive in ${A}; do
|
|
case "${archive}" in
|
|
*${P}.tar.gz)
|
|
pushd "${WORKDIR}/${P}" >/dev/null || die
|
|
unpack "${archive}"
|
|
popd > /dev/null || die
|
|
;;
|
|
*.crate)
|
|
# cargo_crate_unpack is reusable for this
|
|
;;
|
|
*)
|
|
unpack "${archive}"
|
|
;;
|
|
esac
|
|
done
|
|
|
|
cargo_crate_unpack
|
|
cargo_gen_config
|
|
}
|
|
|
|
src_configure() {
|
|
export RUSTFLAGS="${RUSTFLAGS}"
|
|
cargo_src_configure
|
|
}
|
|
|
|
src_compile() {
|
|
local -x ZSTD_SYS_USE_PKG_CONFIG=1
|
|
# Gentoo bug #927338
|
|
if use !elibc_musl && use !elibc_Darwin && use !elibc_bionic; then
|
|
local -x CARGO_FEATURE_UNPREFIXED_MALLOC_ON_SUPPORTED_PLATFORMS=1
|
|
local -x JEMALLOC_OVERRIDE="${ESYSROOT}/usr/$(get_libdir)"/libjemalloc.so
|
|
fi
|
|
cargo_src_compile
|
|
|
|
local releasedir
|
|
releasedir=../../$(cargo_target_dir)
|
|
|
|
${releasedir}/ty generate-shell-completion bash > ty-completion.bash || die
|
|
${releasedir}/ty generate-shell-completion zsh > ty-completion.zsh || die
|
|
}
|
|
|
|
src_test() {
|
|
local -x ZSTD_SYS_USE_PKG_CONFIG=1
|
|
# Gentoo bug #927338
|
|
if use !elibc_musl && use !elibc_Darwin && use !elibc_bionic; then
|
|
local -x CARGO_FEATURE_UNPREFIXED_MALLOC_ON_SUPPORTED_PLATFORMS=1
|
|
local -x JEMALLOC_OVERRIDE="${ESYSROOT}/usr/$(get_libdir)"/libjemalloc.so
|
|
fi
|
|
|
|
cargo_src_test --target-dir "${PWD}"/tested-target/
|
|
}
|
|
|
|
src_install() {
|
|
local releasedir=../../$(cargo_target_dir)
|
|
|
|
dobin ${releasedir}/ty
|
|
|
|
newbashcomp ty-completion.bash ty
|
|
newzshcomp ty-completion.zsh _ty
|
|
}
|