all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Giovanni Biscuolo <g@xelera.eu>
To: Danny Milosavljevic <dannym@scratchpost.org>
Cc: guix-devel@gnu.org
Subject: Re: Guix direct checkout hacking
Date: Sat, 16 Mar 2019 15:39:56 +0100	[thread overview]
Message-ID: <87va0iublv.fsf@roquette.mug.biscuolo.net> (raw)
In-Reply-To: <20190316125456.4db5c8dd@scratchpost.org>

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

Hi Danny,

Danny Milosavljevic <dannym@scratchpost.org> writes:

> Hi,
>
> On Sat, 16 Mar 2019 12:24:27 +0100
> Giovanni Biscuolo <g@xelera.eu> wrote:
>
>> I regurarly "git pull" in $GUIX_CHECKOUT and then "guix environment
>> guix": is it sufficient and necessary to "/.bootstrap" and then
>> "/.configure" every time I enter the environment in order to have a
>> working build environment?
>
> Not really.  Only if dependencies get added or removed,

bootstrap deps or packages deps (inputs)?

> or some variables in the Makefiles get added or removed.

OK, got it thanks

> Personally, I'm too lazy to bootstrap every time.  But I ./configure
> pretty often ("./configure --localstatedir=/var").

uh: --localstatedir is **mandatory**

it defaults to /usr/local/var [1] as documented in GNU Coding Standards
7.2.5 [2] while I thought it defaulted to /var (GNU Coding Standards
it's another *really should* read to be a proficient Guix hacker, no?)

should we better document in
https://www.gnu.org/software/guix/manual/en/html_node/The-Store.html#The-Store?
that if not specified --localstatedir defaults to /usr/local/var as for
above mentioned coding standards?

>> Do I really need to "make check" every time I "activate" the devel
>> environment or after every "git pull" of my $GUIX_CHECKOUT?
>
> Not really, but later on, it's nice to know whether your change broke
> something or whether it was broken to begin with.  Personally, I don't
> run "make check" until I need to.  I often need to backtrack then :)

OK, got it thanks

>> Do I neeed to regurarly "make clean-go" to get rid of compiled .go or I
>> can ignore this step? If this step should be regurarly done: when?
>> (this is not documented, just my curiosity)

[...]

> In the real world, I don't delete all ".go" file every time--it would
> take way too long to recompile.
>
> But if there are strange things happening later, I delete them and
> run "make" in order to rebuild them.

OK got it, thanks

>> I start the build daemon in the environment:
>> 
>>   sudo -E ./pre-inst-env guix-daemon --build-users-group=guixbuild
>
> I never do this since the build daemon almost never changes.  So I just
> use the system build daemon.

eh... got in now, too :-)
I thought I needed to start a separate daemon to be able to build, see [2]

>> error: failed to run download program '/home/giovanni/{git}/giovanni.biscuolo.net/guix/nix/scripts/download': Permission denied
>
> Hmm, what are the permissions of that file?

-rwxr-xr-x 1 giovanni giovanni 272 Mar 16 15:08 nix/scripts/download

> Did you generate it using the same user ? (via ./configure, I think).

yes

OK, so I reconfigured via "./configure --localstatedir=/var" and now:

--8<---------------cut here---------------start------------->8---
giovanni@anemone: time ./pre-inst-env guix build --verbosity=5 hello
guix build: error: getting attributes of path `/gnu/store/hbdalsf5lpf01x4dcknwx6xbn6n5km6k-hello-2.10.tar.gz': No such file or directory

Some deprecated features have been used.  Set the environment
variable GUILE_WARN_DEPRECATED to "detailed" and rerun the
program to get more information.  Set it to "no" to suppress
this message
--8<---------------cut here---------------end--------------->8---

solved this with

--8<---------------cut here---------------start------------->8---
giovanni@anemone: guix gc --verify
reading the store...
checking path existence...
path `/gnu/store/5c88v80zi7gm928ajn739lnz5vc7vkfg-glibc-2.28.tar.xz' disappeared, removing from database...
path `/gnu/store/hbdalsf5lpf01x4dcknwx6xbn6n5km6k-hello-2.10.tar.gz' disappeared, removing from database...
--8<---------------cut here---------------end--------------->8---

and now hello builds


Thanks!


[1] I fully realized this when running
--8<---------------cut here---------------start------------->8---
giovanni@anemone: ./pre-inst-env guix build hello
guix build: error: failed to connect to `/usr/local/var/guix/daemon-socket/socket': Connection refused
--8<---------------cut here---------------end--------------->8---
in the "guix build" environment

[2] https://www.gnu.org/prep/standards/html_node/Directory-Variables.html#Directory-Variables

-- 
Giovanni Biscuolo

Xelera IT Infrastructures

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

      reply	other threads:[~2019-03-16 14:56 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-03-16 11:24 Guix direct checkout hacking Giovanni Biscuolo
2019-03-16 11:54 ` Danny Milosavljevic
2019-03-16 14:39   ` Giovanni Biscuolo [this message]

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

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

  git send-email \
    --in-reply-to=87va0iublv.fsf@roquette.mug.biscuolo.net \
    --to=g@xelera.eu \
    --cc=dannym@scratchpost.org \
    --cc=guix-devel@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 external index

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

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.