Hi Team,

we are working on one of Debian issue regarding big-endian architectures.
Issue link:https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1038447

After a lot of debugging, by upgrading librsvg and its dependency packages one 
after another like libcairo, libpixman and libpango, we found out that while 
upgrading libpixman (libpixman-1-0:s390x) package from version 0.40.0-1 to 
version 0.42.2-1, the test suites failed in the librsvg.



I built these packages ( i.e. cairo, pixman & pango) manually from their 
respective sources by resolving all the version dependencies and ran the 
librsvg tests to make sure that the test suites failed while upgrading pixman 
package from 0.40.0-1 to version 0.42.2-1..



By doing git-bisect on pixman package commits, I figured out the below 
mentioned commit which has changes w.r.t. big-endian architectures, introduced 
the regression. when I reverted this commit in the mainline repo of pixman, 
librsvg tests are passing.



commit b4a105d77232a87304b7b621e2f99e699a8eebd3

Author: Jocelyn Falempe <[email protected]<mailto:[email protected]>>

Date:   Wed Jun 29 10:55:43 2022 +0200

    Fix inverted colors on big endian system

    bits_image_fetch_separable_convolution_affine() didn't take care

    of big endian system

    Signed-off-by: Jocelyn Falempe 
<[email protected]<mailto:[email protected]>>



And I noticed that there is one open issue in pixman regarding to this commit 
changes which is affecting the big-endian systems. Please confirm whether this 
patch can/should be reverted upstream?

https://gitlab.freedesktop.org/pixman/pixman/-/issues/78



I have raised a request to allow the forking of pixman repo.. Once the request 
is granted, I will be able to push the changes.. I have commented in the above 
issue link with all the details..



The Ask is to revert the attached patch so that we will be able to fix 
“librsvg: FTBFS on big-endian architectures: multiple test regressions since 
September 2022” bug…



Thanks,

Gayathri.
Subject: libpixman: Fix for testcase failures on big-endian architecures
diff --git a/pixman/pixman-fast-path.c b/pixman/pixman-fast-path.c
index e62a8ac..d510cac 100644
--- a/pixman/pixman-fast-path.c
+++ b/pixman/pixman-fast-path.c
@@ -2836,11 +2836,7 @@ bits_image_fetch_separable_convolution_affine 
(pixman_image_t * image,
        sgtot = CLIP (sgtot, 0, 0xff);
        sbtot = CLIP (sbtot, 0, 0xff);

-#ifdef WORDS_BIGENDIAN
-       buffer[k] = (satot << 0) | (srtot << 8) | (sgtot << 16) | (sbtot << 24);
-#else
        buffer[k] = (satot << 24) | (srtot << 16) | (sgtot << 8) | (sbtot << 0);
-#endif

     next:
        vx += ux;


Reply via email to