diff options
author | Thilo Bangert <bangert@gentoo.org> | 2009-03-16 11:14:03 +0000 |
---|---|---|
committer | Thilo Bangert <bangert@gentoo.org> | 2009-03-16 11:14:03 +0000 |
commit | 768ddd735b8b4c631eea656d0a877fbbfbf990b0 (patch) | |
tree | 9cea636e07a0ebfd0a38edf5653f617837a23eb2 /app-crypt | |
parent | Version bump and dumps. (diff) | |
download | gentoo-2-768ddd735b8b4c631eea656d0a877fbbfbf990b0.tar.gz gentoo-2-768ddd735b8b4c631eea656d0a877fbbfbf990b0.tar.bz2 gentoo-2-768ddd735b8b4c631eea656d0a877fbbfbf990b0.zip |
introduce src_configure (bug #239970) - honour CC (bug #243546) - thanks Diego
(Portage version: 2.2_rc24/cvs/Linux i686)
Diffstat (limited to 'app-crypt')
-rw-r--r-- | app-crypt/nistp224/ChangeLog | 10 | ||||
-rw-r--r-- | app-crypt/nistp224/files/nistp224-0.75-honour-CC.patch | 79 | ||||
-rw-r--r-- | app-crypt/nistp224/nistp224-0.75-r1.ebuild | 54 |
3 files changed, 141 insertions, 2 deletions
diff --git a/app-crypt/nistp224/ChangeLog b/app-crypt/nistp224/ChangeLog index 701b91156593..67c09216ca36 100644 --- a/app-crypt/nistp224/ChangeLog +++ b/app-crypt/nistp224/ChangeLog @@ -1,6 +1,12 @@ # ChangeLog for app-crypt/nistp224 -# Copyright 1999-2008 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/app-crypt/nistp224/ChangeLog,v 1.2 2008/06/26 07:57:55 bangert Exp $ +# Copyright 1999-2009 Gentoo Foundation; Distributed under the GPL v2 +# $Header: /var/cvsroot/gentoo-x86/app-crypt/nistp224/ChangeLog,v 1.3 2009/03/16 11:14:03 bangert Exp $ + +*nistp224-0.75-r1 (16 Mar 2009) + + 16 Mar 2009; Thilo Bangert <bangert@gentoo.org> + +files/nistp224-0.75-honour-CC.patch, +nistp224-0.75-r1.ebuild: + introduce src_configure (bug #239970) - honour CC (bug #243546) 26 Jun 2008; Thilo Bangert <bangert@gentoo.org> nistp224-0.75.ebuild: remove bindnow-flags - as per bug #226945 diff --git a/app-crypt/nistp224/files/nistp224-0.75-honour-CC.patch b/app-crypt/nistp224/files/nistp224-0.75-honour-CC.patch new file mode 100644 index 000000000000..1f5a938c2cc3 --- /dev/null +++ b/app-crypt/nistp224/files/nistp224-0.75-honour-CC.patch @@ -0,0 +1,79 @@ +--- Makefile.orig 2008-11-04 22:36:26.000000000 +0100 ++++ Makefile 2008-11-04 22:40:08.000000000 +0100 +@@ -1,3 +1,5 @@ ++CC=`head -n 1 conf-cc` ++ + default: it + + clean: +@@ -108,7 +110,7 @@ + hasrpcc.h load rts rts.exp speed systype + rm -f sysdeps + echo nistp224 0.75 >> sysdeps +- gcc --version >> sysdeps ++ ${CC} --version >> sysdeps + cat systype compile load >> sysdeps + grep sysdep hasgethr.h >> sysdeps + grep sysdep hasrdtsc.h >> sysdeps +--- find-systype.sh.orig 2008-11-04 22:35:18.000000000 +0100 ++++ find-systype.sh 2008-11-04 22:36:51.000000000 +0100 +@@ -79,8 +79,8 @@ + ;; + esac + else +- gcc -c trycpp.c +- gcc -o trycpp trycpp.o ++ ${CC} -c trycpp.c ++ ${CC} -o trycpp trycpp.o + case `./trycpp` in + nextstep) + oper="nextstep-`hostinfo | sed -n 's/^[ ]*NeXT Mach \([^:]*\):.*$/\1/p'`" +--- print-cc.sh.orig 2008-11-04 22:34:51.000000000 +0100 ++++ print-cc.sh 2008-11-04 22:35:04.000000000 +0100 +@@ -1,46 +1,5 @@ + cc="`head -n 1 conf-cc`" + systype="`cat systype`" + +- +-gcc -c trycpp.c -malign-double >/dev/null 2>&1 \ +-&& gccad="-malign-double" +- +-gcc -c trycpp.c -mcpu=ultrasparc >/dev/null 2>&1 \ +-&& gccus="-mcpu=ultrasparc" +- +-gcc -c trycpp.c -mcpu=powerpc >/dev/null 2>&1 \ +-&& gccpp="-mcpu=powerpc" +- +-gcc -c trycpp.c -mcpu=21164 >/dev/null 2>&1 \ +-&& gcc21="-mcpu=21164" +- +-rm -f trycpp.o +- +- +-gccbase="gcc -fomit-frame-pointer -Wimplicit -Wunused -Wcomment -Wchar-subscripts -Wuninitialized -Wshadow -Wcast-qual -Wcast-align -Wwrite-strings" +- +- +-case "$cc:$systype" in +- auto:*:i386-*:*) +- cc="$gccbase -O1 $gccad" +- ;; +- auto:*:sparc-*:*:*:*) +- cc="$gccbase -O1 $gccus" +- ;; +- auto:*:ppc-*:*:*:*) +- cc="$gccbase -O2 $gccpp" +- ;; +- auto:*:alpha-*:*:*:*) +- cc="$gccbase -O2 $gcc21" +- ;; +- auto:aix-*:-:-:*:-) +- cc="$gccbase -O2 $gccpp" +- ;; +- auto:*) +- cc="$gccbase -O2" +- ;; +-esac +- +- + cat warn-auto.sh + echo exec "$cc" '-c ${1+"$@"}' diff --git a/app-crypt/nistp224/nistp224-0.75-r1.ebuild b/app-crypt/nistp224/nistp224-0.75-r1.ebuild new file mode 100644 index 000000000000..0fb3005a7db3 --- /dev/null +++ b/app-crypt/nistp224/nistp224-0.75-r1.ebuild @@ -0,0 +1,54 @@ +# Copyright 1999-2009 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/app-crypt/nistp224/nistp224-0.75-r1.ebuild,v 1.1 2009/03/16 11:14:03 bangert Exp $ + +EAPI="2" + +inherit toolchain-funcs flag-o-matic fixheadtails + +DESCRIPTION="nistp224 performs compressed Diffie-Hellman key exchange on the NIST P-224 elliptic curve" +HOMEPAGE="http://cr.yp.to/nistp224.html" +SRC_URI="http://cr.yp.to/${PN}/${P}.tar.gz" +LICENSE="as-is" +SLOT="0" +KEYWORDS="~x86" +IUSE="" +DEPEND="" +RDEPEND=${DEPEND} +S="${WORKDIR}/math/${P}/src" + +src_prepare() { + epatch "${FILESDIR}"/${P}-asmfix.patch + epatch "${FILESDIR}"/${P}-declare-exit.patch + cd "${S}" + epatch "${FILESDIR}"/${P}-honour-CC.patch + ht_fix_file Makefile print*.sh +} + +src_configure() { + append-flags -fPIC + echo -n "$(tc-getCC) ${CFLAGS}" > conf-cc + echo -n "$(tc-getCC) ${LDFLAGS}" > conf-ld + if use ppc; then + # untested + echo -n "powerpc" > conf-opt + elif use sparc; then + # untested + echo -n "sparc" > conf-opt + else + # optiminations for ppro and pentium fail + echo -n "idea64" > conf-opt + fi +} + +src_compile() { + emake || die "emake failed" +} + +src_install() { + dobin nistp224 nistp224-56 + mv nistp224.a libnistp224.a + dolib.a libnistp224.a + insinto /usr/include + doins nistp224.h +} |