summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobin H. Johnson <robbat2@gentoo.org>2015-08-08 13:49:04 -0700
committerRobin H. Johnson <robbat2@gentoo.org>2015-08-08 17:38:18 -0700
commit56bd759df1d0c750a065b8c845e93d5dfa6b549d (patch)
tree3f91093cdb475e565ae857f1c5a7fd339e2d781e /sci-mathematics/ggnfs
downloadgentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.gz
gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.bz2
gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.zip
proj/gentoo: Initial commit
This commit represents a new era for Gentoo: Storing the gentoo-x86 tree in Git, as converted from CVS. This commit is the start of the NEW history. Any historical data is intended to be grafted onto this point. Creation process: 1. Take final CVS checkout snapshot 2. Remove ALL ChangeLog* files 3. Transform all Manifests to thin 4. Remove empty Manifests 5. Convert all stale $Header$/$Id$ CVS keywords to non-expanded Git $Id$ 5.1. Do not touch files with -kb/-ko keyword flags. Signed-off-by: Robin H. Johnson <robbat2@gentoo.org> X-Thanks: Alec Warner <antarus@gentoo.org> - did the GSoC 2006 migration tests X-Thanks: Robin H. Johnson <robbat2@gentoo.org> - infra guy, herding this project X-Thanks: Nguyen Thai Ngoc Duy <pclouds@gentoo.org> - Former Gentoo developer, wrote Git features for the migration X-Thanks: Brian Harring <ferringb@gentoo.org> - wrote much python to improve cvs2svn X-Thanks: Rich Freeman <rich0@gentoo.org> - validation scripts X-Thanks: Patrick Lauer <patrick@gentoo.org> - Gentoo dev, running new 2014 work in migration X-Thanks: Michał Górny <mgorny@gentoo.org> - scripts, QA, nagging X-Thanks: All of other Gentoo developers - many ideas and lots of paint on the bikeshed
Diffstat (limited to 'sci-mathematics/ggnfs')
-rw-r--r--sci-mathematics/ggnfs/Manifest4
-rw-r--r--sci-mathematics/ggnfs/files/ggnfs-0.77.1-gentoo.patch158
-rw-r--r--sci-mathematics/ggnfs/ggnfs-0.77.1-r2.ebuild67
-rw-r--r--sci-mathematics/ggnfs/metadata.xml11
4 files changed, 240 insertions, 0 deletions
diff --git a/sci-mathematics/ggnfs/Manifest b/sci-mathematics/ggnfs/Manifest
new file mode 100644
index 000000000000..11526490e57c
--- /dev/null
+++ b/sci-mathematics/ggnfs/Manifest
@@ -0,0 +1,4 @@
+DIST def-nm-params.txt 3495 SHA256 5febf991cdd4112265bd58379c6d0819e6bb01b6e656902256fe13e4b63ba97c SHA512 b924292bc5354f87a3f88f2c35b767b9183704ced61c0e709cdd0974a2e1f34a4c170c6d12524b10162f63306f74001ad30e82ac7997d98db823006086772460 WHIRLPOOL 9ecabb6bee118269bd4d345582d36f9f82d54585ce7092adb3b6e1d27be4d0297201a408c76bb692047192a996982113d8387aad3c4764062f6d23f2f9febc82
+DIST def-par.txt 4957 SHA256 40d0b9be2c52282f29ff8cbc50799b625fc05b1da6eb7f2070fb3eb2ac81e7fa SHA512 fc0851513b1170e0a43e7458e24da4274146272018b7fefbe35280005ebeba20458756c4d4715b2a98780354dd1c5bcf31d98dd1388f1d352fb718062141c434 WHIRLPOOL 81151ab8235b2b55a7e8ceca4453b49bab3d3109eaf1352808b7e42c3612977402856c518ba8d8a1e5b6b80e33bbc3f33bdc565da5d3ee9e4251a1d253ace496
+DIST ggnfs-0.77.1.zip 2279013 SHA256 f6509661f22c562b3616e99989d39c160e8f49664e1fe3215d2f0d1441003a7a SHA512 77f5050d1310df5de45e80a25c8421cc9240ce11776fc4af596ce19d8b064b926dcc7e6dd7b2ef12d86056f7af0b67db2f746fc261cba24bbcf1efef06287513 WHIRLPOOL 5cb0e67aebd7ed9001ea2347b2211f9ca84ec50d18982436b111c0abb1c3223c66fbb5d029fa38d43e1137e7e7c7087daca85648fba7da92bbfcfe3760ccf87e
+DIST ggnfs-doc.pdf 252344 SHA256 6319442ba7fbeffa7000eb8ded1998877f3ecafc96551fa52c396d7f5d0775f2 SHA512 60f4153dbd31d7484b37a4f805eb71c9a785af884f228039136cd92e64ef145593dc0fde9e6f1c58a11d2d5124760d08d66566134f764e65f7dce86a36a11f01 WHIRLPOOL d93477a474172feb6bcb1db8cad04084496105e990d7906eee839ec49884718c3310e413cdfc6c3a36a42da755cf430a1db337a27a72a152aec6f62b17005758
diff --git a/sci-mathematics/ggnfs/files/ggnfs-0.77.1-gentoo.patch b/sci-mathematics/ggnfs/files/ggnfs-0.77.1-gentoo.patch
new file mode 100644
index 000000000000..ac7516034147
--- /dev/null
+++ b/sci-mathematics/ggnfs/files/ggnfs-0.77.1-gentoo.patch
@@ -0,0 +1,158 @@
+ src/Makefile | 34 +++++++++++++++++-----------------
+ src/lasieve4/Makefile | 6 +++---
+ src/pol5/Makefile | 8 ++++----
+ 3 files changed, 24 insertions(+), 24 deletions(-)
+
+diff --git a/src/Makefile b/src/Makefile
+index 01f66be..59b433f 100644
+--- a/src/Makefile
++++ b/src/Makefile
+@@ -1,15 +1,15 @@
+ # Workaround for PPC
+ # Due to unknown reason -march isn't supported there
+ ifeq ($(ARCH),970)
+- ALLOPT=-mcpu=$(ARCH) -m64 -pipe
++ ALLOPT=
+ else
+- ALLOPT=-march=$(ARCH) -pipe
++ ALLOPT=
+ endif
+
+ INC=-I. -I.. -I../include $(LOCALINC)
+ LIBS=-lgmp -lm
+ BINDIR=../bin
+-LIBFLAGS=$(LOCALLIB)
++LDFLAGS+=$(LOCALLIB)
+
+ MATBUILD_TPIE=0
+ TPIE_DIR=../../tpie
+@@ -17,7 +17,7 @@ TPIE_DIR=../../tpie
+ # Turn on\off workaround for GMP 4.2 bug
+ # Consult http://swox.com/list-archives/gmp-bugs/2006-May/000475.html
+ # for more info
+-GMP_BUG=1
++GMP_BUG=0
+
+ ifeq ($(HOST),generic)
+ ALLOPT+= -DGGNFS_HOST_GENERIC
+@@ -32,10 +32,10 @@ ifeq ($(ARCH),prescott)
+ ALLOPT+= -DL2_CACHE_SIZE=1024
+ endif
+
+-DEBUGOPT=-W -Wall -g -pg
++DEBUGOPT=-W -Wall
+
+-CFLAGS=-DNDEBUG -O3 -funroll-loops -finline-functions \
+- -ftracer -fomit-frame-pointer -W -Wall $(ALLOPT)
++CFLAGS+=-DNDEBUG \
++ -W -Wall $(ALLOPT)
+ # CFLAGS=$(DEBUGOPT) $(ALLOPT)
+ # -ffast-math removed since -funsafe-math-optimizations seems to cause occasional problems, especially in sqrt
+
+@@ -71,7 +71,7 @@ endif
+ ifeq ($(MATBUILD_TPIE),1)
+ BINS+= $(BINDIR)/matbuild-tpie
+ INC+= -I$(TPIE_DIR)/include
+- LIBFLAGS+= -L$(TPIE_DIR)/lib
++ LDFLAGS+= -L$(TPIE_DIR)/lib
+ LIBS+=-ltpie
+ endif
+
+@@ -97,35 +97,35 @@ bins : $(BINS)
+ $(CC) $(CFLAGS) -o $@ -c $*.S
+
+ $(BINDIR)/sieve : sieve.c clsieve.c $(OBJS) makefb.o
+- $(CC) $(INC) $(CFLAGS) $(LIBFLAGS) -o $@ $^ $(LIBS)
++ $(CC) $(INC) $(CFLAGS) $(LDFLAGS) -o $@ $^ $(LIBS)
+
+ $(BINDIR)/makefb : makefb.c $(OBJS)
+- $(CC) $(INC) $(CFLAGS) $(LIBFLAGS) -D_MAKEFB_STANDALONE -o $@ \
++ $(CC) $(INC) $(CFLAGS) $(LDFLAGS) -D_MAKEFB_STANDALONE -o $@ \
+ makefb.c $(OBJS) $(LIBS)
+
+ $(BINDIR)/procrels : procrels.c $(OBJS)
+- $(CC) $(INC) $(CFLAGS) $(LIBFLAGS) -o $@ procrels.c $(OBJS) $(LIBS)
++ $(CC) $(INC) $(CFLAGS) $(LDFLAGS) -o $@ procrels.c $(OBJS) $(LIBS)
+
+ $(BINDIR)/matbuild : matbuild.c $(OBJS)
+- $(CC) $(INC) $(CFLAGS) $(LIBFLAGS) -o $@ matbuild.c combparts.c \
++ $(CC) $(INC) $(CFLAGS) $(LDFLAGS) -o $@ matbuild.c combparts.c \
+ $(OBJS) $(LIBS)
+
+ $(BINDIR)/matbuild-tpie : matbuild.c $(OBJS)
+- $(CPP) $(INC) $(CFLAGS) $(LIBFLAGS) -DGGNFS_TPIE -o $@ matbuild.c \
++ $(CPP) $(INC) $(CFLAGS) $(LDFLAGS) -DGGNFS_TPIE -o $@ matbuild.c \
+ experimental/combparts_tpie.cpp experimental/llist_tpie.cpp \
+ $(OBJS) $(LIBS)
+
+ $(BINDIR)/matprune : matprune.c $(OBJS)
+- $(CC) $(INC) $(CFLAGS) $(LIBFLAGS) -o $@ matprune.c $(OBJS) $(LIBS)
++ $(CC) $(INC) $(CFLAGS) $(LDFLAGS) -o $@ matprune.c $(OBJS) $(LIBS)
+
+ $(BINDIR)/matsolve : matsolve.c $(OBJS)
+- $(CC) $(INC) $(CFLAGS) $(LIBFLAGS) -o $@ matsolve.c $(OBJS) $(LIBS)
++ $(CC) $(INC) $(CFLAGS) $(LDFLAGS) -o $@ matsolve.c $(OBJS) $(LIBS)
+
+ $(BINDIR)/sqrt : sqrt.c $(OBJS)
+- $(CC) $(INC) $(CFLAGS) $(LIBFLAGS) -o $@ sqrt.c $(OBJS) $(LIBS)
++ $(CC) $(INC) $(CFLAGS) $(LDFLAGS) -o $@ sqrt.c $(OBJS) $(LIBS)
+
+ $(BINDIR)/polyselect : polyselect.c $(OBJS)
+- $(CC) $(INC) $(CFLAGS) $(LIBFLAGS) -o $@ polyselect.c $(OBJS) $(LIBS)
++ $(CC) $(INC) $(CFLAGS) $(LDFLAGS) -o $@ polyselect.c $(OBJS) $(LIBS)
+
+ latsiever :
+ $(MAKE) -C lasieve4
+diff --git a/src/lasieve4/Makefile b/src/lasieve4/Makefile
+index 31e05a9..6886b16 100644
+--- a/src/lasieve4/Makefile
++++ b/src/lasieve4/Makefile
+@@ -10,8 +10,8 @@
+ # 6/13/04: Hacked up for use in GGNFS by Chris Monico.
+
+ INC=-I.. -I../../include $(LOCALINC)
+-LIBFLAGS=-L. $(LOCALLIB)
+-CFLAGS+=-Os
++LDFLAGS+=-L. $(LOCALLIB)
++CFLAGS+=
+
+ BINDIR=../../bin
+ FACT=prho.o
+@@ -58,7 +58,7 @@ gnfs-lasieve4eI%.o: gnfs-lasieve4e.c lasieve.h asm/siever-config.h
+
+ $(BINDIR)/gnfs-lasieve4I%e: gnfs-lasieve4eI%.o $(OBJS) libgmp-aux.a \
+ asm/liblasieve.a asm/liblasieveI%.a $(FACT)
+- $(CC) $(CFLAGS) $(INC) $(LIBFLAGS) -o $@ $^ $(LIBS)
++ $(CC) $(CFLAGS) $(INC) $(LDFLAGS) -o $@ $^ $(LIBS)
+
+ asm/lib%.a:
+ $(MAKE) -C asm
+diff --git a/src/pol5/Makefile b/src/pol5/Makefile
+index 44b08be..e474ffb 100644
+--- a/src/pol5/Makefile
++++ b/src/pol5/Makefile
+@@ -1,6 +1,6 @@
+ BINDIR=../../bin
+ INC=-I.. -I../../include $(LOCALINC)
+-LIBFLAGS=$(LOCALLIB)
++LDFLAGS+=$(LOCALLIB)
+ LIBS=-lm -lgmp
+ CFLAGS2=
+
+@@ -46,13 +46,13 @@ all: $(BINS)
+ $(CC) $(INC) -c $(CFLAGS) $(CFLAGS2) $^
+
+ $(BINDIR)/pol51m0b: pol51m0b.o $(OBJS) $(OBJS2)
+- $(CC) $(INC) -o $@ $(CFLAGS) $(CFLAGS2) $^ $(LIBFLAGS) $(LIBS)
++ $(CC) $(INC) $(LDFLAGS) -o $@ $(CFLAGS) $(CFLAGS2) $^ $(LIBS)
+
+ $(BINDIR)/pol51m0n: pol51m0n.o $(OBJS) $(OBJS3)
+- $(CC) $(INC) $(CFLAGS) $(CFLAGS2) -o $@ $^ $(LIBFLAGS) $(LIBS)
++ $(CC) $(INC) $(CFLAGS) $(CFLAGS2) $(LDFLAGS) -o $@ $^ $(LIBS)
+
+ $(BINDIR)/pol51opt: pol51opt.o $(OBJS) $(OBJS4)
+- $(CC) $(INC) $(CFLAGS) $(CFLAGS2) -o $@ $^ $(LIBFLAGS) $(LIBS)
++ $(CC) $(INC) $(CFLAGS) $(CFLAGS2) $(LDFLAGS) -o $@ $^ $(LIBS)
+
+ clean : ;
+ rm -f $(BINS) *.o core
diff --git a/sci-mathematics/ggnfs/ggnfs-0.77.1-r2.ebuild b/sci-mathematics/ggnfs/ggnfs-0.77.1-r2.ebuild
new file mode 100644
index 000000000000..30cf4c9e1c79
--- /dev/null
+++ b/sci-mathematics/ggnfs/ggnfs-0.77.1-r2.ebuild
@@ -0,0 +1,67 @@
+# Copyright 1999-2013 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+inherit eutils
+
+DESCRIPTION="A suite of algorithms to help factoring large integers"
+# inactive old homepage exists, this is a fork
+HOMEPAGE="https://github.com/radii/ggnfs"
+# snapshot because github makes people stupid
+SRC_URI="
+ http://dev.gentooexperimental.org/~dreeevil/${P}.zip
+ http://stuff.mit.edu/afs/sipb/project/pari-gp/ggnfs/Linux/src/def-par.txt
+ http://stuff.mit.edu/afs/sipb/project/pari-gp/ggnfs/Linux/src/def-nm-params.txt
+ http://gentooexperimental.org/~patrick/ggnfs-doc.pdf"
+
+SLOT="0"
+LICENSE="GPL-2"
+KEYWORDS="~amd64 ~x86"
+IUSE=""
+
+DEPEND=">=dev-libs/gmp-4.3:0
+ app-arch/unzip"
+RDEPEND="${DEPEND}
+ !sci-mathematics/cado-nfs" # file collisions, fixable
+
+S=${WORKDIR}/${PN}-master
+
+src_prepare() {
+ epatch "${FILESDIR}"/${P}-gentoo.patch
+ echo "#define GGNFS_VERSION \"0.77.1-$ARCH\"" > include/version.h || die
+ # fix directory symlink, add missing targets, rewrite variable used by portage internally
+ cd src/lasieve4 && rm -f -r asm && ln -s ppc32 asm || die
+ sed -i -e 's/all: liblasieve.a/all: liblasieve.a liblasieveI11.a liblasieveI15.a liblasieveI16.a/' asm/Makefile || die
+ cd "${S}"
+ sed -i -e 's/ARCH/MARCH/g' Makefile src/Makefile || die
+ sed -i -e 's/$(LSBINS) strip/$(LSBINS)/' src/Makefile || die #No stripping!
+ sed -i -e 's/SVN \$Revision\$/0.77.1 snapshot/' src/experimental/lasieve4_64/gnfs-lasieve4e.c src/lasieve4/gnfs-lasieve4e.c || die
+ tc-export CC
+}
+
+src_configure() { :; }
+
+src_compile() {
+ # setting MARCH like this is fugly, but it uses -march=$ARCH - better fix welcome
+ # it also assumes a recent-ish compiler
+ cd src
+ HOST="generic" MARCH="${ARCH}" emake -j1
+}
+
+src_install() {
+ mkdir -p "${D}/usr/bin/"
+ for i in gnfs-lasieve4I11e gnfs-lasieve4I12e gnfs-lasieve4I13e gnfs-lasieve4I14e \
+ gnfs-lasieve4I15e gnfs-lasieve4I16e makefb matbuild matprune matsolve pol51m0b pol51m0n \
+ pol51opt polyselect procrels sieve sqrt; do
+ cp "${S}/bin/${i}" "${D}/usr/bin/" || die
+ done
+ mkdir -p "${D}/usr/share/doc/${PN}"
+ cp "${DISTDIR}/def-par.txt" "${D}/usr/share/doc/${PN}" || die
+ cp "${DISTDIR}/def-nm-params.txt" "${D}/usr/share/doc/${PN}" || die
+ docompress -x "/usr/share/doc/${PN}/def-par.txt"
+ docompress -x "/usr/share/doc/${PN}/def-nm-params.txt"
+ # TODO: docs? File collisions?
+ cp ${DISTDIR}/ggnfs-doc.pdf "${D}/usr/share/doc/${PN}" || die
+}
diff --git a/sci-mathematics/ggnfs/metadata.xml b/sci-mathematics/ggnfs/metadata.xml
new file mode 100644
index 000000000000..b5260b94eb22
--- /dev/null
+++ b/sci-mathematics/ggnfs/metadata.xml
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer>
+ <email>patrick@gentoo.org</email>
+ <name>Patrick Lauer</name>
+ </maintainer>
+ <upstream>
+ <remote-id type="github">radii/ggnfs</remote-id>
+ </upstream>
+</pkgmetadata>