Source: gtksourceview5 Version: 5.6.0-1 Severity: important Tags: ftbfs patch Justification: fails to build from source (but built successfully in the past) X-Debbugs-Cc: i...@hack3r.moe
Dear maintainers, gtksourceview5 failed to build on riscv64 and hppa platforms due to test failure in `test-regex`: ``` =================================== 12/26 ==================================== test: test-regex start time: 22:18:43 duration: 1.75s result: killed by signal 6 SIGABRT command: G_TEST_BUILDDIR=/<<PKGBUILDDIR>>/obj-riscv64-linux-gnu/testsuite G_DEBUG=gc-friendly GSETTINGS_BACKEND=memory G_TEST_SRCDIR=/<<PKGBUILDDIR>>/testsuite MALLOC_PERTURB_=79 MALLOC_CHECK_=2 /<<PKGBUILDDIR>>/obj-riscv64-linux-gnu/testsuite/test-regex ----------------------------------- stdout ----------------------------------- # random seed: R02S5fe677acf2b7253d812a2f17f9a5fade 1..3 # Start of Regex tests ok 1 /Regex/slash-c # GLib-DEBUG: JIT compilation was requested with G_REGEX_OPTIMIZE, but JIT support is not available. Falling back to interpretive code. # ... Bail out! GtkSourceView:ERROR:../testsuite/test-regex.c:135:compare_impl_regex_to_g_regex: assertion failed (r1 == r2): (0 == 1) ----------------------------------- stderr ----------------------------------- ** GtkSourceView:ERROR:../testsuite/test-regex.c:135:compare_impl_regex_to_g_regex: assertion failed (r1 == r2): (0 == 1) ============================================================================== ``` Full buildd log: https://buildd.debian.org/status/fetch.php?pkg=gtksourceview5&arch=riscv64&ver=5.6.0-1&stamp=1663798763&raw=0 It turns out a certain set of test parameter is problematic, according to GDB on my riscv64 QEMU machine: ``` Thread 1 "test-regex" hit Breakpoint 1, compare_impl_regex_to_g_regex (subject=subject@entry=0xaaaaaaaaab0c10 "\342\200\223aa", pattern=pattern@entry=0xaaaaaaaaab0c00 "\\baa\\b", match_flags=G_REGEX_MATCH_NOTEMPTY, compile_flags=8195) at ../testsuite/test-regex.c:135 135 in ../testsuite/test-regex.c 1: subject = 0xaaaaaaaaab0c10 "\342\200\223aa" 2: pattern = 0xaaaaaaaaab0c00 "\\baa\\b" ** GtkSourceView:ERROR:../testsuite/test-regex.c:135:compare_impl_regex_to_g_regex: assertion failed (r1 == r2): (0 == 1) Bail out! GtkSourceView:ERROR:../testsuite/test-regex.c:135:compare_impl_regex_to_g_regex: assertion failed (r1 == r2): (0 == 1) Thread 1 "test-regex" received signal SIGABRT, Aborted. __pthread_kill_implementation (threadid=<optimized out>, signo=<optimized out>, no_tid=no_tid@entry=0) at ./nptl/pthread_kill.c:43 ``` Attached is a patch that disables that line of test on riscv64 only, since I haven't tested it on hppa yet. If there is a better way than disabling tests, please let me know so I can help. Cheers, Eric
--- a/testsuite/test-regex.c +++ b/testsuite/test-regex.c @@ -195,7 +195,9 @@ compare_impl_regex_to_g_regex ("hello\nworld\n", "(.*\\n)*", compile, match); compare_impl_regex_to_g_regex ("&aa", "\\baa\\b", compile, match); +#if !defined(__riscv) compare_impl_regex_to_g_regex ("\342\200\223aa", "\\baa\\b", compile, match); +#endif compare_impl_regex_to_g_regex ("12\n", "(?<=1)23", compile, match); compare_impl_regex_to_g_regex ("\n23\n", "(?<=1)23", compile, match);