unofficial mirror of guix-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Christopher Baines <mail@cbaines.net>
To: Tanguy Le Carrour <tanguy@bioneland.org>
Cc: guix-devel@gnu.org
Subject: Re: Problem with `direnv` package definition
Date: Sat, 20 Apr 2019 18:02:45 +0100	[thread overview]
Message-ID: <87o950txsa.fsf@cbaines.net> (raw)
In-Reply-To: <20190420132019.priud6wucj5l2rn6@melmoth>

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


Tanguy Le Carrour <tanguy@bioneland.org> writes:

> Dear Guix
>
> As I'm still in the process of setting up my environment,
> I am not (yet) able to write and submit a patch for package `direnv`,
> so I'm sending this report instead…
>
> As mentioned on the `direnv` homepage, "direnv is compiled into
> a single static executable" [1]. As I understand it, this means that
> Go is required to build it, but not to run it.
>
> [1]: https://github.com/direnv/direnv
>
> However, in the package definition [2], 3 Go packages are listed as
> "inputs" whereas they should be listed as "native-inputs". Is this
> correct?
>
> [2]: gnu/packages/shellutils.scm

Hi Tanguy,

That sounds right to me, although there have been issues with binaries
generated with Go still referencing the Go compiler, and that's
seemingly the case with the direnv package in Guix at the moment.

There's also an important aspect of cross-compilation to these fields,
which you can read about here:

  https://www.gnu.org/software/guix/manual/en/html_node/package-Reference.html

> As I said, I'm still learning. But I've tried, and here is what I've
> done so far…
>
> I've `git clone`d the repo, ran the `guix env… guix` then `bootstrap`
> `configure` and `make` and everything seems to be fine.
> Just to make sure, I did `./pre-… guix env… direnv` then
> ran `./pre-… guix build direnv` and everything went well.
> Then I moved the direnv dependencies from inputs to native-inputs and
> build it again… and it unsurprisingly failed! The error message [3]
> does not say much… at least to me! ^_^'
>
> [3]: output of `./pre-inst-env guix build --keep-failed direnv`
>   direnv-2.15.2/version.txt
>   direnv-2.15.2/xdg.go
>   phase `unpack' succeeded after 0.0 seconds
>   starting phase `bootstrap'
>   no 'configure.ac' or anything like that, doing nothing
>   phase `bootstrap' succeeded after 0.0 seconds
>   starting phase `patch-usr-bin-file'
>   phase `patch-usr-bin-file' succeeded after 0.0 seconds
>   starting phase `patch-source-shebangs'
>   phase `patch-source-shebangs' succeeded after 0.0 seconds
>   starting phase `patch-generated-file-shebangs'
>   phase `patch-generated-file-shebangs' succeeded after 0.0 seconds
>   starting phase `build'
>   make: *** No targets specified and no makefile found.  Stop.
>   Backtrace:
>   4 (primitive-load
>       "/gnu/store/7rrxdai48si293dihzf55zn3svn…")
>   In ice-9/eval.scm:
>      191:35  3 (_ #f)
>   In srfi/srfi-1.scm:
>      863:16  2 (every1 #<procedure 71bfc0 at /gnu/store/i5ip2vy29fqpp…>
>   …)
>   In
>    /gnu/store/i5ip2vy29fqppjb4pq5isq36gqd42d89-module-import/guix/build/gn
>    u-build-system.scm:
>    799:28  1 (_ _)
>   In
>    /gnu/store/i5ip2vy29fqppjb4pq5isq36gqd42d89-module-import/guix/build/utils.scm:
>    616:6  0 (invoke _ . _)
>    /gnu/store/i5ip2vy29fqppjb4pq5isq36gqd42d89-module-import/guix/build/utils.scm:616:6: In procedure invoke:
>   Throw to key `srfi-34' with args `(#<condition &invoke-error[program: "make" arguments: ("-j" "8"
>   "DESTDIR=/gnu/store/dcvs8cq0ll4hcxc4x3mlcf24y1cw4ckm-direnv-2.15.2")
>   exit-status: 2 term-signal: #f stop-signal: #f] 869e80>)'.
>
>
> I've tried to read the rest of the package definition, but as I'm still
> attending Guile 1-0-1, that didn't help much!
>
> I would very much appreciate it if someone could point out my mistake!

I tried changing the inputs to native-inputs, and the package built for
me. Could you share the exact changes you made?

Chris

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 962 bytes --]

  reply	other threads:[~2019-04-20 17:03 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-04-20 13:20 Problem with `direnv` package definition Tanguy Le Carrour
2019-04-20 17:02 ` Christopher Baines [this message]
2019-04-21  8:34   ` Tanguy Le Carrour
2019-04-21  9:54     ` Christopher Baines
2019-04-23  7:59       ` Christopher Baines
2019-04-23 20:34       ` Tanguy Le Carrour

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=87o950txsa.fsf@cbaines.net \
    --to=mail@cbaines.net \
    --cc=guix-devel@gnu.org \
    --cc=tanguy@bioneland.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).