From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.org/gmane.linux.lib.musl.general/12499 Path: news.gmane.org!.POSTED!not-for-mail From: =?UTF-8?B?TWF0w7rFoSBPbGVrxaHDoWs=?= Newsgroups: gmane.linux.lib.musl.general Subject: Re: shmctl not found when compiling compiler-rt Date: Tue, 13 Feb 2018 15:51:38 +0100 Message-ID: References: <220501518528874@web47o.yandex.ru> <20180213141524.GZ4418@port70.net> <203971518532434@web31o.yandex.ru> Reply-To: musl@lists.openwall.com NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="001a113d723ac2f51f05651921af" X-Trace: blaine.gmane.org 1518533402 12986 195.159.176.226 (13 Feb 2018 14:50:02 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Tue, 13 Feb 2018 14:50:02 +0000 (UTC) To: musl@lists.openwall.com Original-X-From: musl-return-12515-gllmg-musl=m.gmane.org@lists.openwall.com Tue Feb 13 15:49:57 2018 Return-path: Envelope-to: gllmg-musl@m.gmane.org Original-Received: from mother.openwall.net ([195.42.179.200]) by blaine.gmane.org with smtp (Exim 4.84_2) (envelope-from ) id 1elbtz-0002Si-GJ for gllmg-musl@m.gmane.org; Tue, 13 Feb 2018 15:49:47 +0100 Original-Received: (qmail 1580 invoked by uid 550); 13 Feb 2018 14:51:51 -0000 Mailing-List: contact musl-help@lists.openwall.com; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-ID: Original-Received: (qmail 1553 invoked from network); 13 Feb 2018 14:51:50 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to; bh=LXV7h0hDg1eIcBT9UDFU7j/xIXlmM7oqNKICGUzfxMo=; b=rQ/mFFo3GgjSfinWsp9otSUqGgSsSaKKHXkaBme/c+CelatAcR8VQtLUBesrmX07KQ hWJHpZlLNVx1cvMg6oMFnS6fh7w3sXdomQB0R6KLx3mkA/FJl4OK/iP4fs5lQiJVomWJ xctVn7fg2Tyh0XPc0bKTp2Vd2nzEcxUJo9i6vUzJw9fwj57PCACcYro79L0w9lHHNciC mjyFAAiURiR2yzmf+TgX8tcHzL3GjKVUaYO7LUgOT0q8J45djBRvuukFhV5JNQ/VyjX7 DFcTZ2WXM4ZbgYtQjybylyQacrIzQrUMCXJ7cS6Hf/3n5ro8qUnx9WmHav3+yVHQoZZN tffQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to; bh=LXV7h0hDg1eIcBT9UDFU7j/xIXlmM7oqNKICGUzfxMo=; b=E5ZNWnHA9b4lp5jKiYX/SpxrJpGh8mB49Fdm4DM+TlshfzVH/z+q79t3whUi9qswIi Z8BeAWycIhK0cSNo5jqmJyC2wH551o7aY5wDH0AKnPHgxP30hPx1OgP8riN/9+t9PreR Wz28bB1OhfIYWnh92Yirm0E8W2Zd/XjT0CE+LZeGdoP5HcpQ3VQ9t5770C2QVzVfCpnT lyHf+5bREzT/Mb6EENS9E70km76eHCB/r1qxtlRruORN//peAIgLbceq7o28XJbptwBV 4RVsqGDIfZDvN7hlIQcfGrYWrWioVC/ULsZOTIFZsE/a9H1cdk/dQeOFbbe4JDx0Rjx6 cIxA== X-Gm-Message-State: APf1xPDdF96CjxWvW9B6c7TWX1pdVoPcQoZmg4S0Fm92dVn0It8VzqdV R+0l/sIsWHGR/B/6rX6+SFRIdoBTXvxLKWpDCTs= X-Google-Smtp-Source: AH8x2254DNcyPTASxhtG2SIDTsgT9nIzKp+BJsUOT0UcFeryrH7GvM2l0MrghZ5o1VcFgljhlaSXmxtNpPhm6Q9mTt0= X-Received: by 10.202.68.7 with SMTP id r7mr977531oia.231.1518533498564; Tue, 13 Feb 2018 06:51:38 -0800 (PST) In-Reply-To: Xref: news.gmane.org gmane.linux.lib.musl.general:12499 Archived-At: --001a113d723ac2f51f05651921af Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Oh, now I read it again and I realize you try to compile compiler-rt and not musl. I'm so sorry for misunderstanding. I had a rough day. PS: Sorry for spam 2018-02-13 15:36 GMT+01:00 Mat=C3=BA=C5=A1 Olek=C5=A1=C3=A1k : > I assumed it's the same problem a had last week on pure llvm environment > and I discovered bug in compiler-rt detection which solves my patch. > > 2018-02-13 15:33 GMT+01:00 Dmitry Golovin : > >> Thank you for the patch, but I don't think it is relevant to this proble= m. >> >> If you take a look at my build script, you'll see that I don't need it: >> https://github.com/tpimh/ngtc/blob/alpine/build.sh#L73 >> >> Regards, >> Dmitry >> >> 13.02.2018, 16:31, "Mat=C3=BA=C5=A1 Olek=C5=A1=C3=A1k" : >> > Try this patch to correctly link compiler-rt. >> > >> > 2018-02-13 15:15 GMT+01:00 Szabolcs Nagy : >> >> * Dmitry Golovin [2018-02-13 15:34:34 +0200]: >> >>> I'm trying to compile compiler-rt with musl and it used to be fine, >> but I can't succeed with recent versions of compiler-rt. >> >>> >> >>> The compilation fails because of the lack of real_shmctl while musl >> clearly has shmctl: http://git.musl-libc.org/cgit/ >> musl/tree/src/ipc/shmctl.c >> >>> >> >>> Here is the complete output: >> >>> >> >>> llvm/projects/compiler-rt/lib/msan/msan_interceptors.cc:1446:15: >> error: no member named 'real_shmctl' in namespace '__interception'; did = you >> mean 'real_ioctl'? >> >>> int res =3D REAL(shmctl)(shmid, shmctl_ipc_stat, &ds); >> >>> ^~~~~~~~~~~~ >> >> >> >> there should be a >> >> >> >> DECLARE_REAL(int, shmctl, int shmid, int cmd, void *buf) >> >> >> >> in that file which defines __interception::real_shmctl. >> >> >> >>> To compile without glibc on linux using this patch: >> >>> https://github.com/tpimh/ngtc/blob/alpine/patch/compiler-rt- >> 01-sanitizer-nongnu.patch >> >>> >> >>> Regards, >> >>> Dmitry >> > > --001a113d723ac2f51f05651921af Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Oh, now I read it again and I realize you try to compile c= ompiler-rt and not musl. I'm so sorry for misunderstanding. I had a rou= gh day.

PS: Sorry for spam

2018-02-13 15:36 GMT+01:00 Mat=C3= =BA=C5=A1 Olek=C5=A1=C3=A1k <oleksak.matus@gmail.com>:=
I assumed it's the = same problem a had last week on pure llvm environment and I discovered bug = in compiler-rt detection which solves my patch.
=

2018-02-13 15:33 GMT+01:00 Dmitry Golovin <dima@golovin.in>:<= br>
Thank you for the patch, but I don't = think it is relevant to this problem.

If you take a look at my build script, you'll see that I don't need= it: https://github.com/tpimh/ngtc/blob/a= lpine/build.sh#L73

Regards,
Dmitry

13.02.2018, 16:31, "Mat=C3=BA=C5=A1 Olek=C5=A1=C3=A1k" <oleksak.matus@gmail.= com>:
> Try this patch to correctly link compiler-rt.
>
> 2018-02-13 15:15 GMT+01:00 Szabolcs Nagy <nsz@port70.net>:
>> * Dmitry Golovin <dima@golovin.in> [2018-02-13 15:34:34 +0200]:
>>> I'm trying to compile compiler-rt with musl and it used to= be fine, but I can't succeed with recent versions of compiler-rt.
>>>
>>> The compilation fails because of the lack of real_shmctl while= musl clearly has shmctl: http://git.musl-li= bc.org/cgit/musl/tree/src/ipc/shmctl.c
>>>
>>> Here is the complete output:
>>>
>>>=C2=A0 =C2=A0 =C2=A0llvm/projects/compiler-rt/lib/msan/msa= n_interceptors.cc:1446:15: error: no member named 'real_shmctl'= ; in namespace '__interception'; did you mean 'real_ioctl'?=
>>>=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0int res =3D REAL(shmctl)(shmi= d, shmctl_ipc_stat, &ds);
>>>=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 = =C2=A0^~~~~~~~~~~~
>>
>> there should be a
>>
>> DECLARE_REAL(int, shmctl, int shmid, int cmd, void *buf)
>>
>> in that file which defines __interception::real_shmctl.
>>
>>> To compile without glibc on linux using this patch:
>>> ht= tps://github.com/tpimh/ngtc/blob/alpine/patch/compiler-rt-01-sani= tizer-nongnu.patch
>>>
>>> Regards,
>>> Dmitry


--001a113d723ac2f51f05651921af--