Re: [PATCH v2 glibc 0/2] SIGSTOP/SIGCONT duplicating portions of files.

Michael Kelly <[email protected]> Fri, 26 Jun 2026 20:11:02 +0100
Newsgroups gmane.os.hurd.bugs
Message-ID <[email protected]>
I was thinking about having another bash at the haskell packages build 
corruption problem. There hadn't been many haskell builds attempted when 
I looked a few weeks ago.

Is it expected that the corruption of a few months ago would still occur ?

Mike.

On 13/04/2026 01:54, Samuel Thibault wrote:
> Samuel Thibault, le lun. 13 avril 2026 01:41:16 +0200, a ecrit:
>> It seems to be helping a bit (I have seen a bit less corruption
>> apparently), but it seems we are still facing corruptions, notably when
>> building these packages:
>>
>> haskell-dbus
>> haskell-graphviz
>> haskell-texmath
>> haskell-trifecta
>> haskell-typst
>>
>> we end up with various symbol table issues etc. The attached "checkone"
>> script does some tests (give it the libghc-foo-dev.deb file name as
>> parameter) that end up failing on these packages results on the buildds.
> But I can't reproduce that on my on box... (didn't use eatmydata,
> though)
>
> Samuel
>
>
>> Samuel Thibault, le jeu. 02 avril 2026 01:05:57 +0200, a ecrit:
>>> Hello,
>>>
>>> Thanks for this! I have pushed it to upstream glibc.
>>>
>>> Samuel
>>>
>>> Mike Kelly, le mer. 01 avril 2026 20:49:31 +0100, a ecrit:
>>>> This is my proposal to fix the SIGSTOP/SIGCONT issue where RPC calls
>>>> were being repeated even though the server will complete the request
>>>> as discussed in the thread:
>>>>
>>>> https://lists.gnu.org/archive/html/bug-hurd/2026-03/msg00243.html
>>>>
>>>> The very simple test case was to run tar whilst SIGSTOP/SIGCONT
>>>> multiple times from the shell:
>>>>
>>>> # /usr/bin/tar xf data.tar.xz
>>>>
>>>> Repeated interrupted extractions of the same archive result in file
>>>> differences in the output as some segments are written multiple times.
>>>>
>>>> There are 2 patches that must be applied in the sequence specified:
>>>>
>>>> 1) Alterations to MSG_EXAMINE to provide the signal thread with access
>>>> to additional RPC input parameters. There was a case of 'return -1' in
>>>> the i386 version which made no sense in an inline macro and I'm
>>>> guessing was a historic leftover. I have altered it to match the
>>>> x86_64 version.
>>>>
>>>> 2) Patch 2 is the revised architecture independent fix for
>>>> SIGSTOP/SIGCONT.
>>>>
>>>> I can confirm that this patch fixes this testcase on both hurd-i386
>>>> and hurd-amd64. I've run msgport utility and it runs with output
>>>> generated from report-wait so seems OK. Hopefully there are no
>>>> unforeseen negative consequences.
>>>>
>>>> Cheers,
>>>>
>>>> Mike.
>> #!/bin/bash
>> TMPDIR=/tmp/$$
>>
>> 	case $1 in
>> 		*libghc*-dev_*)
>> 			;;
>> 		*)
>> 			exit 0
>> 	esac
>> 	echo checking $1
>> 	dpkg-deb -x $1 $TMPDIR
>> 	cd $TMPDIR || exit 0
>> 	for i in $(find usr/lib/haskell-packages/ghc/lib -name \*.so) ; do
>> 	       	if readelf -r $i | grep -q R_X86_64_NONE \
>> 		    || LANG=C readelf -s $i 2>&1 | grep -q "readelf: Warning: local symbol" \
>> 		    || ld $i -o $TMPDIR/test.so 2>&1 | grep -q "corrupt symbol table" \
>> 				   ; then
>> 			echo "$1 bogus"
>> 		       	break
>> 		fi
>>         	done
>> 	rm -fr $TMPDIR
>