zed: update to 0.137.3
This commit is contained in:
committed by
GitHub
parent
e315e3fd42
commit
20325aabb5
@@ -1,65 +0,0 @@
|
||||
diff --git a/Cargo.lock b/Cargo.lock
|
||||
index d8681c4be..335a0a399 100644
|
||||
--- a/Cargo.lock
|
||||
+++ b/Cargo.lock
|
||||
@@ -3056,8 +3056,7 @@ dependencies = [
|
||||
[[package]]
|
||||
name = "curl-sys"
|
||||
version = "0.4.67+curl-8.3.0"
|
||||
-source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
-checksum = "3cc35d066510b197a0f72de863736641539957628c8a42e70e27c66849e77c34"
|
||||
+source = "git+https://github.com/ognevny/curl-rust.git?branch=sys-0.4.67-dynamic-mingw#077c35c6b5331042e3ba22e879c8b0bebe7bbf93"
|
||||
dependencies = [
|
||||
"cc",
|
||||
"libc",
|
||||
@@ -5824,8 +5823,7 @@ dependencies = [
|
||||
[[package]]
|
||||
name = "libz-sys"
|
||||
version = "1.1.12"
|
||||
-source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
-checksum = "d97137b25e321a73eef1418d1d5d2eda4d77e12813f8e6dead84bc52c5870a7b"
|
||||
+source = "git+https://github.com/ognevny/libz-sys.git?branch=sys-1.1.12-dynamic#c7fac58eed1671bf350fc28e5fb193c7f37cd6b8"
|
||||
dependencies = [
|
||||
"cc",
|
||||
"libc",
|
||||
@@ -13221,12 +13219,10 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "zstd-sys"
|
||||
-version = "2.0.8+zstd.1.5.5"
|
||||
-source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
-checksum = "5556e6ee25d32df2586c098bbfa278803692a20d0ab9565e049480d52707ec8c"
|
||||
+version = "2.0.10+zstd.1.5.6"
|
||||
+source = "git+https://github.com/ognevny/zstd-rs.git?branch=sys-2.0.10-dynamic#ae8ea299d53178d5b947f7c04b2d738f06d1330f"
|
||||
dependencies = [
|
||||
"cc",
|
||||
- "libc",
|
||||
"pkg-config",
|
||||
]
|
||||
|
||||
diff --git a/Cargo.toml b/Cargo.toml
|
||||
index 5785e5b7a..5b32a12c3 100644
|
||||
--- a/Cargo.toml
|
||||
+++ b/Cargo.toml
|
||||
@@ -286,10 +286,7 @@ hex = "0.4.3"
|
||||
ignore = "0.4.22"
|
||||
indoc = "1"
|
||||
# We explicitly disable http2 support in isahc.
|
||||
-isahc = { version = "1.7.2", default-features = false, features = [
|
||||
- "static-curl",
|
||||
- "text-decoding",
|
||||
-] }
|
||||
+isahc = { version = "1.7.2", default-features = false, features = ["text-decoding"] }
|
||||
itertools = "0.11.0"
|
||||
lazy_static = "1.4.0"
|
||||
libc = "0.2"
|
||||
@@ -429,6 +426,9 @@ features = [
|
||||
tree-sitter = { git = "https://github.com/tree-sitter/tree-sitter", rev = "7b4894ba2ae81b988846676f54c0988d4027ef4f" }
|
||||
# Workaround for a broken nightly build of gpui: See #7644 and revisit once 0.5.3 is released.
|
||||
pathfinder_simd = { git = "https://github.com/servo/pathfinder.git", rev = "30419d07660dc11a21e42ef4a7fa329600cff152" }
|
||||
+curl-sys = { git = "https://github.com/ognevny/curl-rust.git", branch = "sys-0.4.67-dynamic-mingw" }
|
||||
+zstd-sys = { git = "https://github.com/ognevny/zstd-rs.git", branch = "sys-2.0.10-dynamic" }
|
||||
+libz-sys = { git = "https://github.com/ognevny/libz-sys.git", branch = "sys-1.1.12-dynamic" }
|
||||
|
||||
[profile.dev]
|
||||
split-debuginfo = "unpacked"
|
||||
@@ -3,7 +3,7 @@
|
||||
_realname=zed
|
||||
pkgbase=mingw-w64-${_realname}
|
||||
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
|
||||
pkgver=0.136.2
|
||||
pkgver=0.137.3
|
||||
pkgrel=1
|
||||
pkgdesc="A high-performance, multiplayer code editor (mingw-w64)"
|
||||
arch=('any')
|
||||
@@ -24,25 +24,41 @@ makedepends=("${MINGW_PACKAGE_PREFIX}-rust"
|
||||
"${MINGW_PACKAGE_PREFIX}-pkgconf"
|
||||
"${MINGW_PACKAGE_PREFIX}-fontconfig"
|
||||
"${MINGW_PACKAGE_PREFIX}-openssl"
|
||||
"${MINGW_PACKAGE_PREFIX}-sqlite3"
|
||||
'git')
|
||||
_commit=8629a076a74756af9737e4e07c7523e43f6b3697
|
||||
"${MINGW_PACKAGE_PREFIX}-sqlite3")
|
||||
source=("https://github.com/zed-industries/zed/archive/v${pkgver}/${_realname}-${pkgver}.tar.gz"
|
||||
"001-download-pc-windows-gnu-assets.patch"
|
||||
"002-link-sys-libs-dynamically.patch")
|
||||
sha256sums=('caf4f16fcc8490fc220a507d2287cfac6a84041c03bd9f51b5b4f63f0704737e'
|
||||
'7833a245a982a6d23e16c71e2f7995461c1d0c869aeb6c94108f0f011d90d2ff'
|
||||
'47c9c44b7681d5a013f3a5a2be72abb5a68c13b0c9c070470b97c23097ce3a49')
|
||||
"zstd-sys.tar.gz::https://crates.io/api/v1/crates/zstd-sys/2.0.10+zstd.1.5.6/download"
|
||||
"curl-sys.tar.gz::https://crates.io/api/v1/crates/curl-sys/0.4.67+curl-8.3.0/download"
|
||||
"zed-download-pc-windows-gnu-assets.patch"
|
||||
"zed-use-vendored-deps.patch"
|
||||
"zed-use-dynamic-curl.patch"
|
||||
"curl-sys-use-pkgconfig.patch"
|
||||
"zstd-sys-remove-statik.patch")
|
||||
sha256sums=('d80b144ae7c3b7b2d0266256cd9d6994cbaad46e2d9800d88c622de67034fc7a'
|
||||
'c253a4914af5bafc8fa8c86ee400827e83cf6ec01195ec1f1ed8441bf00d65aa'
|
||||
'3cc35d066510b197a0f72de863736641539957628c8a42e70e27c66849e77c34'
|
||||
'94ca0bc7ae6f73bc4cdb9dd02af2946541b2bee7c71f279a4eeef1f987e76fe4'
|
||||
'e1f0d6f1265a2a13db2cd5cb7e0a3e877de470edd06d06c6a7c92eddefdfb657'
|
||||
'9a6326a5389e07ff6cfe6eccaa7310d5fc3d88e70b11114a8d5db23a6d33c62a'
|
||||
'0e008fc69c67a5e79b05815625ffcef2d008e6b5a4bb0350c90772c49d2ca748'
|
||||
'48f4900ceb02d3aaf9a1020f33d56629156e96759f456c0e7ca18bfcf910767b')
|
||||
noextract=("${_realname}-${pkgver}.tar.gz")
|
||||
|
||||
prepare() {
|
||||
tar -xzf "${_realname}-${pkgver}.tar.gz" || true
|
||||
cd "${srcdir}/${_realname}-${pkgver}"
|
||||
cd "${_realname}-${pkgver}"
|
||||
|
||||
rm -f rust-toolchain.toml
|
||||
|
||||
patch -Np1 -i "${srcdir}/001-download-pc-windows-gnu-assets.patch"
|
||||
patch -Np1 -i "${srcdir}/002-link-sys-libs-dynamically.patch"
|
||||
# download assets for x86_64-pc-windows-gnu target for some extensions
|
||||
patch -Np1 -i "${srcdir}/zed-download-pc-windows-gnu-assets.patch"
|
||||
# vendor some *-sys crates to make them linked dynamically
|
||||
patch -Np1 -i "${srcdir}/zed-use-vendored-deps.patch"
|
||||
# link some system deps dynamically
|
||||
patch -Np1 -i "${srcdir}/zed-use-dynamic-curl.patch"
|
||||
patch -d "../curl-sys-0.4.67+curl-8.3.0" -i "${srcdir}/curl-sys-use-pkgconfig.patch"
|
||||
patch -d "../zstd-sys-2.0.10+zstd.1.5.6" -i "${srcdir}/zstd-sys-remove-statik.patch"
|
||||
|
||||
cargo update -p curl-sys -p zstd-sys
|
||||
|
||||
cargo fetch --locked --target "$(rustc -vV | sed -n 's/host: //p')"
|
||||
}
|
||||
@@ -60,7 +76,7 @@ _env() {
|
||||
}
|
||||
|
||||
build() {
|
||||
cd "${srcdir}/${_realname}-${pkgver}"
|
||||
cd "${_realname}-${pkgver}"
|
||||
|
||||
_env
|
||||
# remove a werror from gcc 14
|
||||
@@ -73,24 +89,13 @@ build() {
|
||||
}
|
||||
|
||||
check() {
|
||||
cd "${srcdir}/${_realname}-${pkgver}-pre"
|
||||
cd "${_realname}-${pkgver}-pre"
|
||||
|
||||
_env
|
||||
cargo test --release --frozen -p zed
|
||||
}
|
||||
|
||||
package() {
|
||||
cd "${srcdir}/${_realname}-${pkgver}"
|
||||
|
||||
_env
|
||||
cargo install \
|
||||
--frozen \
|
||||
--offline \
|
||||
--no-track \
|
||||
--path crates/zed \
|
||||
--root "${pkgdir}${MINGW_PREFIX}"
|
||||
|
||||
# rename the binary
|
||||
mv "${pkgdir}${MINGW_PREFIX}/bin/Zed" "${pkgdir}${MINGW_PREFIX}/bin/zed"
|
||||
install -Dm644 LICENSE-{AGPL,APACHE,GPL} -t "${pkgdir}${MINGW_PREFIX}/share/licenses/${_realname}/"
|
||||
install -Dm755 "${_realname}-${pkgver}/target/release/Zed" "${pkgdir}${MINGW_PREFIX}/bin/zed"
|
||||
install -Dm644 "${_realname}-${pkgver}"/LICENSE-{AGPL,APACHE,GPL} -t "${pkgdir}${MINGW_PREFIX}/share/licenses/${_realname}/"
|
||||
}
|
||||
|
||||
11
mingw-w64-zed/curl-sys-use-pkgconfig.patch
Normal file
11
mingw-w64-zed/curl-sys-use-pkgconfig.patch
Normal file
@@ -0,0 +1,11 @@
|
||||
--- a/build.rs
|
||||
+++ b/build.rs
|
||||
@@ -28,7 +28,7 @@ fn main() {
|
||||
}
|
||||
|
||||
// Next, fall back and try to use pkg-config if its available.
|
||||
- if windows {
|
||||
+ if target.contains("msvc") {
|
||||
if try_vcpkg() {
|
||||
return;
|
||||
}
|
||||
@@ -1,5 +1,3 @@
|
||||
diff --git a/crates/languages/src/rust.rs b/crates/languages/src/rust.rs
|
||||
index 0b8e449f4..b50e6dd2b 100644
|
||||
--- a/crates/languages/src/rust.rs
|
||||
+++ b/crates/languages/src/rust.rs
|
||||
@@ -77,7 +77,7 @@ impl LspAdapter for RustLspAdapter {
|
||||
@@ -11,8 +9,6 @@ index 0b8e449f4..b50e6dd2b 100644
|
||||
other => bail!("Running on unsupported os: {other}"),
|
||||
};
|
||||
let asset_name = format!("rust-analyzer-{}-{os}.gz", consts::ARCH);
|
||||
diff --git a/extensions/deno/src/deno.rs b/extensions/deno/src/deno.rs
|
||||
index 02231765d..8e1ab4959 100644
|
||||
--- a/extensions/deno/src/deno.rs
|
||||
+++ b/extensions/deno/src/deno.rs
|
||||
@@ -47,7 +47,7 @@ impl DenoExtension {
|
||||
@@ -23,9 +19,7 @@ index 02231765d..8e1ab4959 100644
|
||||
+ zed::Os::Windows => "pc-windows-gnu",
|
||||
},
|
||||
);
|
||||
|
||||
diff --git a/extensions/gleam/src/gleam.rs b/extensions/gleam/src/gleam.rs
|
||||
index 8deef729d..bfafaa435 100644
|
||||
|
||||
--- a/extensions/gleam/src/gleam.rs
|
||||
+++ b/extensions/gleam/src/gleam.rs
|
||||
@@ -47,7 +47,7 @@ impl GleamExtension {
|
||||
@@ -36,4 +30,3 @@ index 8deef729d..bfafaa435 100644
|
||||
+ zed::Os::Windows => "pc-windows-gnu",
|
||||
},
|
||||
);
|
||||
|
||||
14
mingw-w64-zed/zed-use-dynamic-curl.patch
Normal file
14
mingw-w64-zed/zed-use-dynamic-curl.patch
Normal file
@@ -0,0 +1,14 @@
|
||||
--- a/Cargo.toml
|
||||
+++ b/Cargo.toml
|
||||
@@ -291,10 +291,7 @@ hex = "0.4.3"
|
||||
ignore = "0.4.22"
|
||||
indoc = "1"
|
||||
# We explicitly disable http2 support in isahc.
|
||||
-isahc = { version = "1.7.2", default-features = false, features = [
|
||||
- "static-curl",
|
||||
- "text-decoding",
|
||||
-] }
|
||||
+isahc = { version = "1.7.2", default-features = false, features = ["text-decoding"] }
|
||||
itertools = "0.11.0"
|
||||
lazy_static = "1.4.0"
|
||||
libc = "0.2"
|
||||
11
mingw-w64-zed/zed-use-vendored-deps.patch
Normal file
11
mingw-w64-zed/zed-use-vendored-deps.patch
Normal file
@@ -0,0 +1,11 @@
|
||||
--- a/Cargo.toml
|
||||
+++ b/Cargo.toml
|
||||
@@ -434,6 +434,8 @@ features = [
|
||||
tree-sitter = { git = "https://github.com/tree-sitter/tree-sitter", rev = "7b4894ba2ae81b988846676f54c0988d4027ef4f" }
|
||||
# Workaround for a broken nightly build of gpui: See #7644 and revisit once 0.5.3 is released.
|
||||
pathfinder_simd = { git = "https://github.com/servo/pathfinder.git", rev = "30419d07660dc11a21e42ef4a7fa329600cff152" }
|
||||
+curl-sys = { path = "../curl-sys-0.4.67+curl-8.3.0" }
|
||||
+zstd-sys = { path = "../zstd-sys-2.0.10+zstd.1.5.6" }
|
||||
|
||||
[profile.dev]
|
||||
split-debuginfo = "unpacked"
|
||||
10
mingw-w64-zed/zstd-sys-remove-statik.patch
Normal file
10
mingw-w64-zed/zstd-sys-remove-statik.patch
Normal file
@@ -0,0 +1,10 @@
|
||||
--- a/build.rs
|
||||
+++ b/build.rs
|
||||
@@ -41,7 +41,6 @@ fn generate_bindings(_: Vec<&str>, _: Vec<PathBuf>) {}
|
||||
|
||||
fn pkg_config() -> (Vec<&'static str>, Vec<PathBuf>) {
|
||||
let library = pkg_config::Config::new()
|
||||
- .statik(true)
|
||||
.cargo_metadata(!cfg!(feature = "non-cargo"))
|
||||
.probe("libzstd")
|
||||
.expect("Can't probe for zstd in pkg-config");
|
||||
Reference in New Issue
Block a user