From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:38672) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1f4RZA-0004Fl-GO for guix-patches@gnu.org; Fri, 06 Apr 2018 09:38:09 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1f4RZ4-0007wr-Ap for guix-patches@gnu.org; Fri, 06 Apr 2018 09:38:08 -0400 Received: from debbugs.gnu.org ([208.118.235.43]:60294) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1f4RZ4-0007wY-6A for guix-patches@gnu.org; Fri, 06 Apr 2018 09:38:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1f4RZ3-00087k-TA for guix-patches@gnu.org; Fri, 06 Apr 2018 09:38:01 -0400 Subject: [bug#31077] [PATCH] gnu: libfive: Add snippet, enable tests and remove obsolete phase. Resent-Message-ID: Received: from eggs.gnu.org ([2001:4830:134:3::10]:37684) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1f4RXy-0003Mc-NJ for guix-patches@gnu.org; Fri, 06 Apr 2018 09:36:56 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1f4RXv-0006xZ-G4 for guix-patches@gnu.org; Fri, 06 Apr 2018 09:36:54 -0400 Received: from mout01.posteo.de ([185.67.36.65]:52789) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1f4RXv-0006uF-0d for guix-patches@gnu.org; Fri, 06 Apr 2018 09:36:51 -0400 Received: from submission (posteo.de [89.146.220.130]) by mout01.posteo.de (Postfix) with ESMTPS id E2530212BD for ; Fri, 6 Apr 2018 15:36:42 +0200 (CEST) Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 40Hghp1bG7z9rxG for ; Fri, 6 Apr 2018 15:36:42 +0200 (CEST) From: Diego Nicola Barbato Date: Fri, 06 Apr 2018 15:36:41 +0200 Message-ID: <877epkjw2e.fsf@GlaDOS.home> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+kyle=kyleam.com@gnu.org Sender: "Guix-patches" To: 31077@debbugs.gnu.org --=-=-= Content-Type: text/plain Hello Guix I have noticed that the package "ao-cad" has been updated and renamed to "libfive" recently (commit: 28f4d56dd311a3b4c7102394120de05be6937494). I have been working on the same thing for a while but I got stuck when trying to figure out how to correctly install the Guile library so that it could be used as described in the libfive documentation (https://github.com/libfive/libfive/blob/9d857d1923abecb0e5935b9287d22661f6efaac5/doc/guide.md) by running (load-extension "libfive-guile" "scm_init_libfive_modules") in a Guile REPL. I also thought about installing it in such a way that it could be loaded with (use-modules (libfive)). AFAICT this has not been addressed yet so I will continue working on it. The updated package definition is very similar to what I have written so far except for some minor differences. Among these are a snippet which removes the bundled catch.hpp file from the libfive/test directory and the fact that I did not disable the tests. Additionally I removed a phase which does not seem to be necessary as the package is still built and installed correctly without it. This patch adds those changes. Greetings Diego --=-=-= Content-Type: text/x-patch Content-Disposition: attachment; filename=0001-gnu-libfive-Add-snippet-enable-tests-and-remove-obso.patch Content-Description: Patch >From 402b75db39ec6778862a5a301cd6a6f520608c60 Mon Sep 17 00:00:00 2001 From: Diego Nicola Barbato Date: Fri, 6 Apr 2018 13:43:54 +0200 Subject: [PATCH] gnu: libfive: Add snippet, enable tests and remove obsolete phase. * gnu/packages/engineering.scm (libfive)[source]: Add snippet to remove bundled catch. [arguments]: Remove #:tests?. Add #:test-target. Remove phase 'add-eigen-to-search-path'. --- gnu/packages/engineering.scm | 17 ++++++----------- 1 file changed, 6 insertions(+), 11 deletions(-) diff --git a/gnu/packages/engineering.scm b/gnu/packages/engineering.scm index 1113cafec..2f4e8cef5 100644 --- a/gnu/packages/engineering.scm +++ b/gnu/packages/engineering.scm @@ -580,24 +580,19 @@ as well as pick-place files.") (sha256 (base32 "1r40kyx30wz31cwwlfvfh7fgqkxq3n8dxhswpi9qpf4r5h3l8wsn")) - (file-name (git-file-name name version)))) + (file-name (git-file-name name version)) + (snippet + ;; Remove bundled catch since we provide our own. + '(delete-file "libfive/test/catch.hpp")))) (build-system cmake-build-system) (arguments - `(#:tests? #f ; no "test" target + `(#:test-target "libfive-test" #:phases (modify-phases %standard-phases (add-after 'unpack 'remove-native-compilation (lambda _ (substitute* "CMakeLists.txt" (("-march=native") "")) - #t)) - (add-before 'build 'add-eigen-to-search-path - (lambda* (#:key inputs #:allow-other-keys) - ;; Allow things to find our own Eigen and Catch. - (let ((eigen (assoc-ref inputs "eigen"))) - (setenv "CPLUS_INCLUDE_PATH" - (string-append eigen "/include/eigen3:" - (getenv "CPLUS_INCLUDE_PATH"))) - #t)))))) + #t))))) (native-inputs `(("pkg-config" ,pkg-config))) (inputs -- 2.17.0 --=-=-=--