From mboxrd@z Thu Jan 1 00:00:00 1970 From: Alex Vong Subject: [PATCH 2/2] gnu: Add Mlucas. Date: Sat, 31 Oct 2015 21:56:56 +0800 Message-ID: <20151031215656.4fa557f2@debian> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:46570) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZsWex-0002Rh-Mw for guix-devel@gnu.org; Sat, 31 Oct 2015 09:57:32 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZsWev-0005Es-M1 for guix-devel@gnu.org; Sat, 31 Oct 2015 09:57:31 -0400 Received: from mail-pa0-x233.google.com ([2607:f8b0:400e:c03::233]:35612) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZsWev-0005Eo-Ec for guix-devel@gnu.org; Sat, 31 Oct 2015 09:57:29 -0400 Received: by pasz6 with SMTP id z6so101217778pas.2 for ; Sat, 31 Oct 2015 06:57:28 -0700 (PDT) Received: from debian (n219073086160.netvigator.com. [219.73.86.160]) by smtp.gmail.com with ESMTPSA id so4sm14082126pbc.72.2015.10.31.06.57.27 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sat, 31 Oct 2015 06:57:28 -0700 (PDT) List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org To: guix-devel@gnu.org =46rom 00c6dce0002c07a1fecbe5d53bbbb724d0e6379b Mon Sep 17 00:00:00 2001 From: Alex Vong Date: Sat, 31 Oct 2015 19:50:50 +0800 Subject: [PATCH 2/2] gnu: Add Mlucas. * gnu/packages/maths.scm (mlucas): New variable. --- gnu/packages/maths.scm | 68 ++++++++++++++++++++++++++++++++++++++++++++++= ++++ 1 file changed, 68 insertions(+) diff --git a/gnu/packages/maths.scm b/gnu/packages/maths.scm index b4b930d..8076f51 100644 --- a/gnu/packages/maths.scm +++ b/gnu/packages/maths.scm @@ -32,10 +32,14 @@ #:use-module (guix download) #:use-module (guix svn-download) #:use-module (guix utils) + #:use-module (guix build build-flags) #:use-module (guix build utils) #:use-module (guix build-system cmake) #:use-module (guix build-system gnu) #:use-module (gnu packages algebra) + #:use-module (gnu packages autogen) + #:use-module (gnu packages autotools) + #:use-module (gnu packages base) #:use-module (gnu packages bison) #:use-module (gnu packages boost) #:use-module (gnu packages check) @@ -1975,3 +1979,67 @@ algorithm and optimum parameters depending on the da= taset. FLANN is written in C++ and contains bindings for C, Octave and Python.") (license (license:non-copyleft "file://COPYING" "See COPYING in the distribution.")))) + +(define-public mlucas + (let ( ; some dpkg-buildflags and custom build flags presented as flag-l= ist + (custom-flag-list + (flag-list- + (flag-list+ all-flag-list + (flag-list + #:CFLAGS '("-Ofast" + "-pipe" + "-flto" + "-fno-aggressive-loop-optimizations") + #:LDFLAGS '("-Wl,--as-needed"))) + default-flag-list))) + ;; start package definition + (package + (name "mlucas") + (version "14.1") + (source (origin + (method url-fetch) + (uri (string-append "http://hogranch.com/mayer/src/C/mlucas-" + version + ".tar.xz")) + (sha256 + (base32 + "1i6j1479icxfwp3ixs6dk65qilv9hn7213q3iibndlgwjfmh0gb4")))) + (build-system gnu-build-system) + (arguments + `(#:phases + (modify-phases %standard-phases + (add-before 'configure + 'bootstrap + (lambda _ + (zero? (system "./bootstrap"))))) + #:configure-flags + '("--disable-NORMAL-CFLAGS" + "--disable-TRICKY-CFLAGS" + "--enable-MLUCAS-DEFAULT-PATH" + "--enable-verbose-compiler" + ,@(flag-list->string-list custom-flag-list)))) + ;; run-time dependencies + (propagated-inputs `(("coreutils" ,coreutils) + ("sed" ,sed))) + ;; build-time dependencies + (native-inputs `(("autogen" ,autogen) + ("autoconf" ,autoconf) + ("automake" ,automake) + ("perl" ,perl))) + ;; descriptions of the package + (synopsis "Program to perform Lucas-Lehmer test on a Mersenne number") + (description "mlucas performs Lucas-Lehmer test +on prime-exponent Mersenne numbers, +that is, integers of the form 2 ^ p - 1, with prime exponent p. +In short, everything you need to search for world-record Mersenne primes! +It has been used in the verification of various Mersenne primes, +including the 45th, 46th and 48th found Mersenne prime. + +You may use it to test any suitable number as you wish, +but it is preferable that you do so in a coordinated fashion, +as part of the Great Internet Mersenne Prime Search (GIMPS). +For more information on GIMPS, +see for details. +") + (home-page "http://hogranch.com/mayer/README.html") + (license license:gpl2+)))) --=20 2.1.4