From mboxrd@z Thu Jan 1 00:00:00 1970 From: Lukas Gradl Subject: Re: [PATCH] Add googletest Date: Wed, 01 Jun 2016 09:57:53 -0500 Message-ID: <87twhdez33.fsf@openmailbox.org> References: <874m9fwa0k.fsf@openmailbox.org> <87lh2q2v1u.fsf@openmailbox.org> <20160531214400.GA22303@jasmine> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:51916) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b87ax-0001yQ-Kd for guix-devel@gnu.org; Wed, 01 Jun 2016 10:58:08 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1b87at-0008CD-DQ for guix-devel@gnu.org; Wed, 01 Jun 2016 10:58:06 -0400 Received: from mail2.openmailbox.org ([62.4.1.33]:44413) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b87at-0008C3-1x for guix-devel@gnu.org; Wed, 01 Jun 2016 10:58:03 -0400 In-Reply-To: <20160531214400.GA22303@jasmine> (Leo Famulari's message of "Tue, 31 May 2016 17:44:00 -0400") 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: Leo Famulari Cc: guix-devel@gnu.org Thank you for your review! Leo Famulari writes: > On Tue, May 31, 2016 at 08:53:17AM -0500, Lukas Gradl wrote: >> * gnu/packages/check.scm (googletest): New variable. > > Awesome, thanks for this patch! > >> + (build-system cmake-build-system) > > I noticed in the README.md that upstream suggests use of GNU Make unless > building from a Git checkout. Did you try that? I have not tried that. Their README.md left me under the impression that tests are not supported useing GNU Make, but I just looked at their Makefile and there are test targets, so I can try using the gnu-build-system, if that is preferred? > >> + (native-inputs >> + `(("python-2" ,python-2))) > > The README also suggests that this is only necessary for building from > Git, although it's worth finding out what they mean by "re-generating > certain source files from templates". We prefer to re-build "generated" > source files since they are not really "source files" in many cases. > It seems they generate c++ header files using pump.py. I will look into that more. Python is also needed for tests. >> + (replace 'install >> + (lambda _ >> + (let ((out (assoc-ref %outputs "out"))) >> + (and >> + (mkdir-p (string-append out "/lib")) >> + (mkdir-p (string-append out "/include")) >> + (zero? >> + (system* "cp" "-r" >> + "../googletest-release-1.7.0/include" >> + out)) >> + (zero? (system* "cp" "libgtest.a" "libgtest_main.a" >> + (string-append out "/lib")))))))))) > > I think these uses of (system*) could be replaced by (copy-recursively) > and (install-file), respectively. These indeed sound very useful. I will send an updated patch shortly. Thank you! Best, Lukas