Github messages for voidlinux
 help / color / mirror / Atom feed
From: ericonr <ericonr@users.noreply.github.com>
To: ml@inbox.vuxu.org
Subject: Re: [PR PATCH] [Updated] pixman: update to 0.40.0.
Date: Wed, 14 Oct 2020 22:41:30 +0200	[thread overview]
Message-ID: <20201014204130.jTmgyZ0KFnSYomLQ-diUAki6lDXdQITmEW7L4C7FrO4@z> (raw)
In-Reply-To: <gh-mailinglist-notifications-41a7ca26-5023-4802-975b-f1789d68868e-void-packages-25301@inbox.vuxu.org>

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

There is an updated pull request by ericonr against master on the void-packages repository

https://github.com/ericonr/void-packages pixman
https://github.com/void-linux/void-packages/pull/25301

pixman: update to 0.40.0.
Update links, simplify musl patch.

---

I'm not sure I understand the musl patch. The main thing with musl is that thread stack size is small, so putting the array in thread storage seems worse than leaving it in the main stack.

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

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

From 90e031b00067fdd13bee6023fcc4a9bbc57027f9 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=C3=89rico=20Rolim?= <erico.erc@gmail.com>
Date: Fri, 2 Oct 2020 20:07:03 -0300
Subject: [PATCH] pixman: update to 0.40.0, adopt.

- Update links, use linker flag for stack size instead of patch.
- Move to meson build style.
---
 .../musl-static__thread-scanline_buffer.patch | 35 ---------------
 srcpkgs/pixman/template                       | 43 +++++++++++++------
 2 files changed, 29 insertions(+), 49 deletions(-)
 delete mode 100644 srcpkgs/pixman/patches/musl-static__thread-scanline_buffer.patch

diff --git a/srcpkgs/pixman/patches/musl-static__thread-scanline_buffer.patch b/srcpkgs/pixman/patches/musl-static__thread-scanline_buffer.patch
deleted file mode 100644
index 0b9339dbea0..00000000000
--- a/srcpkgs/pixman/patches/musl-static__thread-scanline_buffer.patch
+++ /dev/null
@@ -1,35 +0,0 @@
-Reduce the stack footprint of pixman's function
-general_composite_rect() which allocates a large buffer
-`stack_scanline_buffer`. Make it `static __thread` instead.
-
---- pixman/pixman-general.c	2015-12-27 21:37:37.000000000 +0100
-+++ pixman/pixman-general.c	2016-05-05 12:24:47.346661080 +0200
-@@ -128,8 +128,8 @@
-                          pixman_composite_info_t *info)
- {
-     PIXMAN_COMPOSITE_ARGS (info);
--    uint8_t stack_scanline_buffer[3 * SCANLINE_BUFFER_LENGTH];
--    uint8_t *scanline_buffer = (uint8_t *) stack_scanline_buffer;
-+    static __thread uint8_t static_scanline_buffer[3 * SCANLINE_BUFFER_LENGTH];
-+    uint8_t *scanline_buffer = (uint8_t *) static_scanline_buffer;
-     uint8_t *src_buffer, *mask_buffer, *dest_buffer;
-     pixman_iter_t src_iter, mask_iter, dest_iter;
-     pixman_combine_32_func_t compose;
-@@ -158,7 +158,7 @@
-     if (width <= 0 || _pixman_multiply_overflows_int (width, Bpp * 3))
- 	return;
- 
--    if (width * Bpp * 3 > sizeof (stack_scanline_buffer) - 15 * 3)
-+    if (width * Bpp * 3 > sizeof (static_scanline_buffer) - 15 * 3)
-     {
- 	scanline_buffer = pixman_malloc_ab_plus_c (width, Bpp * 3, 15 * 3);
- 
-@@ -232,7 +232,7 @@
-     if (dest_iter.fini)
- 	dest_iter.fini (&dest_iter);
-     
--    if (scanline_buffer != (uint8_t *) stack_scanline_buffer)
-+    if (scanline_buffer != (uint8_t *) static_scanline_buffer)
- 	free (scanline_buffer);
- }
- 
diff --git a/srcpkgs/pixman/template b/srcpkgs/pixman/template
index eb4a6da3b03..e20583149c1 100644
--- a/srcpkgs/pixman/template
+++ b/srcpkgs/pixman/template
@@ -1,25 +1,41 @@
 # Template file for 'pixman'
 pkgname=pixman
-version=0.38.4
+version=0.40.0
 revision=1
-build_style=gnu-configure
-configure_args="--disable-gtk" # do not require gtk+!
+build_style=meson
+# gtk is only necessary for demos, disabled to avoid dependency loop
+# OpenMP isn't recommended by upstream:
+#   https://gitlab.freedesktop.org/pixman/pixman/-/blob/9b49f4e08751885289333fed652bf5e0f45976b4/pixman/dither/make-blue-noise.c#L8
+configure_args="--auto-features=disabled -Dgtk=disabled -Dopenmp=disabled
+ -Dgnu-inline-asm=enabled"
 hostmakedepends="pkg-config perl"
+checkdepends="libpng-devel"
 short_desc="Library of low-level pixel manipulation routines"
-maintainer="Orphaned <orphan@voidlinux.org>"
+maintainer="Érico Nogueira <ericonr@disroot.org>"
 license="MIT"
-homepage="https://wiki.freedesktop.org/xorg/"
-distfiles="${XORG_SITE}/lib/${pkgname}-${version}.tar.bz2"
-checksum=84abb7fa2541af24d9c3b34bf75d6ac60cc94ac4410061bbb295b66a29221550
+homepage="http://pixman.org/"
+distfiles="https://www.cairographics.org/releases/${pkgname}-${version}.tar.gz"
+checksum=6d200dec3740d9ec4ec8d1180e25779c00bc749f94278c8b9021f5534db223fc
 
-pre_configure() {
-	case "$XBPS_TARGET_MACHINE" in
-		arm*) configure_args+=" --disable-arm-iwmmxt --disable-arm-iwmmxt2";;
-	esac
-}
+# set stacksize for musl: https://gitlab.gnome.org/GNOME/librsvg/-/issues/595
+LDFLAGS="-Wl,-z,stack-size=2097152"
+
+if [ "$XBPS_CHECK_PKGS" ]; then
+	configure_args+=" -Dlibpng=enabled"
+fi
+
+# enable vectorized implementations per arch
+case "$XBPS_TARGET_MACHINE" in
+	x86_64*) configure_args+=" -Dsse2=enabled -Dssse3=enabled";;
+	i686*) configure_args+=" -Dmmx=enabled -Dsse2=enabled -Dssse3=enabled";;
+	ppc64*) configure_args+=" -Dvmx=enabled";;
+	arm*) configure_args+=" -Darm-simd=enabled";;
+	aarch64*) configure_args+=" -Dneon=enabled";;
+	mips*) configure_args+=" -Dmips-dspr2=enabled";;
+esac
 
 post_install() {
-	vlicense COPYING
+	vlicense COPYING LICENSE
 }
 
 pixman-devel_package() {
@@ -28,7 +44,6 @@ pixman-devel_package() {
 	pkg_install() {
 		vmove usr/include
 		vmove usr/lib/pkgconfig
-		vmove "usr/lib/*.a"
 		vmove "usr/lib/*.so"
 	}
 }

  parent reply	other threads:[~2020-10-14 20:41 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-10-02 23:09 [PR PATCH] " ericonr
2020-10-02 23:14 ` [PR PATCH] [Updated] " ericonr
2020-10-02 23:41 ` ericonr
2020-10-09  5:00 ` [PR PATCH] [Updated] " ericonr
2020-10-09  5:01 ` ericonr
2020-10-13 22:00 ` ericonr
2020-10-13 22:20 ` ifreund
2020-10-13 22:20 ` ifreund
2020-10-13 22:22 ` ericonr
2020-10-13 22:42 ` ericonr
2020-10-14 20:23 ` [PR PATCH] [Updated] " ericonr
2020-10-14 20:41 ` ericonr [this message]
2020-10-14 21:27 ` ericonr
2020-10-14 21:43 ` ericonr
2020-10-14 21:47 ` ericonr
2020-10-14 22:03 ` ericonr
2020-10-20  5:50 ` ericonr
2020-11-06 13:52 ` ericonr
2020-11-06 14:00 ` [PR PATCH] [Merged]: " ericonr

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=20201014204130.jTmgyZ0KFnSYomLQ-diUAki6lDXdQITmEW7L4C7FrO4@z \
    --to=ericonr@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).