-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

I figured out why I was getting those two test failures after looking
more closely at tests/store.log: when I installed GuixSD, I did so
directly from another hard drive on the same system (having read in the
past about issues with multi-booting, I figured I'd just decide which to
boot to by selecting hard drives). I had previously cloned guix on the
Ubuntu hard drive, and figured I'd just mount it and copy it over. It
turns out that re-running make didn't alter the tests quite as much as I
thought it would, and the old path was stuck in some of them (on GuixSD
there is no code-downloads folder, it's just straight in
Programming/). After a git clean, though, the tests all pass.

> Though something went from with your email client.  :-)

Aye, turns out M-x epa-mail-sign doesn't work well with attachments. I
posted another message that should be signed correctly, as well as this
one.

> What are your thoughts on the next steps?

Well, I took a look at libstore/build.cc, and that is a lot of code. I
hope I can get away with only reading as much as is necessary to clarify
details. To that end, I'd like to make sure that my high-level
understanding of the build process is accurate.

- - A derivation is a node in a (acyclic?) graph of "what depends on what" or,
  alternately put, what is input to what.

- - Derivations can depend on other derivations or plain files (can those files 
be
  directories?), where "plain files" cannot depend on anything else.

- - "Building" a derivation involves first ensuring that all of its inputs are
  "built" (in the case of inputs that are derivations, this means ensuring its
  output exists as a store item, and if not, producing it by this same
  process. In the case of plain file inputs, this means just ensuring that they
  exist as a store item), and then preparing a build environment. The "builder"
  script is then executed in a chroot rooted under the build tree. After it has
  completed, the output (where is it put during the build process?) from
  building the derivation is placed in the store (and registered).

- - "preparing a build environment" involves first creating a directory in which
  the build will be run, then populating it with certain expected files and
  directories (as detailed in 2.4.1 of the manual). Also, the store items
  produced from building the inputs need to somehow be made available (is there
  a gnu/store/ under the build tree? I feel like I don't quite understand where
  everything goes in the build tree). Also, set any environment variables
  associated with the derivation.

Assuming I've got the gist of it sort of right, that leaves one more question:
how are hashes for the paths computed? It's not sha256 like the database hashes,
it seems to be 160 bits in size. How are all the inputs hashed together? Are all
the inputs put in one big directory and that is hashed in nar form, or what? And
what about store items that don't have any inputs (for example, something placed
in there with add-text-to-store)? I suppose in that case they are their own
input, perhaps?

Some of those answers might be in the manual, but I didn't manage to
find them.
-----BEGIN PGP SIGNATURE-----

iQEzBAEBCAAdFiEEdNapMPRLm4SepVYGwWaqSV9/GJwFAllGRk0ACgkQwWaqSV9/
GJw9TQf/W8ewHEFzwTssGhMGW/pGsSvUMnzdQNmx31Y1HLMpUbhBazbIUa57pz5g
ZfDbUIRnKBYlCPi5X+8Om8fzMjWpUixYeyv/Clk3sRvbcQhod0cejbRIC0PAiTN0
mVlu4tUWJlEXekcG7OqhdZ8AZXJ53qOkNMEHR3h91PCJOZj2fOVwzlC5kp7gUfcM
C9a/rgCb6ZG6dXQNH3Q0qI38+akDg3tbD0BDk97yhHCBSVitwbJd9vTiEl3QhAPP
WFlZjmZGFpfruZiuRDyO8pOFC4tfdsEy/wv4spjq63ZgBNqLQsI9Y0JfXJWM/fEH
d+KsI54ix/yDhZnbZofLaogAH3Fo8w==
=Ukhf
-----END PGP SIGNATURE-----

Reply via email to