From: Logarithmus <Logarithmus@users.noreply.github.com>
To: ml@inbox.vuxu.org
Subject: Re: [PR PATCH] [Updated] New package: wezterm-20210405.110924.a5bb5be8
Date: Mon, 03 May 2021 01:40:10 +0200 [thread overview]
Message-ID: <20210502234010.2jvbKERxvKGm-E51A6UU1lF1quaUnLobTX91gJT-pdQ@z> (raw)
In-Reply-To: <gh-mailinglist-notifications-41a7ca26-5023-4802-975b-f1789d68868e-void-packages-30619@inbox.vuxu.org>
[-- Attachment #1: Type: text/plain, Size: 1594 bytes --]
There is an updated pull request by Logarithmus against master on the void-packages repository
https://github.com/Logarithmus/void-packages wezterm
https://github.com/void-linux/void-packages/pull/30619
New package: wezterm-20210405.110924.a5bb5be8
<!-- Mark items with [x] where applicable -->
#### General
- [x] This is a new package and it conforms to the [quality requirements](https://github.com/void-linux/void-packages/blob/master/Manual.md#quality-requirements)
#### Have the results of the proposed changes been tested?
- [x] I use the packages affected by the proposed changes on a regular basis and confirm this PR works for me
- [ ] I generally don't use the affected packages but briefly tested this PR
<!--
If GitHub CI cannot be used to validate the build result (for example, if the
build is likely to take several hours), make sure to
[skip CI](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration).
When skipping CI, uncomment and fill out the following section.
Note: for builds that are likely to complete in less than 2 hours, it is not
acceptable to skip CI.
-->
<!--
#### Does it build and run successfully?
(Please choose at least one native build and, if supported, at least one cross build. More are better.)
- [ ] I built this PR locally for my native architecture, (ARCH-LIBC)
- [ ] I built this PR locally for these architectures (if supported. mark crossbuilds):
- [ ] aarch64-musl
- [ ] armv7l
- [ ] armv6l-musl
-->
A patch file from https://github.com/void-linux/void-packages/pull/30619.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-wezterm-30619.patch --]
[-- Type: text/x-diff, Size: 5445 bytes --]
From a10abce22cdc86c318c4622ae372ea48e322c71a Mon Sep 17 00:00:00 2001
From: Artur Sinila <freesoftware@logarithmus.dev>
Date: Fri, 2 Apr 2021 04:34:12 +0300
Subject: [PATCH] New package: wezterm-20210405.110924.a5bb5be8
---
.../wezterm/patches/00-cargo-resolver.patch | 32 +++++++++++++
srcpkgs/wezterm/patches/01-sysdeps.patch | 38 +++++++++++++++
srcpkgs/wezterm/template | 48 +++++++++++++++++++
3 files changed, 118 insertions(+)
create mode 100644 srcpkgs/wezterm/patches/00-cargo-resolver.patch
create mode 100644 srcpkgs/wezterm/patches/01-sysdeps.patch
create mode 100644 srcpkgs/wezterm/template
diff --git a/srcpkgs/wezterm/patches/00-cargo-resolver.patch b/srcpkgs/wezterm/patches/00-cargo-resolver.patch
new file mode 100644
index 000000000000..0b5d4385abcf
--- /dev/null
+++ b/srcpkgs/wezterm/patches/00-cargo-resolver.patch
@@ -0,0 +1,32 @@
+--- Cargo.toml
++++ Cargo.toml
+@@ -1,3 +1,5 @@
++cargo-features = ["resolver"]
++
+ [workspace]
+ members = ["wezterm-mux-server", "wezterm", "wezterm-gui", "strip-ansi-escapes", "wezterm-ssh"]
+ resolver = "2"
+--- async_ossl/Cargo.toml
++++ async_ossl/Cargo.toml
+@@ -1,3 +1,5 @@
++cargo-features = ["resolver"]
++
+ [package]
+ name = "async_ossl"
+ version = "0.1.0"
+--- wezterm-gui/Cargo.toml
++++ wezterm-gui/Cargo.toml
+@@ -1,3 +1,5 @@
++cargo-features = ["resolver"]
++
+ [package]
+ name = "wezterm-gui"
+ version = "0.1.0"
+--- wezterm-mux-server/Cargo.toml
++++ wezterm-mux-server/Cargo.toml
+@@ -1,3 +1,5 @@
++cargo-features = ["resolver"]
++
+ [package]
+ name = "wezterm-mux-server"
+ version = "0.1.0"
diff --git a/srcpkgs/wezterm/patches/01-sysdeps.patch b/srcpkgs/wezterm/patches/01-sysdeps.patch
new file mode 100644
index 000000000000..01764ddfb8ff
--- /dev/null
+++ b/srcpkgs/wezterm/patches/01-sysdeps.patch
@@ -0,0 +1,38 @@
+--- deps/freetype/build.rs
++++ deps/freetype/build.rs
+@@ -74,9 +74,16 @@ fn freetype() {
+ }
+
+ fn main() {
+- zlib();
+- libpng();
+- freetype();
++ println!("cargo:rerun-if-env-changed=WEZTERM_SYSDEPS");
++ if cfg!(unix) && env::var("WEZTERM_SYSDEPS").map(|x| x == "1").unwrap_or(false) {
++ println!("cargo:rustc-link-lib=z");
++ println!("cargo:rustc-link-lib=png");
++ println!("cargo:rustc-link-lib=freetype");
++ } else {
++ zlib();
++ libpng();
++ freetype();
++ }
+ let out_dir = env::var("OUT_DIR").unwrap();
+ println!("cargo:outdir={}", out_dir);
+ println!("cargo:rustc-env=MACOSX_DEPLOYMENT_TARGET=10.9");
+--- deps/harfbuzz/build.rs
++++ deps/harfbuzz/build.rs
+@@ -45,7 +45,12 @@ fn emit_libdirs(p: &Path) {
+ }
+
+ fn main() {
+- harfbuzz();
++ println!("cargo:rerun-if-env-changed=WEZTERM_SYSDEPS");
++ if cfg!(unix) && env::var("WEZTERM_SYSDEPS").map(|x| x == "1").unwrap_or(false) {
++ println!("cargo:rustc-link-lib=harfbuzz");
++ } else {
++ harfbuzz();
++ }
+ let out_dir = env::var("OUT_DIR").unwrap();
+ println!("cargo:outdir={}", out_dir);
+ println!("cargo:rustc-env=MACOSX_DEPLOYMENT_TARGET=10.9");
diff --git a/srcpkgs/wezterm/template b/srcpkgs/wezterm/template
new file mode 100644
index 000000000000..c1ad30f132fb
--- /dev/null
+++ b/srcpkgs/wezterm/template
@@ -0,0 +1,48 @@
+# Template file for 'wezterm'
+pkgname=wezterm
+version=20210405.110924.a5bb5be8
+revision=1
+_version=${version//./-}
+wrksrc="${pkgname}-${_version}"
+build_style=cargo
+hostmakedepends="pkgconf python3"
+makedepends="fontconfig-devel libxcb-devel xcb-util-image-devel xcb-util-keysyms-devel
+ xcb-util-wm-devel libxkbcommon-devel libX11-devel wayland-devel openssl-devel zlib-devel
+ harfbuzz-devel freetype-devel libpng-devel"
+depends="libxkbcommon-x11 hicolor-icon-theme"
+short_desc="GPU-accelerated cross-platform terminal emulator and multiplexer"
+maintainer="Artur Sinila <freesoftware@logarithmus.dev>"
+license="MIT"
+homepage="https://github.com/wez/wezterm"
+changelog="https://raw.githubusercontent.com/wez/wezterm/main/docs/changelog.md"
+distfiles="${homepage}/archive/refs/tags/${_version}.tar.gz"
+checksum=199b884b2fbcc3d9e8aa6cd3bd04a4bc01fccecc093b1db3807d98f580a9e4ec
+
+# Use system harfbuzz, freetype, libz & libpng instead of the vendored ones
+export WEZTERM_SYSDEPS=1
+
+pre_build() {
+ # Fixed in rust 1.49, but we still use 1.48
+ # Can be dropped after merging https://github.com/void-linux/void-packages/pull/30259
+ cargo update -p spinning_top --precise 0.2.2
+ # Before 1.1.3, libz-sys used vendored zlib for musl targets by default.
+ # `wezterm` still uses libz-sys-1.1.2. https://github.com/wez/wezterm/pull/754 fixed that,
+ # but new wezterm release hasn't been made yet
+ # TLDR; can be dropped after new `wezterm` is released
+ cargo update -p libz-sys
+}
+
+do_install() {
+ vbin target/${RUST_TARGET}/release/wezterm
+ vbin target/${RUST_TARGET}/release/wezterm-gui
+ vbin target/${RUST_TARGET}/release/wezterm-mux-server
+ vmkdir usr/share/wezterm/colors
+ vmkdir usr/share/applications/
+ vmkdir usr/share/icons/hicolor/128x128/apps/
+ vmkdir usr/share/icons/hicolor/scalable/apps/
+ install -m 644 assets/colors/* ${DESTDIR}/usr/share/wezterm/colors/
+ vinstall assets/wezterm.desktop 644 usr/share/applications/
+ vinstall assets/icon/terminal.png 644 usr/share/icons/hicolor/128x128/apps/ wezterm.png
+ vinstall assets/icon/wezterm-icon.svg 644 usr/share/icons/hicolor/scalable/apps/ wezterm.svg
+ vlicense LICENSE.md
+}
next prev parent reply other threads:[~2021-05-02 23:40 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-05-01 22:39 [PR PATCH] " Logarithmus
2021-05-01 23:32 ` [PR PATCH] [Updated] " Logarithmus
2021-05-02 14:20 ` ericonr
2021-05-02 14:23 ` [PR REVIEW] " ericonr
2021-05-02 21:51 ` kwshi
2021-05-02 23:14 ` Logarithmus
2021-05-02 23:19 ` Logarithmus
2021-05-02 23:19 ` Logarithmus
2021-05-02 23:20 ` Logarithmus
2021-05-02 23:21 ` Logarithmus
2021-05-02 23:40 ` Logarithmus [this message]
2021-05-02 23:52 ` ericonr
2021-05-06 8:23 ` [PR REVIEW] " Logarithmus
2022-05-19 2:16 ` github-actions
2022-06-03 2:11 ` [PR PATCH] [Closed]: " github-actions
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20210502234010.2jvbKERxvKGm-E51A6UU1lF1quaUnLobTX91gJT-pdQ@z \
--to=logarithmus@users.noreply.github.com \
--cc=ml@inbox.vuxu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).