GNU bug report logs - #38603
[WIP Mercury 0/2] Add Mercury.

Previous Next

Package: guix-patches;

Reported by: Brett Gilio <brettg <at> posteo.net>

Date: Sat, 14 Dec 2019 03:30:02 UTC

Severity: normal

Done: zimoun <zimon.toutoune <at> gmail.com>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 38603 in the body.
You can then email your comments to 38603 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to guix-patches <at> gnu.org:
bug#38603; Package guix-patches. (Sat, 14 Dec 2019 03:30:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Brett Gilio <brettg <at> posteo.net>:
New bug report received and forwarded. Copy sent to guix-patches <at> gnu.org. (Sat, 14 Dec 2019 03:30:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Brett Gilio <brettg <at> posteo.net>
To: guix-patches <at> gnu.org
Subject: [WIP Mercury 0/2] Add Mercury.
Date: Fri, 13 Dec 2019 21:29:33 -0600
[0000-cover-letter.patch (text/x-patch, inline)]
From a6abc5a2d05cba65c652f5834e768ee8cecde5f8 Mon Sep 17 00:00:00 2001
From: Brett Gilio <brettg <at> posteo.net>
Date: Fri, 13 Dec 2019 21:27:49 -0600
Subject: [WIP Mercury 0/2] Add Mercury.

This is an incomplete patch series for adding Mercury to GNU Guix.

I wanted to put it out there now so other people can work on it and I can
keep track of the progress I make on it.

Please send revisions by rerolling n+1.

Brett Gilio (2):
  gnu: Register mercury module.
  gnu: Add mercury.

 gnu/local.mk             |   1 +
 gnu/packages/mercury.scm | 142 +++++++++++++++++++++++++++++++++++++++
 2 files changed, 143 insertions(+)
 create mode 100644 gnu/packages/mercury.scm

-- 
2.24.1





Information forwarded to guix-patches <at> gnu.org:
bug#38603; Package guix-patches. (Sat, 14 Dec 2019 03:32:02 GMT) Full text and rfc822 format available.

Message #8 received at 38603 <at> debbugs.gnu.org (full text, mbox):

From: Brett Gilio <brettg <at> posteo.net>
To: 38603 <at> debbugs.gnu.org
Subject: [WIP Mercury 1/2] gnu: Register mercury module.
Date: Fri, 13 Dec 2019 21:31:27 -0600
[0001-gnu-Register-mercury-module.patch (text/x-patch, inline)]
From f3fc8801c45e62378a62896c6203ce6931f8d53d Mon Sep 17 00:00:00 2001
From: Brett Gilio <brettg <at> posteo.net>
Date: Fri, 13 Dec 2019 21:25:17 -0600
Subject: [WIP Mercury 1/2] gnu: Register mercury module.

* gnu/local.mk (mercury.scm): Register mercury module.
---
 gnu/local.mk | 1 +
 1 file changed, 1 insertion(+)

diff --git a/gnu/local.mk b/gnu/local.mk
index 32b2c141fa..bd2d32da94 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -335,6 +335,7 @@ GNU_SYSTEM_MODULES =				\
   %D%/packages/mc.scm				\
   %D%/packages/mcrypt.scm			\
   %D%/packages/medical.scm			\
+  %D%/packages/mercury.scm			\
   %D%/packages/mes.scm				\
   %D%/packages/messaging.scm			\
   %D%/packages/mingw.scm			\
-- 
2.24.1





Information forwarded to guix-patches <at> gnu.org:
bug#38603; Package guix-patches. (Sat, 14 Dec 2019 03:33:01 GMT) Full text and rfc822 format available.

Message #11 received at 38603 <at> debbugs.gnu.org (full text, mbox):

From: Brett Gilio <brettg <at> posteo.net>
To: 38603 <at> debbugs.gnu.org
Subject: [WIP Mercury 2/2] gnu: Add mercury.
Date: Fri, 13 Dec 2019 21:31:47 -0600
[0002-gnu-Add-mercury.patch (text/x-patch, inline)]
From a6abc5a2d05cba65c652f5834e768ee8cecde5f8 Mon Sep 17 00:00:00 2001
From: Brett Gilio <brettg <at> posteo.net>
Date: Fri, 13 Dec 2019 21:26:15 -0600
Subject: [WIP Mercury 2/2] gnu: Add mercury.

* gnu/packages/mercury.scm (mercury): New variable.
---
 gnu/packages/mercury.scm | 142 +++++++++++++++++++++++++++++++++++++++
 1 file changed, 142 insertions(+)
 create mode 100644 gnu/packages/mercury.scm

diff --git a/gnu/packages/mercury.scm b/gnu/packages/mercury.scm
new file mode 100644
index 0000000000..4db0386852
--- /dev/null
+++ b/gnu/packages/mercury.scm
@@ -0,0 +1,142 @@
+;;; GNU Guix --- Functional package management for GNU
+;;; Copyright © 2019 Brett Gilio <brettg <at> posteo.net>
+;;;
+;;; This file is part of GNU Guix.
+;;;
+;;; GNU Guix is free software; you can redistribute it and/or modify it
+;;; under the terms of the GNU General Public License as published by
+;;; the Free Software Foundation; either version 3 of the License, or (at
+;;; your option) any later version.
+;;;
+;;; GNU Guix is distributed in the hope that it will be useful, but
+;;; WITHOUT ANY WARRANTY; without even the implied warranty of
+;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+;;; GNU General Public License for more details.
+;;;
+;;; You should have received a copy of the GNU General Public License
+;;; along with GNU Guix.  If not, see <http://www.gnu.org/licenses/>.
+
+;; TODO: Not all of these modules are needed.
+(define-module (gnu packages mercury)
+  #:use-module (guix download)
+  #:use-module (guix packages)
+  #:use-module (guix utils)
+  #:use-module ((guix licenses) #:prefix license:)
+  #:use-module (guix build-system gnu)
+  #:use-module (guix build-system cmake)
+  #:use-module (gnu packages bdw-gc)
+  #:use-module (gnu packages compression)
+  #:use-module (gnu packages commencement)
+  #:use-module (gnu packages multiprecision)
+  #:use-module (gnu packages ninja)
+  #:use-module (gnu packages readline)
+  #:use-module (gnu packages tex)
+  #:use-module (gnu packages libunwind)
+  #:use-module (gnu packages image)
+  #:use-module (gnu packages xorg)
+  #:use-module (gnu packages fontutils)
+  #:use-module (gnu packages pkg-config)
+  #:use-module (gnu packages tls)
+  #:use-module (gnu packages perl)
+  #:use-module (gnu packages texinfo)
+  #:use-module (gnu packages flex)
+  #:use-module (gnu packages shells)
+  #:use-module (gnu packages bison)
+  #:use-module (srfi srfi-1)
+  #:use-module (ice-9 match)) ; match-lambda
+
+(define-public mercury
+  (package
+    (name "mercury")
+    (version "14.01.1")
+    (source (origin
+              (method url-fetch)
+              (uri (string-append "https://dl.mercurylang.org/release/mercury-srcdist-"
+                                  version
+                                  ".tar.gz"))
+              (sha256
+               (base32
+                "12z8qi3da8q50mcsjsy5bnr4ia6ny5lkxvzy01a3c9blgbgcpxwq"))))
+    (build-system gnu-build-system)
+    (arguments
+     `(#:imported-modules ((ice-9 match)
+                           ,@%gnu-build-system-modules)
+       #:modules ((ice-9 match)
+                  (guix build gnu-build-system)
+                  (guix build utils)
+                  ,@%gnu-build-system-modules)
+       #:tests? #f ; TODO: tests are cryptic. Figure it out later.
+       #:phases
+       (modify-phases %standard-phases
+         (add-after 'unpack 'patch
+           (lambda _ (substitute*
+                         (list "Makefile"
+                               "Mmakefile"
+                               "scripts/mercury_update_interface.in"
+                               "scripts/mercury_config.in"
+                               "scripts/mmake.in"
+                               "scripts/mmake.sh"
+                               "scripts/Mmake.vars.in"
+                               "scripts/mdb.in"
+                               "scripts/rs6000_hack"
+                               "scripts/fullarch"
+                               "scripts/mmc.in"
+                               "scripts/canonical_grade"
+                               "scripts/mprof.in"
+                               "scripts/gud.el"
+                               "scripts/ml.in"
+                               "scripts/canonical_grade.in"
+                               "scripts/mdprof.in"
+                               "scripts/vpath_find"
+                               "scripts/mkfifo_using_mknod.in"
+                               "scripts/prepare_install_dir.in"
+                               "scripts/ml.sh"
+                               "scripts/mprof_merge_runs"
+                               "scripts/mtc"
+                               "scripts/mgnuc.in"
+                               "scripts/c2init.in"
+                               "bindist/bindist.Makefile")
+                       (("/bin/sh") (which "sh"))
+                       (("/bin/pwd") (which "pwd"))
+                       (("/bin/rm") (which "rm")))))
+         (add-after 'unpack 'replace-boehm
+           (lambda* (#:key inputs #:allow-other-keys)
+             (let ((boehm (assoc-ref inputs "libgc")))
+               (map (match-lambda
+                      ((src orig-name new-name)
+                       (with-directory-excursion "."
+                         (apply unpack (list #:source src))
+                         (apply patch-source-shebangs (list #:source src)))
+                       (delete-file-recursively new-name)
+                       (invoke "mv" orig-name new-name)))
+                    `((,boehm "source" "libgc")))))))))
+    (native-inputs
+     `(("texinfo" ,texinfo)
+       ("flex" ,flex)
+       ("tcsh", tcsh)
+       ("bison" ,bison)
+       ("readline" ,readline)
+       ("libgc" ,libgc)))
+    (synopsis "A pure logic programming language")
+    (description "Mercury is a logic/functional programming language which 
+combines the clarity and expressiveness of declarative programming with advanced
+static analysis and error detection features.  Its highly optimized execution 
+algorithm delivers efficiency far in excess of existing logic programming 
+systems, and close to conventional programming systems. Mercury addresses 
+the problems of large-scale program development, allowing modularity, 
+separate compilation, and numerous optimization/time trade-offs.")
+    (home-page "https://mercurylang.org")
+    (license license:gpl2)))
+
+(define-public mercury-minimal
+  (package (inherit mercury)
+	   (name "mercury-minimal")
+	   (build-system gnu-build-system)
+	   (arguments
+            (substitute-keyword-arguments (package-arguments mercury)
+              ((#:configure-flags flags ''())
+               `(list "--enable-minimal-install"))))
+           (inputs
+            `(("gcc-toolchain" ,gcc-toolchain)))
+           (synopsis "A pure logic programming language (used only for
+compiling packages dependent on base Mercury)")))
-- 
2.24.1





Information forwarded to guix-patches <at> gnu.org:
bug#38603; Package guix-patches. (Mon, 06 Jan 2020 23:58:01 GMT) Full text and rfc822 format available.

Message #14 received at 38603 <at> debbugs.gnu.org (full text, mbox):

From: Brett Gilio <brettg <at> gnu.org>
To: 38603 <at> debbugs.gnu.org
Subject: [WIP v2 0/1] Add mercury.
Date: Mon, 06 Jan 2020 17:57:17 -0600
[v2-0000-cover-letter.patch (text/x-patch, inline)]
From 1a78e1b20f015f2f7297eb17becb7b740a991fd5 Mon Sep 17 00:00:00 2001
From: Brett Gilio <brettg <at> gnu.org>
Date: Mon, 6 Jan 2020 17:52:27 -0600
Subject: [WIP v2 0/1] Add mercury.
To: guix-patches <at> gnu.org

This is a revision of the first patch series. The first patch series
is effectively without use as this method contains everything into a
single patch.

This package still requires some work on getting the Boehm `libgc` package
replacement to work just right (or maybe just do a recursive checkout of the
submodule from Git? Though that seems less Guixy), as well as getting the grades
just right (should Java be added in the default package, or split out into a
mercury-grade-java package with some load_path magic?), and getting the test
cases to work.

Mercury is truly a giant and monolithic project, so I would not mind some help!

If you aren't familiar with Mercury, checkout http://mercurylang.org/.

Thanks!

Brett Gilio (1):
  gnu: Add mercury.

 gnu/local.mk             |   3 +-
 gnu/packages/mercury.scm | 157 +++++++++++++++++++++++++++++++++++++++
 2 files changed, 159 insertions(+), 1 deletion(-)
 create mode 100644 gnu/packages/mercury.scm

-- 
2.24.1





Information forwarded to guix-patches <at> gnu.org:
bug#38603; Package guix-patches. (Mon, 06 Jan 2020 23:58:02 GMT) Full text and rfc822 format available.

Message #17 received at 38603 <at> debbugs.gnu.org (full text, mbox):

From: Brett Gilio <brettg <at> gnu.org>
To: 38603 <at> debbugs.gnu.org
Subject: [WIP v2 1/1] gnu: Add mercury.
Date: Mon, 06 Jan 2020 17:57:35 -0600
[v2-0001-gnu-Add-mercury.patch (text/x-patch, inline)]
From 1a78e1b20f015f2f7297eb17becb7b740a991fd5 Mon Sep 17 00:00:00 2001
From: Brett Gilio <brettg <at> gnu.org>
Date: Mon, 6 Jan 2020 17:51:29 -0600
Subject: [WIP v2 1/1] gnu: Add mercury.
To: guix-patches <at> gnu.org

* gnu/local.mk (GNU_SYSTEM_MODULES): Add mercury.scm
* gnu/packages/mercury.scm: New file.
---
 gnu/local.mk             |   3 +-
 gnu/packages/mercury.scm | 157 +++++++++++++++++++++++++++++++++++++++
 2 files changed, 159 insertions(+), 1 deletion(-)
 create mode 100644 gnu/packages/mercury.scm

diff --git a/gnu/local.mk b/gnu/local.mk
index b7fa503257..e488424056 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -24,7 +24,7 @@
 # Copyright © 2019 John Soo <jsoo1 <at> asu.edu>
 # Copyright © 2019 Jonathan Brielmaier <jonathan.brielmaier <at> web.de>
 # Copyright © 2019 Evan Straw <evan.straw99 <at> gmail.com>
-# Copyright © 2019 Brett Gilio <brettg <at> gnu.org>
+# Copyright © 2019, 2020 Brett Gilio <brettg <at> gnu.org>
 # Copyright © 2019 Amin Bandali <bandali <at> gnu.org>
 #
 # This file is part of GNU Guix.
@@ -340,6 +340,7 @@ GNU_SYSTEM_MODULES =				\
   %D%/packages/mc.scm				\
   %D%/packages/mcrypt.scm			\
   %D%/packages/medical.scm			\
+  %D%/packages/mercury.scm			\
   %D%/packages/mes.scm				\
   %D%/packages/messaging.scm			\
   %D%/packages/mingw.scm			\
diff --git a/gnu/packages/mercury.scm b/gnu/packages/mercury.scm
new file mode 100644
index 0000000000..f3c0bc9fa7
--- /dev/null
+++ b/gnu/packages/mercury.scm
@@ -0,0 +1,157 @@
+;;; GNU Guix --- Functional package management for GNU
+;;; Copyright © 2020 Brett Gilio <brettg <at> posteo.net>
+;;;
+;;; This file is part of GNU Guix.
+;;;
+;;; GNU Guix is free software; you can redistribute it and/or modify it
+;;; under the terms of the GNU General Public License as published by
+;;; the Free Software Foundation; either version 3 of the License, or (at
+;;; your option) any later version.
+;;;
+;;; GNU Guix is distributed in the hope that it will be useful, but
+;;; WITHOUT ANY WARRANTY; without even the implied warranty of
+;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+;;; GNU General Public License for more details.
+;;;
+;;; You should have received a copy of the GNU General Public License
+;;; along with GNU Guix.  If not, see <http://www.gnu.org/licenses/>.
+
+(define-module (gnu packages mercury)
+  #:use-module (guix download)
+  #:use-module (guix git-download)
+  #:use-module (guix packages)
+  #:use-module (guix utils)
+  #:use-module ((guix licenses) #:prefix license:)
+  #:use-module (guix build-system gnu)
+  #:use-module (gnu packages autotools)
+  #:use-module (gnu packages bdw-gc)
+  #:use-module (gnu packages readline)
+  #:use-module (gnu packages texinfo)
+  #:use-module (gnu packages flex)
+  #:use-module (gnu packages shells)
+  #:use-module (gnu packages bison)
+  #:use-module (gnu packages pkg-config)
+  #:use-module (ice-9 match)) ; match-lambda
+
+;; NOTE: Package `mercury` requires a specific revision and fork of
+;; upstream Boehm `libgc`. We use this method to obtain that fork
+;; and patch it into `mercury` manually.
+(define (bdwgc-mercury commit-bdwgc hash)
+  (let ((commit commit-bdwgc))
+    (package (inherit libgc)
+             (source
+              (origin
+                (method git-fetch)
+                (uri (git-reference
+                      (url "https://github.com/Mercury-Language/bdwgc.git")
+                      (commit commit)))
+                (sha256 (base32 hash))))
+             (native-inputs
+              `(("autoconf" ,autoconf)
+                ("automake" ,automake)
+                ("libtool" ,libtool)
+                ,@(package-native-inputs libgc))))))
+
+(define-public mercury
+  (package
+    (name "mercury")
+    (version "14.01.1")
+    (source (origin
+              (method url-fetch)
+              (uri (string-append
+                    "https://dl.mercurylang.org/release/mercury-srcdist-"
+                    version ".tar.gz"))
+              (sha256
+               (base32
+                "12z8qi3da8q50mcsjsy5bnr4ia6ny5lkxvzy01a3c9blgbgcpxwq"))))
+    (build-system gnu-build-system)
+    (arguments
+     `(#:modules ((guix build gnu-build-system)
+                  (guix build utils)
+                  (ice-9 match))
+       #:tests? #f ; TODO: tests are cryptic. Figure it out later.
+       #:phases
+       (modify-phases %standard-phases
+         (add-after 'unpack 'patch
+           (lambda _
+             (substitute*
+                 (list "Makefile"
+                       "Mmakefile"
+                       "scripts/mercury_update_interface.in"
+                       "scripts/mercury_config.in"
+                       "scripts/mmake.in"
+                       "scripts/mmake.sh"
+                       "scripts/Mmake.vars.in"
+                       "scripts/mdb.in"
+                       "scripts/rs6000_hack"
+                       "scripts/fullarch"
+                       "scripts/mmc.in"
+                       "scripts/canonical_grade"
+                       "scripts/mprof.in"
+                       "scripts/gud.el"
+                       "scripts/ml.in"
+                       "scripts/canonical_grade.in"
+                       "scripts/mdprof.in"
+                       "scripts/vpath_find"
+                       "scripts/mkfifo_using_mknod.in"
+                       "scripts/prepare_install_dir.in"
+                       "scripts/ml.sh"
+                       "scripts/mprof_merge_runs"
+                       "scripts/mtc"
+                       "scripts/mgnuc.in"
+                       "scripts/c2init.in"
+                       "bindist/bindist.Makefile")
+               (("/bin/sh") (which "sh"))
+               (("/bin/pwd") (which "pwd"))
+               (("/bin/rm") (which "rm")))
+             #t))
+         (add-after 'unpack 'replace-boehm-gc
+           (lambda* (#:key inputs outputs #:allow-other-keys)
+             (let ((out (assoc-ref outputs "out"))
+                   (libgc (assoc-ref inputs "libgc"))
+                   (unpack (assoc-ref %standard-phases 'unpack))
+                   (patch-source-shebangs
+                    (assoc-ref %standard-phases 'patch-source-shebangs)))
+               (map (match-lambda
+                      ((src orig-name new-name)
+                       (with-directory-excursion "."
+                         (apply unpack (list #:source src))
+                         (apply patch-source-shebangs (list #:source src)))
+                       (delete-file-recursively new-name)
+                       (invoke "mv" orig-name new-name)))
+                    `((,libgc "source/include/gc" "boehm_gc"))))
+             #t)))))
+    (native-inputs
+     `(("texinfo" ,texinfo)
+       ("flex" ,flex)
+       ("tcsh", tcsh)
+       ("bison" ,bison)
+       ("readline" ,readline)
+       ("libatomic-ops" ,libatomic-ops)
+       ("libgc" ,(bdwgc-mercury
+                  "5287fbab8a6f2284a12beeb9e3ba592301436b98"
+                  "1crlw7zhjik39qdfqp5w317dskxdrklfw48g4jzrjzry12hkmq9y"))
+       ("pkg-config" ,pkg-config)))
+    (synopsis "A pure logic programming language")
+    (description "Mercury is a logic/functional programming language which 
+combines the clarity and expressiveness of declarative programming with advanced
+static analysis and error detection features.  Its highly optimized execution 
+algorithm delivers efficiency far in excess of existing logic programming 
+systems, and close to conventional programming systems. Mercury addresses 
+the problems of large-scale program development, allowing modularity, 
+separate compilation, and numerous optimization/time trade-offs.")
+    (home-page "https://mercurylang.org")
+    (license license:gpl2)))
+
+(define-public mercury-minimal
+  (package (inherit mercury)
+	   (name "mercury-minimal")
+	   (build-system gnu-build-system)
+	   (arguments
+            (substitute-keyword-arguments (package-arguments mercury)
+              ((#:configure-flags flags ''())
+               `(list "--enable-minimal-install"))))
+           (inputs
+            `(("gcc-toolchain" ,gcc-toolchain)))
+           (synopsis "A pure logic programming language (used only for
+compiling packages dependent on base Mercury)")))
-- 
2.24.1





Information forwarded to guix-patches <at> gnu.org:
bug#38603; Package guix-patches. (Thu, 23 Jul 2020 18:35:02 GMT) Full text and rfc822 format available.

Message #20 received at 38603 <at> debbugs.gnu.org (full text, mbox):

From: Tobias Geerinckx-Rice <me <at> tobias.gr>
To: Brett Gilio <brettg <at> gnu.org>
Cc: 38603 <at> debbugs.gnu.org
Subject: Re: branch master updated: gnu: Add mercury.
Date: Thu, 23 Jul 2020 20:34:29 +0200
[Message part 1 (text/plain, inline)]
Hi Brett,

guix-commits <at> gnu.org 写道:
> commit 7235ce224e3d20b5f73474cac2d3b34b50d754a5
> Author: Brett Gilio <brettg <at> gnu.org>
> AuthorDate: Thu Jul 23 12:13:59 2020 -0500
>
>     gnu: Add mercury.
>     
>     * gnu/local.mk (GNU_SYSTEM_MODULES): Add mercury.scm.
>     * gnu/packages/mercury.scm: New file.

Thanks!  I'd close the bug but I'm unable to get past 
mercury-minimal[0].  I suppose it's a permissions issue: the files 
in question are -r--r--r--.

> +              ((#:configure-flags flags ''())
> +               `(list ""))

Is this a weird work-around for something?  If so, please add a 
comment.  If not, remove the "".

(‘flags’ could be ‘_’ as in

> +              ((#:tests? _) #f) ; FIXME: Many test-cases 
> failing.

but that will change the hash.)

Kind regards,

T G-R

[0]: https://www.tobias.gr/mercury-minimal.log.txt, extract:
[…]
cp: cannot create regular file 
'/tmp/guix-build-mercury-minimal-20.06.drv-0/mercury-srcdist-20.06/install_grade_dir.asm_fast.gc/boehm_gc/thread_local_alloc.c': 
Permission denied
cp: cannot create regular file 
'/tmp/guix-build-mercury-minimal-20.06.drv-0/mercury-srcdist-20.06/install_grade_dir.asm_fast.gc/boehm_gc/typd_mlc.c': 
Permission denied
cp: cannot create regular file 
'/tmp/guix-build-mercury-minimal-20.06.drv-0/mercury-srcdist-20.06/install_grade_dir.asm_fast.gc/boehm_gc/win32_threads.c': 
Permission denied
make[2]: Entering directory 
'/tmp/guix-build-mercury-minimal-20.06.drv-0/mercury-srcdist-20.06/install_grade_dir.asm_fast.gc/boehm_gc'
cp Makefile.direct Makefile
cp: cannot create regular file 'Makefile': Permission denied
make[2]: *** 
[/tmp/guix-build-mercury-minimal-20.06.drv-0/mmake.SW2BFY:861: 
Makefile] Error 1
make[2]: Leaving directory 
'/tmp/guix-build-mercury-minimal-20.06.drv-0/mercury-srcdist-20.06/install_grade_dir.asm_fast.gc/boehm_gc'
To clean up from failed install, remove 
/tmp/guix-build-mercury-minimal-20.06.drv-0/mercury-srcdist-20.06/install_grade_dir.asm_fast.gc
make[1]: *** 
[/tmp/guix-build-mercury-minimal-20.06.drv-0/mmake.x8C0kk:1457: 
install_grades] Error 1
make[1]: Leaving directory 
'/tmp/guix-build-mercury-minimal-20.06.drv-0/mercury-srcdist-20.06'
make: *** [Makefile:34: install] Error 2
command "make" "install" failed with status 2
[signature.asc (application/pgp-signature, inline)]

Information forwarded to guix-patches <at> gnu.org:
bug#38603; Package guix-patches. (Thu, 23 Jul 2020 21:27:02 GMT) Full text and rfc822 format available.

Message #23 received at submit <at> debbugs.gnu.org (full text, mbox):

From: brettg <at> posteo.net
To: Tobias Geerinckx-Rice <me <at> tobias.gr>, Tobias Geerinckx-Rice via
 Guix-patches <guix-patches <at> gnu.org>
Cc: 38603 <at> debbugs.gnu.org, Brett Gilio <brettg <at> gnu.org>,
 Guix-patches <guix-patches-bounces+brettg=posteo.net <at> gnu.org>
Subject: Re: [bug#38603] branch master updated: gnu: Add mercury.
Date: Thu, 23 Jul 2020 23:26:18 +0200
On 23.07.2020 20:34, Tobias Geerinckx-Rice via Guix-patches via wrote:
> Hi Brett,
> 
> guix-commits <at> gnu.org 写道:
>> commit 7235ce224e3d20b5f73474cac2d3b34b50d754a5
>> Author: Brett Gilio <brettg <at> gnu.org>
>> AuthorDate: Thu Jul 23 12:13:59 2020 -0500
>> 
>>     gnu: Add mercury.
>>         * gnu/local.mk (GNU_SYSTEM_MODULES): Add mercury.scm.
>>     * gnu/packages/mercury.scm: New file.
> 
> Thanks!  I'd close the bug but I'm unable to get past
> mercury-minimal[0].  I suppose it's a permissions issue: the files in
> question are -r--r--r--.
> 
>> +              ((#:configure-flags flags ''())
>> +               `(list ""))
> 
> Is this a weird work-around for something?  If so, please add a
> comment.  If not, remove the "".
> 
> (‘flags’ could be ‘_’ as in
> 
>> +              ((#:tests? _) #f) ; FIXME: Many test-cases failing.
> 
> but that will change the hash.)
> 
> Kind regards,
> 
> T G-R


Hi Tobias, Thank you for telling me. I thought I had gotten the 
conditions just right, at least for the
mercury-minimal compiler, but it seems there is more work to be done! 
Yes, leave this bug open
and I will investigate. I am trying my best to keep the changes 
contained and well tested to my
computers to prevent over-working the build server, so I appreciate 
patience as mercury is turning
out to be somewhat convoluted. :)

If others are following the progress here, please feel free to post 
suggestions and patches. I will
have to investigate this probably tomorrow or over the weekend.

Brett Gilio




Information forwarded to guix-patches <at> gnu.org:
bug#38603; Package guix-patches. (Thu, 23 Jul 2020 21:27:02 GMT) Full text and rfc822 format available.

Information forwarded to guix-patches <at> gnu.org:
bug#38603; Package guix-patches. (Thu, 23 Jul 2020 22:21:02 GMT) Full text and rfc822 format available.

Message #29 received at 38603 <at> debbugs.gnu.org (full text, mbox):

From: brettg <at> posteo.net
To: Tobias Geerinckx-Rice <me <at> tobias.gr>
Cc: 38603 <at> debbugs.gnu.org, Brett Gilio <brettg <at> gnu.org>
Subject: Re: branch master updated: gnu: Add mercury.
Date: Fri, 24 Jul 2020 00:20:45 +0200
> […]
> cp: cannot create regular file
> '/tmp/guix-build-mercury-minimal-20.06.drv-0/mercury-srcdist-20.06/install_grade_dir.asm_fast.gc/boehm_gc/thread_local_alloc.c':
> Permission denied
> cp: cannot create regular file
> '/tmp/guix-build-mercury-minimal-20.06.drv-0/mercury-srcdist-20.06/install_grade_dir.asm_fast.gc/boehm_gc/typd_mlc.c':
> Permission denied
> cp: cannot create regular file
> '/tmp/guix-build-mercury-minimal-20.06.drv-0/mercury-srcdist-20.06/install_grade_dir.asm_fast.gc/boehm_gc/win32_threads.c':
> Permission denied
> make[2]: Entering directory
> '/tmp/guix-build-mercury-minimal-20.06.drv-0/mercury-srcdist-20.06/install_grade_dir.asm_fast.gc/boehm_gc'
> cp Makefile.direct Makefile
> cp: cannot create regular file 'Makefile': Permission denied
> make[2]: ***
> [/tmp/guix-build-mercury-minimal-20.06.drv-0/mmake.SW2BFY:861:
> Makefile] Error 1
> make[2]: Leaving directory
> '/tmp/guix-build-mercury-minimal-20.06.drv-0/mercury-srcdist-20.06/install_grade_dir.asm_fast.gc/boehm_gc'
> To clean up from failed install, remove
> /tmp/guix-build-mercury-minimal-20.06.drv-0/mercury-srcdist-20.06/install_grade_dir.asm_fast.gc
> make[1]: ***
> [/tmp/guix-build-mercury-minimal-20.06.drv-0/mmake.x8C0kk:1457:
> install_grades] Error 1
> make[1]: Leaving directory
> '/tmp/guix-build-mercury-minimal-20.06.drv-0/mercury-srcdist-20.06'
> make: *** [Makefile:34: install] Error 2
> command "make" "install" failed with status 2

On further investigation I can not reproduce this issue. Tobias, what 
architecture are you working from,
and what I am assuming this failed during the install phase?

I would like to hear from others if mercury-minimal is causing issues 
for anybody else. I will still
investigate, but just letting it run in the background on my end the 
build for mercury-minimal
went to completion just fine. Clearly there is a reproducibility issue 
at play here probably with
the configure phase which generates the several files and is perhaps 
being inconsistent with
how permissions are being established.

Overall, mercury and mercury-minimal need a lot of work to reduce the 
size, get grades right,
and maybe get the grades split out into different outputs.

Brett Gilio




Information forwarded to guix-patches <at> gnu.org:
bug#38603; Package guix-patches. (Fri, 24 Jul 2020 08:04:02 GMT) Full text and rfc822 format available.

Message #32 received at 38603 <at> debbugs.gnu.org (full text, mbox):

From: Tobias Geerinckx-Rice <me <at> tobias.gr>
To: brettg <at> posteo.net
Cc: 38603 <at> debbugs.gnu.org, Brett Gilio <brettg <at> gnu.org>
Subject: Re: branch master updated: gnu: Add mercury.
Date: Fri, 24 Jul 2020 10:03:50 +0200
[Message part 1 (text/plain, inline)]
Brett,

brettg <at> posteo.net 写道:
> On further investigation I can not reproduce this issue. Tobias, 
> what
> architecture are you working from,

World's most boring x86_64 box with plenty of free space.  I'll 
try it on my laptop.

> and what I am assuming this failed during the install phase?

Yep!

Kind regards,

T G-R
[signature.asc (application/pgp-signature, inline)]

Information forwarded to guix-patches <at> gnu.org:
bug#38603; Package guix-patches. (Fri, 24 Jul 2020 19:39:02 GMT) Full text and rfc822 format available.

Message #35 received at 38603 <at> debbugs.gnu.org (full text, mbox):

From: Brett Gilio <brettg <at> gnu.org>
To: Tobias Geerinckx-Rice <me <at> tobias.gr>
Cc: 38603 <at> debbugs.gnu.org, brettg <at> posteo.net
Subject: Re: branch master updated: gnu: Add mercury.
Date: Fri, 24 Jul 2020 14:37:25 -0500
Tobias Geerinckx-Rice <me <at> tobias.gr> writes:
>
> World's most boring x86_64 box with plenty of free space.  I'll try it
> on my laptop.
>

I am having some peers with Guix installed attempt the build using a
standard commit on the time-machine. So far I have not received any
notice of the failure. Have you gotten a result from your laptop yet?

Thanks for your help!
Brett




Information forwarded to guix-patches <at> gnu.org:
bug#38603; Package guix-patches. (Sat, 25 Jul 2020 09:45:03 GMT) Full text and rfc822 format available.

Message #38 received at 38603 <at> debbugs.gnu.org (full text, mbox):

From: Alexandru-Sergiu Marton <brown121407 <at> posteo.ro>
To: Brett Gilio <brettg <at> gnu.org>
Cc: 38603 <at> debbugs.gnu.org, Tobias Geerinckx-Rice <me <at> tobias.gr>
Subject: Re: [bug#38603] branch master updated: gnu: Add mercury.
Date: Sat, 25 Jul 2020 09:33:11 +0300
[Message part 1 (text/plain, inline)]
Hi all,

I tried to build this too and I had no problems. I used:

  guix time-machine -- build mercury

I attached the build log in case anyone might want to look through it.

Cheers,
Sergiu

[mercury.txt (text/plain, attachment)]

Reply sent to zimoun <zimon.toutoune <at> gmail.com>:
You have taken responsibility. (Tue, 12 Apr 2022 10:37:02 GMT) Full text and rfc822 format available.

Notification sent to Brett Gilio <brettg <at> posteo.net>:
bug acknowledged by developer. (Tue, 12 Apr 2022 10:37:02 GMT) Full text and rfc822 format available.

Message #43 received at 38603-done <at> debbugs.gnu.org (full text, mbox):

From: zimoun <zimon.toutoune <at> gmail.com>
To: Brett Gilio <brettg <at> gnu.org>
Cc: 38603-done <at> debbugs.gnu.org
Subject: Re: bug#38603: [WIP Mercury 0/2] Add Mercury.
Date: Tue, 12 Apr 2022 12:30:32 +0200
Hi,

On Mon, 06 Jan 2020 at 17:57, Brett Gilio <brettg <at> gnu.org> wrote:

[...]

> +(define-public mercury
> +  (package
> +    (name "mercury")
> +    (version "14.01.1")
> +    (source (origin
> +              (method url-fetch)
> +              (uri (string-append
> +                    "https://dl.mercurylang.org/release/mercury-srcdist-"
> +                    version ".tar.gz"))

--8<---------------cut here---------------start------------->8---
8b928a3931cafddb291152bc259b634ab3ab441b
Author:     Brett Gilio <brettg <at> gnu.org>
AuthorDate: Wed Nov 25 16:40:29 2020 -0600
Commit:     Brett Gilio <brettg <at> gnu.org>
CommitDate: Wed Nov 25 16:40:29 2020 -0600

gnu: mercury: Update to 20.06.1.

* gnu/packages/mercury.scm (mercury): Update to 20.06.1.
--8<---------------cut here---------------end--------------->8---


Closing!


Cheers,
simon




bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Tue, 10 May 2022 11:24:03 GMT) Full text and rfc822 format available.

This bug report was last modified 1 year and 345 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.