Github messages for voidlinux
 help / color / mirror / Atom feed
* [PR PATCH] ripgrep: use system-provided libpcre2
@ 2020-09-28 22:53 Logarithmus
  2020-09-28 22:54 ` [PR PATCH] [Updated] " Logarithmus
                   ` (6 more replies)
  0 siblings, 7 replies; 8+ messages in thread
From: Logarithmus @ 2020-09-28 22:53 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 559 bytes --]

There is a new pull request by Logarithmus against master on the void-packages repository

https://github.com/Logarithmus/void-packages ripgrep
https://github.com/void-linux/void-packages/pull/25179

ripgrep: use system-provided libpcre2
By default, for musl targets `libpcre2` is linked statically. This patch fixes this and reduces binary size by ~400 KiB for `x86_64-musl` target.
More info here: https://github.com/burntsushi/rust-pcre2/tree/HEAD/pcre2-sys#notes

A patch file from https://github.com/void-linux/void-packages/pull/25179.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-ripgrep-25179.patch --]
[-- Type: text/x-diff, Size: 1099 bytes --]

From 56c110dcb133a465ec572b4476464ecf2daa52fd Mon Sep 17 00:00:00 2001
From: Artur Sinila <personal@logarithmus.dev>
Date: Tue, 29 Sep 2020 01:48:27 +0300
Subject: [PATCH] ripgrep: use system-provided libpcre2

---
 srcpkgs/ripgrep/template | 9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

diff --git a/srcpkgs/ripgrep/template b/srcpkgs/ripgrep/template
index 339d2de3a39..158619189cc 100644
--- a/srcpkgs/ripgrep/template
+++ b/srcpkgs/ripgrep/template
@@ -1,7 +1,7 @@
 # Template file for 'ripgrep'
 pkgname=ripgrep
 version=12.1.1
-revision=1
+revision=2
 build_style=cargo
 configure_args="--features=pcre2"
 hostmakedepends="ruby-asciidoctor pkg-config"
@@ -13,6 +13,13 @@ homepage="https://github.com/BurntSushi/ripgrep/"
 distfiles="https://github.com/BurntSushi/${pkgname}/archive/${version}.tar.gz"
 checksum=2513338d61a5c12c8fea18a0387b3e0651079ef9b31f306050b1f0aaa926271e
 
+# Dynamic linking to libpcre2 even on musl
+export PCRE2_SYS_STATIC=0
+
+pre_build() {
+	echo "PCRE2_SYS_STATIC=$PCRE2_SYS_STATIC"
+}
+
 post_install() {
 	vlicense LICENSE-MIT
 	vlicense UNLICENSE

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2020-09-29  0:13 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-09-28 22:53 [PR PATCH] ripgrep: use system-provided libpcre2 Logarithmus
2020-09-28 22:54 ` [PR PATCH] [Updated] " Logarithmus
2020-09-28 22:56 ` Logarithmus
2020-09-28 23:02 ` [PR REVIEW] " ericonr
2020-09-28 23:47 ` Logarithmus
2020-09-28 23:49 ` Logarithmus
2020-09-29  0:13 ` [PR PATCH] [Closed]: " Logarithmus
2020-09-29  0:13 ` Logarithmus

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).