unofficial mirror of help-guix@gnu.org 
 help / color / mirror / Atom feed
From: Jesse <dev@millwood.earth>
To: help-guix@gnu.org
Subject: Using local package in shell manifest
Date: Wed, 25 Oct 2023 16:49:43 -0400	[thread overview]
Message-ID: <6e04801a-dada-4dd2-a857-d58794eea478@millwood.earth> (raw)

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

Hello,

I have written a package that I have installed with "guix package 
--install-from-file=crosstool-ng.scm". I was able to get it to build and 
install. I can use it if I do "source ~/.guix-profile/etc/profile".

However, I would like to add it to a shell manifest. My manifest just 
includes

(specifications->manifest
   (list "gcc" "git" "zsh" "crosstool-ng"))

My understanding is that "specifications->manifest" is supposed to 
search for the packages in the list? It returns the following when I 
rung "guix shell" in the directory with the manifest.scm:

guix shell: loading environment from 
'/home/jesse/Code/guix-tests/manifest.scm'...
hint: Consider passing the `--check' option once to make sure your shell 
does not
clobber environment variables.

guix shell: error: crosstool-ng: unknown package
guix shell: error: failed to load 
'/home/jesse/Code/guix-tests/manifest.scm':
gnu/packages.scm:545:4: In procedure specification->package+output:
Throw to key `quit' with args `(1)'.

I'd imagine it doesn't know where to look for the package? Is there a 
way to tell guix shell where to look? If not, is there a way to include 
the package in the manifest file? For what it's worth, I have attached 
the package file in question.

This is also my first foray into Guix and Guile, so I've been kind of 
banging my head through writing a package and the manual but I got a 
little stuck here.

Thanks

[-- Attachment #2: crosstool-ng.scm --]
[-- Type: text/x-scheme, Size: 1628 bytes --]

(use-modules
 (guix packages)
 (guix git-download)
 (guix licenses)
 (guix profiles)
 (guix build-system gnu)
 (guix build-system python)
 (guix build utils)
 (gnu packages python)
 (gnu packages autotools)
 (gnu packages gettext)
 (gnu packages texinfo)
 (gnu packages pkg-config)
 (gnu packages base)
 (gnu packages flex)
 (gnu packages gawk)
 (gnu packages man)
 (gnu packages bison)
 (gnu packages compression)
 (gnu packages ncurses)
 )

(package
 (name "crosstool-ng")
 (version "1.26.0")
 (source (origin
          (method git-fetch)
          (uri (git-reference
                (url "https://github.com/crosstool-ng/crosstool-ng.git")
                (commit (string-append "crosstool-ng-" version))))
          (sha256
           (base32
            "04z7zwhxfbjqrd4j16lviilppsd8phwi8zv2rs4jpkmqni6856j1")
           )
          ))
 (build-system gnu-build-system)
 (native-inputs
  (list autoconf
        automake
        gettext-minimal
        libtool
        texinfo
        bison
        flex
        gawk
        unzip
        which
        help2man
        python
        ncurses
        pkg-config))
 (arguments
  '(#:phases (modify-phases %standard-phases
                            (add-before 'bootstrap 'fix-version-gen
                                        (lambda* _
                                                 (patch-shebang "maintainer/git-version-gen")
                                                 )))))

 (synopsis "A versatile (cross-)toolchain generator.")
 (description "A versatile (cross-)toolchain generator.")
 (home-page "https://crosstool-ng.github.io/docs/")
 (license gpl2)
 )

             reply	other threads:[~2023-10-26 13:58 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-10-25 20:49 Jesse [this message]
2023-10-26 14:16 ` Using local package in shell manifest Tomas Volf
2023-10-26 14:48   ` Jesse
2023-10-26 15:43     ` Tomas Volf

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=6e04801a-dada-4dd2-a857-d58794eea478@millwood.earth \
    --to=dev@millwood.earth \
    --cc=help-guix@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.
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).