From mboxrd@z Thu Jan 1 00:00:00 1970 From: Efraim Flashner Subject: Re: [PATCH] Add googletest Date: Thu, 9 Jun 2016 21:40:54 +0300 Message-ID: <20160609184054.GB513@debian-netbook> References: <874m9fwa0k.fsf@openmailbox.org> <87lh2q2v1u.fsf@openmailbox.org> <20160531214400.GA22303@jasmine> <87twhdez33.fsf@openmailbox.org> <20160602014944.GB31306@jasmine> <87h9dbegsl.fsf@openmailbox.org> <20160605131210.GC859@debian-netbook> <877fe3pcl3.fsf@openmailbox.org> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="TakKZr9L6Hm6aLOc" Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:52054) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bB4tC-0001GM-SJ for guix-devel@gnu.org; Thu, 09 Jun 2016 14:41:13 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bB4t8-0006nz-LC for guix-devel@gnu.org; Thu, 09 Jun 2016 14:41:09 -0400 Received: from flashner.co.il ([178.62.234.194]:57256) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bB4t8-0006jb-8j for guix-devel@gnu.org; Thu, 09 Jun 2016 14:41:06 -0400 Content-Disposition: inline In-Reply-To: <877fe3pcl3.fsf@openmailbox.org> 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" To: Lukas Gradl Cc: guix-devel@gnu.org --TakKZr9L6Hm6aLOc Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Sun, Jun 05, 2016 at 04:09:28PM -0500, Lukas Gradl wrote: > Efraim Flashner writes: >=20 > > On Thu, Jun 02, 2016 at 10:44:58AM -0500, Lukas Gradl wrote: > >>=20 > >> Hi Leo, > >>=20 > > ... > >> > >> The tool "pump.py" is distributed with the Googletest source. It > >> appears to be a part of the source rather than a bundeled dependency a= nd > >> the only reference to it that I found was in Googletest, so I would > >> assume it is a part of Googletest. Therefore I did not create a > >> seperate package for that, but used the one provided in the Googletest > >> source tree. With that, the pre-generated headers can be reproduced. > >> The attached patch does that. > >>=20 > >> Thank you! > >>=20 > > > > A couple last things I found, otherwise it looks great. > > > >> From 7d4aaba39821130ba824c4b2f8bd236e0d1f1639 Mon Sep 17 00:00:00 2001 > >> From: Lukas Gradl > >> Date: Thu, 2 Jun 2016 10:36:17 -0500 > >> Subject: [PATCH] gnu: Add googletest. > >>=20 > >> * gnu/packages/check.scm (googletest): New variable. > >> --- > >> gnu/packages/check.scm | 64 +++++++++++++++++++++++++++++++++++++++++= +++++++++ > >> 1 file changed, 64 insertions(+) > >>=20 > >> diff --git a/gnu/packages/check.scm b/gnu/packages/check.scm > >> index 9eef7a9..4971c71 100644 > >> --- a/gnu/packages/check.scm > >> +++ b/gnu/packages/check.scm > >> @@ -5,6 +5,7 @@ > >> ;;; Copyright =C2=A9 2015 Andreas Enge > >> ;;; Copyright =C2=A9 2016 Efraim Flashner > >> ;;; Copyright =C2=A9 2016 Roel Janssen > >> +;;; Copyright =C2=A9 2016 Lukas Gradl > >> ;;; > >> ;;; This file is part of GNU Guix. > >> ;;; > >> @@ -24,6 +25,7 @@ > >> (define-module (gnu packages check) > >> #:use-module (gnu packages) > >> #:use-module (gnu packages autotools) > >> + #:use-module (gnu packages python) > >> #:use-module (guix licenses) > >> #:use-module (guix packages) > >> #:use-module (guix download) > >> @@ -193,3 +195,65 @@ in the code. Cppcheck primarily detects the type= s of bugs that the compilers > >> normally do not detect. The goal is to detect only real errors in th= e code > >> (i.e. have zero false positives).") > >> (license gpl3+))) > >> + > >> +(define-public googletest > >> + (package > >> + (name "googletest") > >> + (version "1.7.0") > >> + (source > >> + (origin > >> + (method url-fetch) > >> + (uri > >> + (string-append > >> + "https://github.com/google/googletest/archive/release-" > >> + version ".tar.gz")) > > > > add: (file-name (string-append name "-" version ".tar.gz")) >=20 > I added it. >=20 > > > >> + (sha256 > >> + (base32 > >> + "1k0nf1l9cb3prdmsvaajl5i31bx86c1mw0d5jgzykz7rzm36afpp")))) > >> + (build-system gnu-build-system) > >> + (native-inputs > >> + `(("python-2" ,python-2) > >> + ("autoconf" ,autoconf) > >> + ("automake" ,automake) > >> + ("libtool" ,libtool))) > >> + (arguments > >> + `( #:phases > >> + (modify-phases %standard-phases > >> + (add-before 'configure 'autoconf > >> + (lambda _ > >> + (zero? (system* "autoreconf" "-vfi")))) > >> + (add-before 'autoconf 'generate-headers > >> + (lambda _ > >> + (begin > >> + (delete-file "include/gtest/gtest-param-test.h") > >> + (system* "python2" "scripts/pump.py" > >> + "include/gtest/gtest-param-test.h.pump") > >> + (delete-file "include/gtest/internal/gtest-tuple.h") > >> + (system* "python2" "scripts/pump.py" > >> + "include/gtest//internal/gtest-tuple.h.pump") > >> + (delete-file > >> + "include/gtest/internal/gtest-param-util-generated.h") > >> + (system* > >> + "python2" "scripts/pump.py" > >> + "include/gtest/internal/gtest-param-util-generated.h.= pump") > >> + (delete-file "include/gtest/internal/gtest-type-util.h= ") > >> + (system* "python2" "scripts/pump.py" > >> + "include/gtest/internal/gtest-type-util.h.pum= p")))) > >> + (replace 'install > >> + (lambda _ > >> + (let ((out (assoc-ref %outputs "out")) > >> + (version version)) > > ^ > > you don't actually use this variable -- > > >=20 > Oh, Sorry about that. This is a leftover from a previous attemt that I > forgot to remove. >=20 > >> + (begin > >> + (install-file "lib/.libs/libgtest_main.a" > >> + (string-append out "/lib")) > >> + (install-file "lib/.libs/libgtest.a" > >> + (string-append out "/lib")) > >> + (copy-recursively > >> + (string-append "include") > > > > don't need the string-append above > > >=20 > Same here. >=20 > >> + (string-append out "/include"))))))))) > >> + (home-page "https://github.com/google/googletest/") > >> + (synopsis "Test discovery and XUnit test framework") > >> + (description "Google Test features an XUnit test framework, autom= ated test > >> +discovery, death tests, assertions, parameterized tests and XML test = report > >> +generation.") > >> + (license bsd-3))) > >> --=20 > >> 2.7.4 > >>=20 >=20 >=20 > Thank you for your review! >=20 > An updated patch is attached. >=20 > Best, > Lukas >=20 >=20 > From 54223517c0c05b5c5bfcca055c8b12cb650c8b40 Mon Sep 17 00:00:00 2001 > From: Lukas Gradl > Date: Sun, 5 Jun 2016 16:03:56 -0500 > Subject: [PATCH] gnu: Add googletest. >=20 > * gnu/packages/check.scm (googletest): New variable. > --- > gnu/packages/check.scm | 63 ++++++++++++++++++++++++++++++++++++++++++++= ++++++ > 1 file changed, 63 insertions(+) >=20 > diff --git a/gnu/packages/check.scm b/gnu/packages/check.scm > index 9eef7a9..64b5006 100644 > --- a/gnu/packages/check.scm > +++ b/gnu/packages/check.scm > @@ -5,6 +5,7 @@ > ;;; Copyright =C2=A9 2015 Andreas Enge > ;;; Copyright =C2=A9 2016 Efraim Flashner > ;;; Copyright =C2=A9 2016 Roel Janssen > +;;; Copyright =C2=A9 2016 Lukas Gradl > ;;; > ;;; This file is part of GNU Guix. > ;;; > @@ -24,6 +25,7 @@ > (define-module (gnu packages check) > #:use-module (gnu packages) > #:use-module (gnu packages autotools) > + #:use-module (gnu packages python) > #:use-module (guix licenses) > #:use-module (guix packages) > #:use-module (guix download) > @@ -193,3 +195,64 @@ in the code. Cppcheck primarily detects the types o= f bugs that the compilers > normally do not detect. The goal is to detect only real errors in the c= ode > (i.e. have zero false positives).") > (license gpl3+))) > + > +(define-public googletest > + (package > + (name "googletest") > + (version "1.7.0") > + (source > + (origin > + (method url-fetch) > + (uri > + (string-append > + "https://github.com/google/googletest/archive/release-" > + version ".tar.gz")) > + (file-name (string-append name "-" version ".tar.gz")) > + (sha256 > + (base32 > + "1k0nf1l9cb3prdmsvaajl5i31bx86c1mw0d5jgzykz7rzm36afpp")))) > + (build-system gnu-build-system) > + (native-inputs > + `(("python-2" ,python-2) > + ("autoconf" ,autoconf) > + ("automake" ,automake) > + ("libtool" ,libtool))) > + (arguments > + `(#:phases > + (modify-phases %standard-phases > + (add-before 'configure 'autoconf > + (lambda _ > + (zero? (system* "autoreconf" "-vfi")))) > + (add-before 'autoconf 'generate-headers > + (lambda _ > + (begin > + (delete-file "include/gtest/gtest-param-test.h") > + (system* "python2" "scripts/pump.py" > + "include/gtest/gtest-param-test.h.pump") > + (delete-file "include/gtest/internal/gtest-tuple.h") > + (system* "python2" "scripts/pump.py" > + "include/gtest//internal/gtest-tuple.h.pump") > + (delete-file > + "include/gtest/internal/gtest-param-util-generated.h") > + (system* > + "python2" "scripts/pump.py" > + "include/gtest/internal/gtest-param-util-generated.h.pum= p") > + (delete-file "include/gtest/internal/gtest-type-util.h") > + (system* "python2" "scripts/pump.py" > + "include/gtest/internal/gtest-type-util.h.pump")= ))) > + (replace 'install > + (lambda _ > + (let ((out (assoc-ref %outputs "out"))) > + (begin > + (install-file "lib/.libs/libgtest_main.a" > + (string-append out "/lib")) > + (install-file "lib/.libs/libgtest.a" > + (string-append out "/lib")) > + (copy-recursively "include" > + (string-append out "/include"))))))))) > + (home-page "https://github.com/google/googletest/") > + (synopsis "Test discovery and XUnit test framework") > + (description "Google Test features an XUnit test framework, automate= d test > +discovery, death tests, assertions, parameterized tests and XML test rep= ort > +generation.") > + (license bsd-3))) > --=20 > 2.7.4 >=20 Patch pushed! --=20 Efraim Flashner =D7=90=D7=A4=D7=A8=D7=99=D7=9D = =D7=A4=D7=9C=D7=A9=D7=A0=D7=A8 GPG key =3D A28B F40C 3E55 1372 662D 14F7 41AA E7DC CA3D 8351 Confidentiality cannot be guaranteed on emails sent or received unencrypted --TakKZr9L6Hm6aLOc Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQIcBAEBCgAGBQJXWbgxAAoJEPTB05F+rO6TAK0P/0zrN/lpt0anzR12lvb4mGmg BjNznrc2oYkNeo+2dxPpNgP8yarFlF+8Wfb1+gxPon9JdRM8vyzTn1T4thdO8RNz 43RJ6xPgygzTyfWsAbUaoboxNq36kpxEeZwE9Ui8nIGKda58i4QqF3k8guqcUgz9 21TAu/Jb687P5DBju3iM+FklhjGyjJdVY9IYMgSCGe1eEv8Grqb/lfih8SfYKDa/ WbK/a5rZ+ftFo6sZzmTGQdQRIN9h3Z2MymRcAsZj56Wl6l7RrN069+1UsnaCwlT4 S3XeLlp4csBX66/CdzxS4y/NP3w833yAzB2ktkfe++vKDHW3RGIh2/vX29+Nr1Xl paKYMcYtpRQa8v+j5nb/9hcbSxJNmcL7bTS+D0uRNihSXQv5749NqjUxPY6qGgWE sJp+QJeioe5CfNeF9Tu/nRdyydsSUNNdY/NLhGkwXkknW2UynIXS8qKgnjVhHNRx KUYZgv+PQQoeGxhRUy6XCo+cl7eEPYyc+ENn/THhBPeS3ZAvAUWo01QkuBt0ToIq 9BOQ46HsqfuWdpAXKpEjKyw8r2rGas3ZGD4gATp4/pZ9eH7EOYVcG08KN9qJOXoj I63gZkCB0vhfoH0DAh1GCZV9KUgZ6BnvMttpexwrrhzHDSf+SYhoxQ1phavtmzDS QfzL+XxQbb9uw2dT798P =RgLM -----END PGP SIGNATURE----- --TakKZr9L6Hm6aLOc--