Skip to content

Commit

Permalink
app-editors/zed: add 0.172.10
Browse files Browse the repository at this point in the history
  • Loading branch information
robert7k committed Feb 10, 2025
1 parent 3873354 commit 30d2418
Show file tree
Hide file tree
Showing 2 changed files with 213 additions and 0 deletions.
3 changes: 3 additions & 0 deletions app-editors/zed/Manifest
Original file line number Diff line number Diff line change
Expand Up @@ -33,10 +33,13 @@ DIST zed-0.170.4-crates.tar.xz 102368748 BLAKE2B 8da887e0802da0f4d555f9ae00f8eab
DIST zed-0.170.4.tar.gz 13542920 BLAKE2B 5a3d96079a47420540bf83c887ad87e75bf67d45e14cabc8be61f4a53640e57080d0a504db599b045cdd4415a7aae71a5249c831ffbd2a20b1ec069a28e73e28 SHA512 eaf02b294e3f5ef9f00fb487415a04e61e4bf13cb4908f218a6acdbb4e1b0f9819b965f35dace75f4b0898a74c2f7ec769c204cbe98ec16055e56be94e1109d9
DIST zed-0.171.3-crates.tar.xz 102307728 BLAKE2B d0eb6c2af519b0ffa02ec8100d32ae451f0268b9048eb0f47b27fcceb3a68f9837adccf9bcf628f93b9217cca8927911be068ad26c8d405e7e8f5cab80005e04 SHA512 d1e46b754af188793fb91c4772ade052e2635a91061f3ec5046b71b5faa92ccbffbe69a6be27787b1ec73c5a1a604082aa80b43dac25f9f35322157b6b58cb07
DIST zed-0.171.3.tar.gz 13569223 BLAKE2B faa1b6645aae26b3111f68a075a9cbe0d60a774343d222b0a65959b4b49ee74a281b89e1159388ebfe0b1767ee46707f494b0d66361936021c7eaf449e1c30c8 SHA512 d605807449f474b85be486f7f255cc0cd97253e791d3921058481de002f45bdb0438be86d6789ebc2622ab1e82ba43248a92c2461ed7a04417c21302ad9856f7
DIST zed-0.172.10-crates.tar.xz 101309808 BLAKE2B 98770d79f4cddda7c8215760a4856b42107414d50c0b28499e8dab334e36d7f1629034875f396cf3e342ccac562bf71d6be61e360f57388badca594fe691fcb0 SHA512 3b549b155ed160350852f71281f966a35900089f85fd05190d15bbdd9a257c124aa313ad1ddedc0c5f644d0f64f49d8c86091aebb0f897e5a51640bfe48d9007
DIST zed-0.172.10.tar.gz 13621974 BLAKE2B df0fc8e93ca584c84281e86a86c5c4d9ae47d13aac3bfaa3c5837aa64677e9fccb0f6b6eabce8a5b953af5c2062a587e4e31bef8cebe0003ea5a78e1e98ecbc9 SHA512 4799a04191ac07a8da178252f79097def1f1959c4ecbbfef71999765d4ed6db41089b7445c529e1b6784c8598cd6c60707028048f8fdb2afbf96b99b7ad016e8
DIST zed-0.172.8-crates.tar.xz 101309808 BLAKE2B 98770d79f4cddda7c8215760a4856b42107414d50c0b28499e8dab334e36d7f1629034875f396cf3e342ccac562bf71d6be61e360f57388badca594fe691fcb0 SHA512 3b549b155ed160350852f71281f966a35900089f85fd05190d15bbdd9a257c124aa313ad1ddedc0c5f644d0f64f49d8c86091aebb0f897e5a51640bfe48d9007
DIST zed-0.172.8.tar.gz 13619615 BLAKE2B 5cb194a6e234ac8273e81f2ec6991cea9956d7094940a0c3d932d6e4a7ae599dc48a82e7a60be182612b789dbb35e0b31690c76798dfe45751b5de680cfa5aa4 SHA512 c45ac9722a4db274b6a856442f8351ecd1955e07deb2e9efa250e9748ae7b10c8c69f53c6297d21790e74fa065e70e2731010c8dec74fea13a0bd6ae61a2cb04
EBUILD zed-0.165.4.ebuild 9505 BLAKE2B 913cb247ea92dbdb4e69b9cafc562a63f07b5ce6b495946ef622c3dfce7b32e83d4aad165ec9b7dda7b7b1c0b9ce54f1bc835dffcee333b6de7a59cea49ba257 SHA512 1527549f3b4732d230ed69f797840b705805467389e379f8a0958bedb1ecf66f2f9058857eb9cfd8b8b057934a391fa15275342f5fb1d1c0d9e6b8203fc370d3
EBUILD zed-0.168.2.ebuild 11505 BLAKE2B 1b614242968c757bdece760f455d25e8b34502098d31523689fc36918b8228e9d85d60292af85f502338dc69d2139f2f9347bd1082deeabe8bccd54c5c92a538 SHA512 5592cafac8272ce0b21526041803b3100218f3133dcf937866b9fd3ccd987b5636ae3d7bd62963a4818b530c69c662cee00f27d0c95f617dfc92b8fde49d8fbe
EBUILD zed-0.170.4.ebuild 11769 BLAKE2B 06e2550f8607e26422d80c1e6a71f66af75236c87d12f587ed4f483ccd270eb8b507e33f76c03c9d4fea2a954195b455ace48a96e9e3ae95b3f98a25abd0461f SHA512 23faae17747eb787107c3a4b1a967289226af0f0e480206e8e23cb7f493254f6be816b857d91d72f67f6e35186158d422e0690385e62adf965ef997d857ac518
EBUILD zed-0.171.3.ebuild 11911 BLAKE2B 01ec7b0a23c12c37edb146110f266ed49417260214e422fd152f8b922e0dd4bded2f58288b23ac394170eff9d114f92eb7a6de1be2df450e3ee68677db817d73 SHA512 5c18b2bc2c605bbea4f63a93d3fb8fbce1530a895e32b4bef2ff7ad4a1eb89449c2290bc905846bbb7ecdb1816b0d2027bd88586b740282d271953f8ca6ae571
EBUILD zed-0.172.10.ebuild 12146 BLAKE2B ad27eca2ea64e41e6c3ee8ab5efb2fb06c225de7f514e5d4fd4c169c735b1461ed0a7f80da0dea0d6ca56e15bb24aec7f026ec8efe5be8886ce6b13b35cbf368 SHA512 663645139d944d6f201c45a2f50c6eb5f26bdb3ae2a0f10a98cd075b195a56e3fd9b0a94e834d983df04eb71de3228697cd7470b420cc6a426a618a89f2cec90
EBUILD zed-0.172.8.ebuild 12140 BLAKE2B 52fb899a51506d44ddf5998b1f34fac55718512b85ff5fb190f5f8e38ee3fd3cd1a3b3b37af2f7b6e94c745503e7f5ee3a9125e70ea1bf3454dd02142064616f SHA512 212d6b79ca5692cc0ee627ba56ef7ca6707144d2952d64ff68049baf0dd7feacd5f0ba9ab57bbfff7e2871207233afcfe1ea10d5b241b1d697a1412662cc8d15
210 changes: 210 additions & 0 deletions app-editors/zed/zed-0.172.10.ebuild
Original file line number Diff line number Diff line change
@@ -0,0 +1,210 @@
# Copyright 2025 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2

# Autogenerated by pycargoebuild 0.13.5

EAPI=8

CRATES="
"

declare -A GIT_CRATES=(
[alacritty_terminal]='https://github.com/alacritty/alacritty;5e78d20c709cb1ab8d44ca7a8702cc26d779227c;alacritty-%commit%/alacritty_terminal'
[async-pipe]='https://github.com/zed-industries/async-pipe-rs;82d00a04211cf4e1236029aa03e6b6ce2a74c553;async-pipe-rs-%commit%'
[async-stripe]='https://github.com/zed-industries/async-stripe;3672dd4efb7181aa597bf580bf5a2f5d23db6735;async-stripe-%commit%'
[blade-graphics]='https://github.com/kvark/blade;091a8401033847bb9b6ace3fcf70448d069621c5;blade-%commit%/blade-graphics'
[blade-macros]='https://github.com/kvark/blade;091a8401033847bb9b6ace3fcf70448d069621c5;blade-%commit%/blade-macros'
[blade-util]='https://github.com/kvark/blade;091a8401033847bb9b6ace3fcf70448d069621c5;blade-%commit%/blade-util'
[cosmic-text]='https://github.com/pop-os/cosmic-text;542b20ca4376a3b5de5fa629db1a4ace44e18e0c;cosmic-text-%commit%'
[cpal]='https://github.com/zed-industries/cpal;fd8bc2fd39f1f5fdee5a0690656caff9a26d9d50;cpal-%commit%'
[font-kit]='https://github.com/zed-industries/font-kit;40391b7c0041d8a8572af2afa3de32ae088f0120;font-kit-%commit%'
[git2]='https://github.com/rust-lang/git2-rs;a3b90cb3756c1bb63e2317bf9cfa57838178de5c;git2-rs-%commit%'
[libgit2-sys]='https://github.com/rust-lang/git2-rs;a3b90cb3756c1bb63e2317bf9cfa57838178de5c;git2-rs-%commit%/libgit2-sys'
[libwebrtc]='https://github.com/zed-industries/livekit-rust-sdks;060964da10574cd9bf06463a53bf6e0769c5c45e;livekit-rust-sdks-%commit%/libwebrtc'
[livekit-api]='https://github.com/zed-industries/livekit-rust-sdks;060964da10574cd9bf06463a53bf6e0769c5c45e;livekit-rust-sdks-%commit%/livekit-api'
[livekit-protocol]='https://github.com/zed-industries/livekit-rust-sdks;060964da10574cd9bf06463a53bf6e0769c5c45e;livekit-rust-sdks-%commit%/livekit-protocol'
[livekit-runtime]='https://github.com/zed-industries/livekit-rust-sdks;060964da10574cd9bf06463a53bf6e0769c5c45e;livekit-rust-sdks-%commit%/livekit-runtime'
[livekit]='https://github.com/zed-industries/livekit-rust-sdks;060964da10574cd9bf06463a53bf6e0769c5c45e;livekit-rust-sdks-%commit%/livekit'
[lsp-types]='https://github.com/zed-industries/lsp-types;72357d6f6d212bdffba3b5ef4b31d8ca856058e7;lsp-types-%commit%'
[nvim-rs]='https://github.com/KillTheMule/nvim-rs;69500bae73b8b3f02a05b7bee621a0d0e633da6c;nvim-rs-%commit%'
[oo7]='https://github.com/zed-industries/oo7;9d5d5fcd7e4e0add9b420ffb58f67661b0b37568;oo7-%commit%/client'
[pet-conda]='https://github.com/microsoft/python-environment-tools;1abe5cec5ebfbe97ca71746a4cfc7fe89bddf8e0;python-environment-tools-%commit%/crates/pet-conda'
[pet-core]='https://github.com/microsoft/python-environment-tools;1abe5cec5ebfbe97ca71746a4cfc7fe89bddf8e0;python-environment-tools-%commit%/crates/pet-core'
[pet-env-var-path]='https://github.com/microsoft/python-environment-tools;1abe5cec5ebfbe97ca71746a4cfc7fe89bddf8e0;python-environment-tools-%commit%/crates/pet-env-var-path'
[pet-fs]='https://github.com/microsoft/python-environment-tools;1abe5cec5ebfbe97ca71746a4cfc7fe89bddf8e0;python-environment-tools-%commit%/crates/pet-fs'
[pet-global-virtualenvs]='https://github.com/microsoft/python-environment-tools;1abe5cec5ebfbe97ca71746a4cfc7fe89bddf8e0;python-environment-tools-%commit%/crates/pet-global-virtualenvs'
[pet-homebrew]='https://github.com/microsoft/python-environment-tools;1abe5cec5ebfbe97ca71746a4cfc7fe89bddf8e0;python-environment-tools-%commit%/crates/pet-homebrew'
[pet-jsonrpc]='https://github.com/microsoft/python-environment-tools;1abe5cec5ebfbe97ca71746a4cfc7fe89bddf8e0;python-environment-tools-%commit%/crates/pet-jsonrpc'
[pet-linux-global-python]='https://github.com/microsoft/python-environment-tools;1abe5cec5ebfbe97ca71746a4cfc7fe89bddf8e0;python-environment-tools-%commit%/crates/pet-linux-global-python'
[pet-mac-commandlinetools]='https://github.com/microsoft/python-environment-tools;1abe5cec5ebfbe97ca71746a4cfc7fe89bddf8e0;python-environment-tools-%commit%/crates/pet-mac-commandlinetools'
[pet-mac-python-org]='https://github.com/microsoft/python-environment-tools;1abe5cec5ebfbe97ca71746a4cfc7fe89bddf8e0;python-environment-tools-%commit%/crates/pet-mac-python-org'
[pet-mac-xcode]='https://github.com/microsoft/python-environment-tools;1abe5cec5ebfbe97ca71746a4cfc7fe89bddf8e0;python-environment-tools-%commit%/crates/pet-mac-xcode'
[pet-pipenv]='https://github.com/microsoft/python-environment-tools;1abe5cec5ebfbe97ca71746a4cfc7fe89bddf8e0;python-environment-tools-%commit%/crates/pet-pipenv'
[pet-pixi]='https://github.com/microsoft/python-environment-tools;1abe5cec5ebfbe97ca71746a4cfc7fe89bddf8e0;python-environment-tools-%commit%/crates/pet-pixi'
[pet-poetry]='https://github.com/microsoft/python-environment-tools;1abe5cec5ebfbe97ca71746a4cfc7fe89bddf8e0;python-environment-tools-%commit%/crates/pet-poetry'
[pet-pyenv]='https://github.com/microsoft/python-environment-tools;1abe5cec5ebfbe97ca71746a4cfc7fe89bddf8e0;python-environment-tools-%commit%/crates/pet-pyenv'
[pet-python-utils]='https://github.com/microsoft/python-environment-tools;1abe5cec5ebfbe97ca71746a4cfc7fe89bddf8e0;python-environment-tools-%commit%/crates/pet-python-utils'
[pet-reporter]='https://github.com/microsoft/python-environment-tools;1abe5cec5ebfbe97ca71746a4cfc7fe89bddf8e0;python-environment-tools-%commit%/crates/pet-reporter'
[pet-telemetry]='https://github.com/microsoft/python-environment-tools;1abe5cec5ebfbe97ca71746a4cfc7fe89bddf8e0;python-environment-tools-%commit%/crates/pet-telemetry'
[pet-venv]='https://github.com/microsoft/python-environment-tools;1abe5cec5ebfbe97ca71746a4cfc7fe89bddf8e0;python-environment-tools-%commit%/crates/pet-venv'
[pet-virtualenv]='https://github.com/microsoft/python-environment-tools;1abe5cec5ebfbe97ca71746a4cfc7fe89bddf8e0;python-environment-tools-%commit%/crates/pet-virtualenv'
[pet-virtualenvwrapper]='https://github.com/microsoft/python-environment-tools;1abe5cec5ebfbe97ca71746a4cfc7fe89bddf8e0;python-environment-tools-%commit%/crates/pet-virtualenvwrapper'
[pet-windows-registry]='https://github.com/microsoft/python-environment-tools;1abe5cec5ebfbe97ca71746a4cfc7fe89bddf8e0;python-environment-tools-%commit%/crates/pet-windows-registry'
[pet-windows-store]='https://github.com/microsoft/python-environment-tools;1abe5cec5ebfbe97ca71746a4cfc7fe89bddf8e0;python-environment-tools-%commit%/crates/pet-windows-store'
[pet]='https://github.com/microsoft/python-environment-tools;1abe5cec5ebfbe97ca71746a4cfc7fe89bddf8e0;python-environment-tools-%commit%/crates/pet'
[reqwest]='https://github.com/zed-industries/reqwest;fd110f6998da16bbca97b6dddda9be7827c50e29;reqwest-%commit%'
[tree-sitter-gomod]='https://github.com/camdencheek/tree-sitter-go-mod;6efb59652d30e0e9cd5f3b3a669afd6f1a926d3c;tree-sitter-go-mod-%commit%'
[tree-sitter-gowork]='https://github.com/zed-industries/tree-sitter-go-work;acb0617bf7f4fda02c6217676cc64acb89536dc7;tree-sitter-go-work-%commit%'
[tree-sitter-heex]='https://github.com/zed-industries/tree-sitter-heex;1dd45142fbb05562e35b2040c6129c9bca346592;tree-sitter-heex-%commit%'
[tree-sitter-md]='https://github.com/tree-sitter-grammars/tree-sitter-markdown;9a23c1a96c0513d8fc6520972beedd419a973539;tree-sitter-markdown-%commit%'
[tree-sitter-yaml]='https://github.com/zed-industries/tree-sitter-yaml;baff0b51c64ef6a1fb1f8390f3ad6015b83ec13a;tree-sitter-yaml-%commit%'
[webrtc-sys-build]='https://github.com/zed-industries/livekit-rust-sdks;060964da10574cd9bf06463a53bf6e0769c5c45e;livekit-rust-sdks-%commit%/webrtc-sys/build'
[webrtc-sys]='https://github.com/zed-industries/livekit-rust-sdks;060964da10574cd9bf06463a53bf6e0769c5c45e;livekit-rust-sdks-%commit%/webrtc-sys'
[xim-ctext]='https://github.com/XDeme1/xim-rs;d50d461764c2213655cd9cf65a0ea94c70d3c4fd;xim-rs-%commit%/xim-ctext'
[xim-parser]='https://github.com/XDeme1/xim-rs;d50d461764c2213655cd9cf65a0ea94c70d3c4fd;xim-rs-%commit%/xim-parser'
[xim]='https://github.com/XDeme1/xim-rs;d50d461764c2213655cd9cf65a0ea94c70d3c4fd;xim-rs-%commit%'
[xkbcommon]='https://github.com/ConradIrwin/xkbcommon-rs;fcbb4612185cc129ceeff51d22f7fb51810a03b2;xkbcommon-rs-%commit%'
)

LLVM_COMPAT=( {18..19} )
RUST_MIN_VER="1.81.0"
RUST_NEEDS_LLVM=1
WEBRTC_COMMIT="dac8015-6"

inherit cargo check-reqs desktop flag-o-matic llvm-r1 toolchain-funcs xdg

DESCRIPTION="The fast, collaborative code editor"
HOMEPAGE="https://zed.dev https://github.com/zed-industries/zed"
SRC_URI="
https://github.com/zed-industries/zed/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz
https://gitlab.com/api/v4/projects/35204985/packages/generic/${PN}/${PV}/${P}-crates.tar.xz
amd64? (
https://github.com/livekit/rust-sdks/releases/download/webrtc-${WEBRTC_COMMIT}/webrtc-linux-x64-release.zip ->
webrtc-${WEBRTC_COMMIT}-linux-x64-release.zip
)
arm64? (
https://github.com/livekit/rust-sdks/releases/download/webrtc-${WEBRTC_COMMIT}/webrtc-linux-arm64-release.zip ->
webrtc-${WEBRTC_COMMIT}-linux-arm64-release.zip
)
${CARGO_CRATE_URIS}"

LICENSE="GPL-3+"
# Dependent crate licenses
LICENSE+="
Apache-2.0 Apache-2.0-with-LLVM-exceptions BSD-2 BSD CC0-1.0 ISC
LGPL-3 MIT MPL-2.0 Unicode-3.0 ZLIB
"
SLOT="0"
KEYWORDS="~amd64 ~arm64"
IUSE="gles"
CHECKREQS_DISK_BUILD="9G"
CHECKREQS_MEMORY="16G"

DEPEND="
app-arch/zstd:=
app-misc/jq
dev-db/sqlite:3
>=dev-libs/libgit2-1.9.0
dev-libs/mimalloc
dev-libs/openssl:0/3
dev-libs/protobuf
dev-libs/wayland
dev-libs/wayland-protocols
dev-util/wayland-scanner
dev-util/vulkan-tools
media-fonts/noto
media-libs/alsa-lib
media-libs/fontconfig
media-libs/vulkan-loader[X]
net-analyzer/openbsd-netcat
net-misc/curl
sys-libs/zlib
x11-libs/libxcb:=
x11-libs/libxkbcommon[X]
"
RDEPEND="${DEPEND}"
BDEPEND="
app-arch/unzip
dev-build/cmake
dev-util/vulkan-headers
sys-devel/gettext
sys-devel/mold
$(llvm_gen_dep '
llvm-core/clang:${LLVM_SLOT}=
llvm-core/llvm:${LLVM_SLOT}=
')
"

QA_FLAGS_IGNORED="usr/bin/zedit"

pkg_setup() {
if tc-is-gcc; then
export CARGO_PROFILE_RELEASE_LTO="true"
elif tc-is-clang; then
export CARGO_PROFILE_RELEASE_LTO="thin"
fi
strip-unsupported-flags
# flags from upstream
export RUSTFLAGS="${RUSTFLAGS} -C symbol-mangling-version=v0 --cfg tokio_unstable -C link-arg=-fuse-ld=mold -C link-args=-Wl,--disable-new-dtags,-rpath,\$ORIGIN/../lib"
# linking error with llvm-18
export RUSTFLAGS="${RUSTFLAGS} -C link-args=-Wl,-z,nostart-stop-gc"
# fix error in livekit-rust-sdks
export RUSTFLAGS="${RUSTFLAGS} -A unexpected_cfgs"
if use gles; then
export RUSTFLAGS="${RUSTFLAGS} --cfg gles"
fi
llvm-r1_pkg_setup
rust_pkg_setup
}

src_prepare() {
default

export APP_CLI="zedit"
export APP_ICON="zed"
export APP_ID="dev.zed.Zed"
export APP_NAME="Zed"
export APP_ARGS="%U"
export DO_STARTUP_NOTIFY="true"
envsubst < "crates/zed/resources/zed.desktop.in" > ${APP_ID}.desktop || die

# Cargo offline fetch workaround
local CPAL_COMMIT="fd8bc2fd39f1f5fdee5a0690656caff9a26d9d50"
local CPAL_GIT="git = \"https://github.com/zed-industries/cpal\", rev = \"${CPAL_COMMIT}\""
local CPAL_PATH="path = \"${WORKDIR}/cpal-${CPAL_COMMIT}\""

sed -e "s#${CPAL_GIT}#${CPAL_PATH}#" \
-i "${S}/Cargo.toml" || die "Cargo fetch workaround failed"
}

src_configure() {
cargo_src_configure --all-features
}

src_compile() {
export RELEASE_VERSION="${PV}"
export ZED_UPDATE_EXPLANATION='Updates are handled by portage'
if use arm64; then
export LK_CUSTOM_WEBRTC="${WORKDIR}/linux-arm64-release"
elif use amd64; then
export LK_CUSTOM_WEBRTC="${WORKDIR}/linux-x64-release"
fi
cargo_src_compile --package zed --package cli
}

src_install() {
newbin $(cargo_target_dir)/cli ${APP_CLI}
exeinto "/usr/libexec"
newexe $(cargo_target_dir)/zed zed-editor

newicon -s 512 crates/zed/resources/app-icon.png zed.png
newicon -s 1024 crates/zed/resources/[email protected] zed.png
domenu "${S}/${APP_ID}.desktop"
}

src_test () {
mkdir -p "${HOME}/.config/zed" || die
mkdir -p "${HOME}/.local/share/zed/logs/" || die

SHELL=/usr/bin/sh RUST_BACKTRACE=full cargo_src_test -vv
}

0 comments on commit 30d2418

Please sign in to comment.