From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from pigeon.gentoo.org ([208.92.234.80] helo=lists.gentoo.org) by finch.gentoo.org with esmtp (Exim 4.60) (envelope-from ) id 1PG6Zq-00047i-8A for garchives@archives.gentoo.org; Wed, 10 Nov 2010 09:02:46 +0000 Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id D0CDDE0994 for ; Wed, 10 Nov 2010 09:02:45 +0000 (UTC) Received: from mailgate-02.zdv.uni-mainz.de (mailgate-02.zdv.Uni-Mainz.DE [134.93.178.246]) by pigeon.gentoo.org (Postfix) with ESMTP id CB78FE08BE for ; Wed, 10 Nov 2010 08:41:54 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=uni-mainz.de; i=cschwan@students.uni-mainz.de; q=dns/txt; s=ironport; t=1289378515; x=1320914515; h=from:to:subject:date:references:in-reply-to:mime-version: content-transfer-encoding:message-id; z=From:=20Christopher=20Schwan=20|To:=20|Subject: =20Re:=20[gentoo-science]=20sci-libs/mpir=20for=20the=20m ain=20tree|Date:=20Wed,=2010=20Nov=202010=2009:41:49=20+0 100|References:=20<20101108234212.GN1906@denkmatte.mittag -leffler.se>=20<201011092119.54408.f.r.bissey@massey.ac.n z>|In-Reply-To:=20<201011092119.54408.f.r.bissey@massey.a c.nz>|MIME-Version:=201.0|Content-Transfer-Encoding:=20qu oted-printable|Message-ID:=20<201011100941.49756.cschwan@ students.uni-mainz.de>; bh=r7ZQOk/pdcGWeXEystlpojCEkgMO6P0IR1hC85vE550=; b=KYU2IQqXh359kNOpMEXLq6U8UI927ThEbv984Ph51w2qBM6flw0vhwLy Jdk5VzTCLluok19xsADsETNYuNlL/m427x98JBCgw4rRe0h+aavFa9B99 rripe2i7Kp/tnTV9AX0g5HuWj7iUiannk0hbF3Oyf3YruAFdneh+l7UEz k=; X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AiUFADHp2UwKXgZQ/2dsb2JhbACUMo5zuz2FSgSNaQ Received: from e14hub-01.zdv.uni-mainz.de ([10.94.6.80]) by mailgate-02.zdv.uni-mainz.de with ESMTP; 10 Nov 2010 09:41:51 +0100 Received: from gnuke-notebook.localnet (134.93.86.55) by mail.uni-mainz.de (10.94.6.82) with Microsoft SMTP Server (TLS) id 14.1.218.12; Wed, 10 Nov 2010 09:41:50 +0100 From: Christopher Schwan To: Subject: Re: [gentoo-science] sci-libs/mpir for the main tree Date: Wed, 10 Nov 2010 09:41:49 +0100 User-Agent: KMail/1.13.5 (Linux/2.6.34-gentoo-r12; KDE/4.5.3; i686; ; ) References: <20101108234212.GN1906@denkmatte.mittag-leffler.se> <201011092119.54408.f.r.bissey@massey.ac.nz> In-Reply-To: <201011092119.54408.f.r.bissey@massey.ac.nz> Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-science@lists.gentoo.org Reply-to: gentoo-science@lists.gentoo.org MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Message-ID: <201011100941.49756.cschwan@students.uni-mainz.de> X-Originating-IP: [134.93.86.55] X-Archives-Salt: 73dcc4e6-989c-492f-8326-87a213331a07 X-Archives-Hash: 98070800836372dbd125a589937014ec Hi, On Tuesday 09 November 2010 09:19:54 Fran=E7ois Bissey wrote: > > Hi, > >=20 > > my next migration victim will be mpir, the friendly clone of gmp. The > > current ebuild is the same in sage-on-gentoo and science. It has this > > assembler stuff in it that I don't understand. Who did this? What is > > the latest here, can we remove the fat TODO-banner (or DO it?). > >=20 > > Any other hints/objections? (Yes, I know that there is a bump > > waiting...) >=20 > Hi Thomas, >=20 > Christopher did it. mpir like gmp suffer from executable stacks. I followed the instructions listed in number 6 of the following page:=20 http://www.gentoo.org/proj/en/hardened/gnu-stack.xml . However, the fix is= =20 incomplete (some architectures still have executable stacks) and I had some= =20 problems with BASH: for i in $(find . -type f -name '*.asm') ; do echo $i >/dev/null cat >> $i <<-EOF #if defined(__linux__) && defined(__ELF__) .section .note.GNU-stack,"",%progbits #endif EOF done If I remove the line with "echo" (which *should* be completely useless), th= e=20 cat command does not patch files - WHY ?! Also, mpir seemed to have dropped= =20 yasm beginning with mpir-2.1 (?), so I think at least one loop in mpir's=20 ebuild is superfluous. > There are talk on sage-devel which is very close to mpir upstream > to take a different approach: using an m4 macro and a linker flag > to remove them -Wl,-z,noexecstack. This seems to be a better idea. > The motivation to fix this is fedora 14 which doesn't allow executable > stacks by default. > I think the warning could be removed for now but the ebuild will probably > need a little TLC in the near future. >=20 > Francois Christopher