From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.org/gmane.linux.lib.musl.general/3177 Path: news.gmane.org!not-for-mail From: Timerlan Moldobaev Newsgroups: gmane.linux.lib.musl.general Subject: Re: cluts test suite with musl Date: Wed, 24 Apr 2013 15:26:57 +0300 Message-ID: References: <20130423134038.GX20323@brightrain.aerifal.cx> <20130423153127.GA20323@brightrain.aerifal.cx> <20130423154705.GB20323@brightrain.aerifal.cx> Reply-To: musl@lists.openwall.com NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: multipart/alternative; boundary=047d7b86db60fb858204db1a6ada X-Trace: ger.gmane.org 1366806426 4026 80.91.229.3 (24 Apr 2013 12:27:06 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 24 Apr 2013 12:27:06 +0000 (UTC) To: musl@lists.openwall.com Original-X-From: musl-return-3181-gllmg-musl=m.gmane.org@lists.openwall.com Wed Apr 24 14:27:10 2013 Return-path: Envelope-to: gllmg-musl@plane.gmane.org Original-Received: from mother.openwall.net ([195.42.179.200]) by plane.gmane.org with smtp (Exim 4.69) (envelope-from ) id 1UUyn0-0004Rk-73 for gllmg-musl@plane.gmane.org; Wed, 24 Apr 2013 14:27:10 +0200 Original-Received: (qmail 30267 invoked by uid 550); 24 Apr 2013 12:27:08 -0000 Mailing-List: contact musl-help@lists.openwall.com; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: Original-Received: (qmail 30259 invoked from network); 24 Apr 2013 12:27:08 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:content-type; bh=cde+zKmlAs5CgLxP6sYdm8+gzK2M26aVPLo8EzhgfRc=; b=RrZKP90cSTarnldc2zoLfJHCOK5xDfdueLRFNOSbJpUdYFx+FwQ3iyXO1C+uaDKxZZ 9vUUkYyvo2kSopXpqaLOujs2YOhOLgSD/Z2gAgMM93igcmJVhf7cQwy9bDbvPT3t7Fd7 ZZ3UUKV35PKilbv8NumYLZvOZJ/G/IqEe4b3ACf6rHBZ/AYJYSNoKDtFH7E4tBHS8wq/ qbs1112Hk6bSK8FekHwX1bwa3cf5pWT7W4xU55XpDpItFFmUF5pRJVSx0MmWiJx/A4HB eZ1kGW+Hpnz1LJ0+qRLosHhSsb3mo77IdWx0WmVzFtTiGK0tfrOCzxd9dSQr3FDpOibW 7HhQ== X-Received: by 10.194.63.109 with SMTP id f13mr68119992wjs.11.1366806417341; Wed, 24 Apr 2013 05:26:57 -0700 (PDT) In-Reply-To: <20130423154705.GB20323@brightrain.aerifal.cx> Xref: news.gmane.org gmane.linux.lib.musl.general:3177 Archived-At: --047d7b86db60fb858204db1a6ada Content-Type: text/plain; charset=ISO-8859-1 Thanks ! I applied the patch. Still have some tests failing. For instance tests/buf fails with the following error message: iconv(&<"abcd">, &<4>, &s, &<3>) caused a SIGSEGV! I am not sure but it seems that iconv() that is called from wrap_iconv() should return an error return value and set an errno value. At least to my understanding that the way the test is written. For musl implementation of iconv() returns 0 and sets no errno. While in the case of standard Linux implementation, errno = E2BIG and -1 returned ( error return value) . For the case buf linked dynamically against the standard libc.so library: ldd tests/buf libpthread.so.0 => /lib64/libpthread.so.0 (0x00000030d1000000) librt.so.1 => /lib64/librt.so.1 (0x00000030d4400000) libm.so.6 => /lib64/libm.so.6 (0x00000030d0800000) libc.so.6 => /lib64/libc.so.6 (0x00000030d0400000) /lib64/ld-linux-x86-64.so.2 (0x00000030cf400000) > uname -a Linux lnxbdc96 2.6.18-164.11.1.el5 #1 SMP Wed Jan 6 13:26:04 EST 2010 x86_64 x86_64 x86_64 GNU/Linux Can you please look into this ? Thanks. On Tue, Apr 23, 2013 at 6:47 PM, Rich Felker wrote: > On Tue, Apr 23, 2013 at 11:31:27AM -0400, Rich Felker wrote: > > On Tue, Apr 23, 2013 at 06:17:15PM +0300, Timerlan Moldobaev wrote: > > > Can you please specify what tests within cluts should work > correctly ? > > > There are chances that in my specific environment some musl issues > might > > > pop up even when running cluts partly. > > > I can assist in debugging such issues (as it was for testsuite case). > > > > Yes, I'm actually working on a patch right now that disables the > > incorrect tests and fixes up some other issues. > > Here's the patch. I've just disabled the EINTR test module entirely > since it's full of wrong code including broken attempts at > synchronization based on a volatile variable, and attempts to unlock a > lock that's already unlocked. > > The other main issue was invalid numeric tests. > > Note that the setuid race test will not work without root, and I don't > think it's reliable anyway. There's an alternate test for this issue > on the glibc bug tracker: > > http://sourceware.org/bugzilla/show_bug.cgi?id=13347 > > Rich > --047d7b86db60fb858204db1a6ada Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable
Thanks !

I applied the patch. Still hav= e some tests failing.

For instance tests/buf fails= with the following error message:

iconv(&<= "abcd">, &<4>, &s, &<3>) caused a SIGS= EGV!

I am not sure but =A0it seems that iconv() =A0that is c= alled from wrap_iconv() should return =A0an error return value and set an e= rrno value.=A0
At least to my understanding =A0that the way the t= est is written.=A0
For musl=A0implementation=A0of iconv() =A0returns 0 and sets no errno.= =A0

While in the case of standard Linux implementa= tion, errno =3D=A0E2BIG and -1 returned ( error return value) .
<= br>
For the case buf linked dynamically against the standard libc.so= library:

=A0ldd tests/buf
= =A0 =A0 =A0 =A0 libpthread.so.0 =3D> /lib64/libpthread.so.0 (0x00000030d= 1000000)
=A0 =A0 =A0 =A0 librt.so.1 =3D> /lib64/librt.so.1 (0x00000030d44000= 00)
=A0 =A0 =A0 =A0 libm.so.6 =3D> /lib64/libm.so.6 (0x0000003= 0d0800000)
=A0 =A0 =A0 =A0 libc.so.6 =3D> /lib64/libc.so.6 (0x= 00000030d0400000)
=A0 =A0 =A0 =A0 /lib64/ld-linux-x86-64.so.2 (0x00000030cf400000)

> uname -a
Linux lnxbdc96 2.6.18-164= .11.1.el5 #1 SMP Wed Jan 6 13:26:04 EST 2010 x86_64 x86_64 x86_64 GNU/Linux=

Can you please look into this ?=A0

Thanks.



On Tue, Ap= r 23, 2013 at 6:47 PM, Rich Felker <dalias@aerifal.cx> wrote= :
On T= ue, Apr 23, 2013 at 11:31:27AM -0400, Rich Felker wrote:
> On Tue, Apr 23, 2013 at 06:17:15PM +0300, Timerlan Moldobaev wrote: > > Can you please specify what =A0tests within cluts =A0should =A0wo= rk correctly ?
> > There are chances that in my specific environment some musl issue= s might
> > pop up even when running cluts partly.
> > I can assist in debugging such issues (as it was for testsuite ca= se).
>
> Yes, I'm actually working on a patch right now that disables the > incorrect tests and fixes up some other issues.

Here's the patch. I've just disabled the EINTR test mod= ule entirely
since it's full of wrong code including broken attempts at
synchronization based on a volatile variable, and attempts to unlock a
lock that's already unlocked.

The other main issue was invalid numeric tests.

Note that the setuid race test will not work without root, and I don't<= br> think it's reliable anyway. There's an alternate test for this issu= e
on the glibc bug tracker:

http://sourceware.org/bugzilla/show_bug.cgi?id=3D13347

Rich

--047d7b86db60fb858204db1a6ada--