mirror of
https://github.com/zed-industries/zed.git
synced 2024-11-08 07:35:01 +03:00
Bundle linux deps (#11681)
Inlcude linux deps in the bundle Release Notes: - N/A
This commit is contained in:
parent
8e92f19fed
commit
9af1298a7f
25
Cargo.lock
generated
25
Cargo.lock
generated
@ -621,6 +621,18 @@ dependencies = [
|
|||||||
"url",
|
"url",
|
||||||
]
|
]
|
||||||
|
|
||||||
|
[[package]]
|
||||||
|
name = "async-native-tls"
|
||||||
|
version = "0.5.0"
|
||||||
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
|
checksum = "9343dc5acf07e79ff82d0c37899f079db3534d99f189a1837c8e549c99405bec"
|
||||||
|
dependencies = [
|
||||||
|
"futures-util",
|
||||||
|
"native-tls",
|
||||||
|
"thiserror",
|
||||||
|
"url",
|
||||||
|
]
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "async-net"
|
name = "async-net"
|
||||||
version = "1.7.0"
|
version = "1.7.0"
|
||||||
@ -815,7 +827,7 @@ version = "0.16.1"
|
|||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
checksum = "5682ea0913e5c20780fe5785abacb85a411e7437bf52a1bedb93ddb3972cb8dd"
|
checksum = "5682ea0913e5c20780fe5785abacb85a411e7437bf52a1bedb93ddb3972cb8dd"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"async-native-tls",
|
"async-native-tls 0.3.3",
|
||||||
"async-std",
|
"async-std",
|
||||||
"futures-io",
|
"futures-io",
|
||||||
"futures-util",
|
"futures-util",
|
||||||
@ -2185,6 +2197,7 @@ name = "client"
|
|||||||
version = "0.1.0"
|
version = "0.1.0"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"anyhow",
|
"anyhow",
|
||||||
|
"async-native-tls 0.5.0",
|
||||||
"async-recursion 0.3.2",
|
"async-recursion 0.3.2",
|
||||||
"async-tungstenite",
|
"async-tungstenite",
|
||||||
"chrono",
|
"chrono",
|
||||||
@ -6899,6 +6912,15 @@ version = "0.1.5"
|
|||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
checksum = "ff011a302c396a5197692431fc1948019154afc178baf7d8e37367442a4601cf"
|
checksum = "ff011a302c396a5197692431fc1948019154afc178baf7d8e37367442a4601cf"
|
||||||
|
|
||||||
|
[[package]]
|
||||||
|
name = "openssl-src"
|
||||||
|
version = "300.2.3+3.2.1"
|
||||||
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
|
checksum = "5cff92b6f71555b61bb9315f7c64da3ca43d87531622120fea0195fc761b4843"
|
||||||
|
dependencies = [
|
||||||
|
"cc",
|
||||||
|
]
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "openssl-sys"
|
name = "openssl-sys"
|
||||||
version = "0.9.93"
|
version = "0.9.93"
|
||||||
@ -6907,6 +6929,7 @@ checksum = "db4d56a4c0478783083cfafcc42493dd4a981d41669da64b4572a2a089b51b1d"
|
|||||||
dependencies = [
|
dependencies = [
|
||||||
"cc",
|
"cc",
|
||||||
"libc",
|
"libc",
|
||||||
|
"openssl-src",
|
||||||
"pkg-config",
|
"pkg-config",
|
||||||
"vcpkg",
|
"vcpkg",
|
||||||
]
|
]
|
||||||
|
@ -19,6 +19,7 @@ test-support = ["clock/test-support", "collections/test-support", "gpui/test-sup
|
|||||||
anyhow.workspace = true
|
anyhow.workspace = true
|
||||||
async-recursion = "0.3"
|
async-recursion = "0.3"
|
||||||
async-tungstenite = { version = "0.16", features = ["async-std", "async-native-tls"] }
|
async-tungstenite = { version = "0.16", features = ["async-std", "async-native-tls"] }
|
||||||
|
async-native-tls = { version = "0.5.0", features = ["vendored"] }
|
||||||
chrono = { workspace = true, features = ["serde"] }
|
chrono = { workspace = true, features = ["serde"] }
|
||||||
clock.workspace = true
|
clock.workspace = true
|
||||||
collections.workspace = true
|
collections.workspace = true
|
||||||
@ -58,3 +59,10 @@ rpc = { workspace = true, features = ["test-support"] }
|
|||||||
settings = { workspace = true, features = ["test-support"] }
|
settings = { workspace = true, features = ["test-support"] }
|
||||||
util = { workspace = true, features = ["test-support"] }
|
util = { workspace = true, features = ["test-support"] }
|
||||||
http = { workspace = true, features = ["test-support"] }
|
http = { workspace = true, features = ["test-support"] }
|
||||||
|
|
||||||
|
[target.'cfg(target_os = "linux")'.dependencies]
|
||||||
|
async-native-tls = {"version" = "0.5.0", features = ["vendored"]}
|
||||||
|
# This is an indirect dependency of async-tungstenite that is included
|
||||||
|
# here so we can vendor libssl with the feature flag.
|
||||||
|
[package.metadata.cargo-machete]
|
||||||
|
ignored = ["async-native-tls"]
|
||||||
|
@ -27,7 +27,7 @@ export ZED_BUNDLE=true
|
|||||||
|
|
||||||
channel=$(<crates/zed/RELEASE_CHANNEL)
|
channel=$(<crates/zed/RELEASE_CHANNEL)
|
||||||
|
|
||||||
version="$(cargo metadata --no-deps --manifest-path crates/zed/Cargo.toml --offline --format-version=1 | jq -r '.packages | map(select(.name == "zed"))[0].version')"
|
version="$(script/get-crate-version zed)"
|
||||||
# Set RELEASE_VERSION so it's compiled into GPUI and it knows about the version.
|
# Set RELEASE_VERSION so it's compiled into GPUI and it knows about the version.
|
||||||
export RELEASE_VERSION="${version}"
|
export RELEASE_VERSION="${version}"
|
||||||
|
|
||||||
@ -38,6 +38,7 @@ host_line=$(echo "$version_info" | grep host)
|
|||||||
target_triple=${host_line#*: }
|
target_triple=${host_line#*: }
|
||||||
|
|
||||||
# Build binary in release mode
|
# Build binary in release mode
|
||||||
|
export RUSTFLAGS="-C link-args=-Wl,-rpath,\$ORIGIN/../lib"
|
||||||
cargo build --release --target "${target_triple}" --package zed --package cli
|
cargo build --release --target "${target_triple}" --package zed --package cli
|
||||||
|
|
||||||
# Strip the binary of all debug symbols
|
# Strip the binary of all debug symbols
|
||||||
@ -60,6 +61,17 @@ mkdir -p "${zed_dir}/bin"
|
|||||||
cp "target/${target_triple}/release/Zed" "${zed_dir}/bin/zed"
|
cp "target/${target_triple}/release/Zed" "${zed_dir}/bin/zed"
|
||||||
cp "target/${target_triple}/release/cli" "${zed_dir}/bin/cli"
|
cp "target/${target_triple}/release/cli" "${zed_dir}/bin/cli"
|
||||||
|
|
||||||
|
# Libs
|
||||||
|
find_libs() {
|
||||||
|
ldd target/debug/Zed |\
|
||||||
|
cut -d' ' -f3 |\
|
||||||
|
grep -v '\<\(libstdc++.so\|libc.so\|libgcc_s.so\|libm.so\)'
|
||||||
|
}
|
||||||
|
|
||||||
|
mkdir -p "${zed_dir}/lib"
|
||||||
|
rm -rf "${zed_dir}/lib/*"
|
||||||
|
cp $(find_libs) "${zed_dir}/lib"
|
||||||
|
|
||||||
# Icons
|
# Icons
|
||||||
mkdir -p "${zed_dir}/share/icons/hicolor/512x512/apps"
|
mkdir -p "${zed_dir}/share/icons/hicolor/512x512/apps"
|
||||||
cp "crates/zed/resources/app-icon$suffix.png" "${zed_dir}/share/icons/hicolor/512x512/apps/zed.png"
|
cp "crates/zed/resources/app-icon$suffix.png" "${zed_dir}/share/icons/hicolor/512x512/apps/zed.png"
|
||||||
|
Loading…
Reference in New Issue
Block a user