unofficial mirror of bug-guix@gnu.org 
 help / color / mirror / code / Atom feed
From: "Philip Munksgaard" <philip@munksgaard.me>
To: 53655@debbugs.gnu.org
Subject: bug#53655: haskell build system cannot build attoparsec
Date: Mon, 31 Jan 2022 11:33:45 +0100	[thread overview]
Message-ID: <a9871314-33e8-474e-b2ec-854a5c740bfb@www.fastmail.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 4270 bytes --]

I'm trying to build a newer version of attoparsec than the one included in guix, namely version 0.14.4.

First of all, `guix import hackage -r attoparsec` fails, as far as I can tell because of the requirement to attoparsec-internal, with the following error:

```
$ guix import hackage -r attoparsec

Starting download of /tmp/guix-file.szLCRk
From https://hackage.haskell.org/package/attoparsec/attoparsec-0.14.4.tar.gz...
 ….14.4.tar.gz  157KiB                5.1MiB/s 00:00 [##################] 100.0%
Backtrace:
           7 (primitive-load "/home/munksgaard/.config/guix/current/…")
In guix/ui.scm:
   2209:7  6 (run-guix . _)
  2172:10  5 (run-guix-command _ . _)
In guix/scripts/import.scm:
   124:11  4 (guix-import . _)
In guix/scripts/import/hackage.scm:
   129:26  3 (guix-import-hackage . _)
In guix/import/utils.scm:
   504:23  2 (recursive-import _ #:repo->guix-package _ #:guix-name _ …)
In srfi/srfi-1.scm:
   586:17  1 (map1 (("attoparsec-internal" #f)))
In guix/import/utils.scm:
   492:33  0 (lookup-node "attoparsec-internal" #f)

guix/import/utils.scm:492:33: In procedure lookup-node:
Wrong number of values returned to continuation (expected 2)
```

`guix import hackage attoparsec` succeeds, but I have to manually remove the dependency on attoparsec-internal, resulting in this file:

```
(define-module (gnu packages futhark)
  #:use-module (guix packages)
  #:use-module (guix download)
  #:use-module (guix build-system haskell)
  #:use-module (guix licenses)
  #:use-module (guix git-download)
  #:use-module ((guix licenses) #:prefix license:)
  #:use-module (gnu packages)
  #:use-module (gnu packages haskell)
  #:use-module (gnu packages haskell)
  #:use-module (gnu packages haskell-web)
  #:use-module (gnu packages haskell-xyz)
  #:use-module (gnu packages haskell-check)
  #:use-module (gnu packages haskell-crypto))

(package
  (name "ghc-attoparsec")
  (version "0.14.4")
  (source
    (origin
      (method url-fetch)
      (uri (hackage-uri "attoparsec" version))
      (sha256
        (base32 "0v4yjz4qi8bwhbyavqxlhsfb1iv07v10gxi64khmsmi4hvjpycrz"))))
  (build-system haskell-build-system)
  (inputs (list ghc-scientific))
  (native-inputs
    (list ghc-quickcheck
          ghc-quickcheck-unicode
          ghc-tasty
          ghc-tasty-quickcheck
          ghc-vector))
  (arguments
    `(#:cabal-revision
      ("1" "149ihklmwnl13mmixq6iq5gzggkgqwsqrjlg2fshqwwbvbd4nn3r")))
  (home-page "https://github.com/bgamari/attoparsec")
  (synopsis "Fast combinator parsing for bytestrings and text")
  (description
    "This package provides a fast parser combinator library, aimed particularly at
dealing efficiently with network protocols and complicated text/binary file
formats.")
  (license license:bsd-3))
```

When trying to build this file however, I get the following error:

```
running "runhaskell Setup.hs" with command "register" and parameters ("--gen-pkg-config=/gnu/store/25ql0xsjqf0alrvy6hmpw6gzirzbqfmv-ghc-attoparsec-0.14.4/ghc-attoparsec-0.14.4.conf")
error: in phase 'register': uncaught exception:
system-error "fport_read" "~A" ("Is a directory") (21)
phase `register' failed after 0.5 seconds
Backtrace:
          11 (primitive-load "/gnu/store/01ry4yp98silvy0mfwgn8c77fxz…")
In guix/build/gnu-build-system.scm:
    906:2 10 (gnu-build #:source _ #:outputs _ #:inputs _ #:phases . #)
In ice-9/boot-9.scm:
  1752:10  9 (with-exception-handler _ _ #:unwind? _ # _)
In srfi/srfi-1.scm:
    634:9  8 (for-each #<procedure 7ffff404a920 at guix/build/gnu-b…> …)
In ice-9/boot-9.scm:
  1752:10  7 (with-exception-handler _ _ #:unwind? _ # _)
In guix/build/gnu-build-system.scm:
   927:23  6 (_)
In guix/build/haskell-build-system.scm:
   244:23  5 (register #:name _ #:system _ #:inputs _ #:outputs _)
In ice-9/ports.scm:
   433:17  4 (call-with-input-file _ _ #:binary _ #:encoding _ # _)
In ice-9/rdelim.scm:
   160:18  3 (read-string _)
In unknown file:
           2 (read-char #<input: /gnu/store/25ql0xsjqf0alrvy6hmpw6gz…>)
In ice-9/boot-9.scm:
  1685:16  1 (raise-exception _ #:continuable? _)
  1685:16  0 (raise-exception _ #:continuable? _)
```

I've attached the entire build log.

[-- Attachment #2: q4j1fa750jn3jks5xpf5lqd4pnxkk9-ghc-attoparsec-0.14.4.drv.gz --]
[-- Type: application/gzip, Size: 8490 bytes --]

             reply	other threads:[~2022-01-31 10:36 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-01-31 10:33 Philip Munksgaard [this message]
2022-02-23 10:02 ` bug#53655: haskell build system cannot build attoparsec zimoun
2022-02-23 11:06   ` Philip Munksgaard
2022-02-23 11:25     ` Philip Munksgaard
2022-02-23 13:57       ` zimoun
2022-04-06 19:27 ` zimoun
2022-04-07  8:23   ` Philip Munksgaard

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=a9871314-33e8-474e-b2ec-854a5c740bfb@www.fastmail.com \
    --to=philip@munksgaard.me \
    --cc=53655@debbugs.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).