From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1 ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id 0GlwN5KoSmCLHQAA0tVLHw (envelope-from ) for ; Thu, 11 Mar 2021 23:32:34 +0000 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1 with LMTPS id 4O4lM5KoSmATCQAAbx9fmQ (envelope-from ) for ; Thu, 11 Mar 2021 23:32:34 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id F2F60260A9 for ; Fri, 12 Mar 2021 00:32:33 +0100 (CET) Received: from localhost ([::1]:39684 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lKUn9-0006Bg-Gy for larch@yhetil.org; Thu, 11 Mar 2021 18:32:31 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:53752) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lKUmT-0006AF-09 for help-guix@gnu.org; Thu, 11 Mar 2021 18:31:54 -0500 Received: from mout01.posteo.de ([185.67.36.65]:54436) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lKUmN-0005QT-FR for help-guix@gnu.org; Thu, 11 Mar 2021 18:31:48 -0500 Received: from submission (posteo.de [89.146.220.130]) by mout01.posteo.de (Postfix) with ESMTPS id 979BC16007F for ; Fri, 12 Mar 2021 00:31:37 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.de; s=2017; t=1615505497; bh=8qHI0spQLZMl92sw1wO8CC3vJZCA6knP11KYT88+HtI=; h=To:From:Subject:Date:From; b=r/uWLrmO89+yQ1gSOqWP5VkKcrfzgnaTjgdI5Cp0Vjc3N69w0sBpriN8gTnnYRqSH jhbqwdWxgKQzzG2gibyTybkvA05mc4GaVB4RI6RDA5pAm3UldFf1+5N4IdUWKffBnm Mba74mDSGZJBjhWr1BpwKC5IJc6jUyii+EBP3TD1io1vp4j1NnMGazRBOGmw3ux821 UokSBz4y8JJDeKEZkqd41as1bT9t6d5sbk9zD0bjZmhoZySi4bGYBNSr1ZhHDEYEU+ c16KVMw2ry8u87gYub+82pyPLaojwcpetKH39OSFB+BesGtbP8Tbyh3YZ6jO+zAEX+ 8Fef1fXTX8Zyg== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4DxQFN6KLXz6tmN for ; Fri, 12 Mar 2021 00:31:36 +0100 (CET) To: help-guix From: Zelphir Kaltstahl Subject: Setting up guix source tree for testing a package Message-ID: <7698a9df-6fe6-9581-a513-456f8058ad3b@posteo.de> Date: Fri, 12 Mar 2021 00:31:36 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.7.1 MIME-Version: 1.0 Content-Language: en-US Received-SPF: pass client-ip=185.67.36.65; envelope-from=zelphirkaltstahl@posteo.de; helo=mout01.posteo.de X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_MED=-2.3, RCVD_IN_MSPIKE_H4=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, URIBL_SBL=1.623 autolearn=ham autolearn_force=no X-Spam_action: no action Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Content-Filtered-By: Mailman/MimeDel 2.1.23 X-BeenThere: help-guix@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-guix-bounces+larch=yhetil.org@gnu.org Sender: "Help-Guix" X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1615505554; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding:list-id:list-help: list-unsubscribe:list-subscribe:list-post:dkim-signature; bh=cHy3DJvTBP3SEL2ThghDOFbBVCyJnUXz9sL6zXFVs+4=; b=cE9Tvxq4Snf5Z6to82eafWDgXHQeDrarfm6N8BvzsqpFtKJ5ffsYIUBrJmkl7GAqbOiz6x OMvQMs5qVU98B83R3OP63ULt5JV/elnpn2rDfoJpXDk9GIAnuNl/Q0iZm0hRU0CjJa/Tpw fcSl2S9m6Pmk8MvooQOCLDahIRkVlapSP+lwvx3nOnfVC+Zh6adDtfF8p/QZaq+gtxY5vR pGRvSWewxO/kA1M48oA+tJbY0dyjz8fiGyoJeBO5ShQCuuZVx45amcSDMPMynuHlaXH4xb kMER5IobasdZKewjTGre3bc1Cv7+i3MWbfcfiVeCd47+9gVuMeiw0YUL7lhgxQ== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1615505554; a=rsa-sha256; cv=none; b=LFAdY7wske6bHKAO/TutM8qSJJSSAyXpm+OI6CIfuaMJcBVR8M9a0sAws/tLT0l/iS+APl BlG2WIH+deUy9RpFCKedElm1Zq2NX1qyHZVH9mJ+Rq/zhRp4QehQ5gZe+VuYleE+8hzGEP KtEsV9uUvX9/1cx/aXhq+kDh+8/3WajmMK36QpQAsxPgYNZMQcZDKwv9eWEkzehTiKMwhW LDMW5VDUEKcxeRrenzsDTWr7z9kQijBg+kn2rlIExDijygBDGCxCCovWRUau/B0SfzgdUi 2G2ZpycXGkq1AT3JmXNu8u7iUtTkLLvRE9skTcPnwUXCxUGYFUYqjCiwgVTqBg== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("body hash did not verify") header.d=posteo.de header.s=2017 header.b="r/uWLrmO"; dmarc=fail reason="SPF not aligned (strict)" header.from=posteo.de (policy=none); spf=pass (aspmx1.migadu.com: domain of help-guix-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=help-guix-bounces@gnu.org X-Migadu-Spam-Score: -1.29 Authentication-Results: aspmx1.migadu.com; dkim=fail ("body hash did not verify") header.d=posteo.de header.s=2017 header.b="r/uWLrmO"; dmarc=fail reason="SPF not aligned (strict)" header.from=posteo.de (policy=none); spf=pass (aspmx1.migadu.com: domain of help-guix-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=help-guix-bounces@gnu.org X-Migadu-Queue-Id: F2F60260A9 X-Spam-Score: -1.29 X-Migadu-Scanner: scn0.migadu.com X-TUID: D8/Jc7he+iKc Hello Guix Users, I am trying to set up GNU Guix for package testing, as I want to test a package before sending in a patch to add it to GNU Guix. I'll describe the steps I am taking and where I am seeing them in the docs in the following. All is happening inside a VM, which runs a Debian 10. The VM is almost fresh, except for guest additions and git and vim and such things. I start at https://guix.gnu.org/manual/en/html_node/Packaging-Guidelines.html , wherein I find a link to https://guix.gnu.org/manual/en/html_node/Defining-Packages.html . Next the packaging guidelines tell me, that I may run for example: ~~~~ ./pre-inst-env guix build gnew --keep-failed ~~~~ inside the Guix build tree. I clone Guix, so that I have a source tree of Guix. I define my package inside `guix/gnu/packages/guile.scm`. In packaging guidelines, there is a link to https://guix.gnu.org/manual/en/html_node/Running-Guix-Before-It-Is-Installed.html . I am supposed to run the test inside a fresh Guix, to make sure, that the package will work fine for others, if I understand correctly. On https://guix.gnu.org/manual/en/html_node/Running-Guix-Before-It-Is-Installed.html I am told, that I need to generate a pre-installation script to run guix without installing it (running stuff in the Guix build tree, as far as I understand). To generate it, I need Guix again. The docs direct me to https://guix.gnu.org/manual/en/html_node/Building-from-Git.html . On https://guix.gnu.org/manual/en/html_node/Building-from-Git.html the dilemma is finally uncovered, that I need Guix to build the pre-installation script, to use that, to build a package in the Guix source tree. > As you can see, there is a chicken-and-egg problem: you first need to have Guix installed. Typically you would install Guix System (see System Installation) or Guix on top of another distro (see Binary Installation); in either case, you would verify the OpenPGP signature on the installation medium. This “bootstraps” the trust chain. I install it. Then I run: ~~~~ guix environment guix --pure ~~~~ The docs tell me I have to run: ~~~~ ./bootstrap ./configure --localstatedir=some_directory ~~~~ But here I am facing a problem. I have no clue what to set the `--localstatedir=directory` to. The docs tell me it is important, but I see no instructions on how to choose a directory for the local state, when I have already a Guix installed (binary installation on foreign distro). The linked docs about the https://guix.gnu.org/manual/en/html_node/The-Store.html do not help me choosing it either, because that page is about the store itself, not about my specific scenario of doing things from Guix source tree. Since I intend to build a package inside the Guix source tree, I think it should exactly _not_ be /var, as that would conflict with the Guix installation, that I had to do to create the pre-inst-env script. What is the idea for the local state directory? Is it the location of a temporary store, which will contain anything, that I produce using the pre-inst-env script? That is what I am guessing. In that case I think `localstoredir` might be a good alias for `localstatedir`. I am trying with an empty directory, which I create just for that purpose, on the same level as the cloned Guix repository: ~~~~ $ tree -L 2 . ├── guix │   ├── ABOUT-NLS │   ├── aclocal.m4 │   ├── AUTHORS │   ├── autom4te.cache │   ├── bootstrap │   ├── build-aux │   ├── ChangeLog │   ├── CODE-OF-CONDUCT │   ├── config-daemon.ac │   ├── config.log │   ├── config.status │   ├── configure │   ├── configure.ac │   ├── COPYING │   ├── doc │   ├── etc │   ├── gnu │   ├── gnu.scm │   ├── guix │   ├── guix.scm │   ├── HACKING │   ├── INSTALL │   ├── m4 │   ├── Makefile │   ├── Makefile.am │   ├── Makefile.in │   ├── NEWS │   ├── nix │   ├── po │   ├── pre-inst-env │   ├── README │   ├── ROADMAP │   ├── scripts │   ├── test-env │   ├── tests │   ├── THANKS │   └── TODO └── guix-store ~~~~ So I run: ~~~~ ./configure --localstatedir=/home/user/dev/guix-store ~~~~ Next is running: ~~~~ make check ~~~~ Some warnings appear: ~~~~ Your input po file po/doc/guix-manual.de.po seems outdated (The amount of entries differ between files: 10012 is not 334 ). Please consider running po4a-updatepo to refresh it. ~~~~ But I am guessing, that these can be ignored for my purposes, as I am not doing anything with translations or po files. However, there are other errors, like not finding code for some modules (the output of make check is very long and probably I should rather put the log somewhere and link to it). The check seems to fail ultimately with the following result: ~~~~ make[4]: *** [Makefile:5563: tests/store.log] Error 1 make[4]: Leaving directory '/home/user/dev/guix' make[3]: *** [Makefile:5545: check-TESTS] Error 2 make[3]: Leaving directory '/home/user/dev/guix' make[2]: *** [Makefile:5794: check-am] Error 2 make[2]: Leaving directory '/home/user/dev/guix' make[1]: *** [Makefile:5322: check-recursive] Error 1 make[1]: Leaving directory '/home/user/dev/guix' make: *** [Makefile:5796: check] Error 2 ~~~~ The only red colored fail I can see is above from that, first line of the following: ~~~~ FAIL: tests/go.scm PASS: tests/grafts.scm PASS: tests/graph.scm PASS: tests/gremlin.scm SKIP: tests/hackage.scm PASS: tests/import-utils.scm PASS: tests/inferior.scm PASS: tests/lint.scm PASS: tests/modules.scm PASS: tests/monads.scm PASS: tests/nar.scm PASS: tests/networking.scm PASS: tests/opam.scm PASS: tests/openpgp.scm PASS: tests/packages.scm SKIP: tests/pack.scm PASS: tests/pki.scm PASS: tests/print.scm PASS: tests/processes.scm PASS: tests/profiles.scm SKIP: tests/publish.scm SKIP: tests/pypi.scm PASS: tests/records.scm PASS: tests/scripts.scm PASS: tests/search-paths.scm PASS: tests/services.scm PASS: tests/services/file-sharing.scm PASS: tests/services/linux.scm PASS: tests/sets.scm PASS: tests/size.scm SKIP: tests/snix.scm PASS: tests/status.scm PASS: tests/store-database.scm PASS: tests/store-deduplication.scm PASS: tests/store-roots.scm make[4]: *** [Makefile:5563: tests/store.log] Error 1 make[4]: Leaving directory '/home/user/dev/guix' make[3]: *** [Makefile:5545: check-TESTS] Error 2 make[3]: Leaving directory '/home/user/dev/guix' make[2]: *** [Makefile:5794: check-am] Error 2 make[2]: Leaving directory '/home/user/dev/guix' make[1]: *** [Makefile:5322: check-recursive] Error 1 make[1]: Leaving directory '/home/user/dev/guix' make: *** [Makefile:5796: check] Error 2 ~~~~ I am not sure, whether this means, that I have an erroneous Guix or whether the localstatedir was wrong or what else it means. However, I continue. The docs on https://guix.gnu.org/manual/en/html_node/Building-from-Git.html continue: > From there on, you can authenticate all the commits included in your checkout by running: make authenticate It is not clear to me, whether that means, that I need to run it in my scenario or whether I should not run it. A look into the Makefile shows, that it is actually calling a guix command `guix git authenticate`. The description is "verify commit signatures and authorizations". "verify" or "verify-signatures" seems a more appropriate name, because it indicates checking signatures, instead of authenticating commits. However, this might be my lacking understanding of what `make authenticate` does or aims to do. When I try running: ~~~~ make authenticate ~~~~ I get an error: ~~~~ $ make authenticate Authenticating Git checkout... /bin/bash: line 1: guix: command not found make: *** [Makefile:6290: authenticate] Error 127 ~~~~ I am confused as to why it does not find guix. I am inside the environment created by `guix environment guix --pure`. I continue nevertheless and try to run: ~~~~ ./pre-inst-env guix build guile-fslib ~~~~ However, my whole setup now seems wo be messed up. The `guix` command can simply no longer be found: ~~~~ $ pwd /home/user/dev $ guix environment guix --pure $ pushd guix ~/dev/guix ~/dev $ ./pre-inst-env guix build guile-fslib guix build: error: failed to connect to `/home/user/dev/guix-store/guix/daemon-socket/socket': No such file or directory ~~~~ A logout and login does not change the error. Where did I go wrong? Regards, Zelphir -- repositories: https://notabug.org/ZelphirKaltstahl