Skip to content

Commit 277edca

Browse files
committed
New package: zeditor-0.231.2
1 parent 1785acd commit 277edca

2 files changed

Lines changed: 79 additions & 0 deletions

File tree

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
diff --git a/assets/settings/default.json b/assets/settings/default.json
2+
index efb0cc9..08fc993 100644
3+
--- a/assets/settings/default.json
4+
+++ b/assets/settings/default.json
5+
@@ -1240,9 +1240,9 @@
6+
// Control what info is collected by Zed.
7+
"telemetry": {
8+
// Send debug info like crash reports.
9+
- "diagnostics": true,
10+
+ "diagnostics": false,
11+
// Send anonymized usage data like what languages you're using Zed with.
12+
- "metrics": true,
13+
+ "metrics": false
14+
},
15+
// Whether to disable all AI features in Zed.
16+
//

srcpkgs/zed/template

Lines changed: 63 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,63 @@
1+
# Template file for 'zed'
2+
pkgname=zed
3+
version=0.231.2
4+
revision=1
5+
archs="x86_64* aarch64*"
6+
build_style=cargo
7+
make_build_args="--package cli --package zed" # --package remote_server # reason below
8+
make_check_args="--workspace"
9+
hostmakedepends="pkg-config cmake gettext perl libzstd-devel bzip2-devel protobuf lld"
10+
makedepends="gettext-devel elfutils-devel alsa-lib-devel fontconfig-devel glib-devel libva-devel libxcb-devel libxkbcommon-devel libzstd-devel openssl-devel wayland-devel vulkan-loader sqlite-devel libX11-devel libgit2-1.9-devel"
11+
short_desc="High-performance, multiplayer code editor"
12+
maintainer="JudahJL <judahlegy@gmail.com>"
13+
license="GPL-3.0-or-later"
14+
homepage="https://zed.dev/"
15+
distfiles="https://github.com/zed-industries/zed/archive/refs/tags/v${version}.tar.gz"
16+
checksum=f99e05b97fd8bc715707ad08e9178a090114caab622370a45ade8e77fd106a39
17+
make_check=ci-skip # too slow and memory-intensive for build environment(OS killed test process and tests on average used ~50 Gb of memory locally)
18+
# https://github.com/void-linux/void-packages/actions/runs/24108190211/job/70336496775 for reference
19+
20+
if [ $XBPS_TARGET_LIBC == "musl" ]; then
21+
makedepends+=" musl-devel"
22+
fi
23+
24+
pre_build() {
25+
echo -n stable > crates/zed/RELEASE_CHANNEL
26+
export RELEASE_VERSION="${version}"
27+
export ZED_UPDATE_EXPLANATION="Please use 'xbps-install -Su' to update."
28+
export ZED_BUNDLE=true
29+
30+
if [ "$CROSS_BUILD" ]; then
31+
export PKG_CONFIG_ALLOW_CROSS=1
32+
33+
# workaround the cc-rs mixing CFLAGS for host and target.
34+
# https://github.com/rust-lang/cc-rs/issues/1469
35+
export CFLAGS_${RUST_BUILD//-/_}="${CFLAGS_host}" \
36+
CXXFLAGS_${RUST_BUILD//-/_}="${CXXFLAGS_host}" \
37+
LDFLAGS_${RUST_BUILD//-/_}="${LDFLAGS_host}" \
38+
CFLAGS_${RUST_TARGET//-/_}="${CFLAGS}" \
39+
CXXFLAGS_${RUST_TARGET//-/_}="${CXXFLAGS}" \
40+
LDFLAGS_${RUST_TARGET//-/_}="${LDFLAGS}" \
41+
CFLAGS="" CXXFLAGS="" LDFLAGS=""
42+
fi
43+
}
44+
45+
do_install() {
46+
vbin "target/${RUST_TARGET}/release/cli" zed-cli
47+
vinstall "target/${RUST_TARGET}/release/zed" 755 usr/libexec zed-editor
48+
# TODO 1: https://github.com/zed-industries/zed/blob/c372f246a0790da012dddbe3935ee2758a3a9c3b/script/bundle-linux#L87-L88 seperately build remote_server. will include it later.
49+
# TODO 2: confirm install location of remote_server
50+
# vinstall "target/${RUST_TARGET}/release/remote_server" 755 usr/libexec
51+
52+
export APP_NAME="Zed"
53+
export APP_CLI="zed-cli"
54+
export APP_ICON="zed"
55+
export APP_ARGS="%U"
56+
export DO_STARTUP_NOTIFY="true"
57+
58+
envsubst < "crates/zed/resources/zed.desktop.in" > "dev.zed.Zed.desktop"
59+
vinstall "dev.zed.Zed.desktop" 644 usr/share/applications
60+
61+
vinstall "crates/zed/resources/app-icon.png" 644 usr/share/icons/hicolor/512x512/apps zed.png
62+
vinstall "crates/zed/resources/app-icon@2x.png" 644 usr/share/icons/hicolor/1024x1024/apps zed.png
63+
}

0 commit comments

Comments
 (0)