From: "Suhail Singh" <suhailsingh247@gmail.com>
To: 75394@debbugs.gnu.org
Cc: Guillaume Le Vaillant <glv@posteo.net>,
Katherine Cox-Buday <cox.katherine.e+guix@gmail.com>,
Munyoki Kilyungi <me@bonfacemunyoki.com>,
Sharlatan Hellseher <sharlatanus@gmail.com>,
jgart <jgart@dismail.de>
Subject: [bug#75394] [PATCH v14 2/2] gnu: Improve user-experience for jpm.
Date: Mon, 7 Oct 2024 23:22:13 -0400 [thread overview]
Message-ID: <68d09c78846a198ba4499f89f53e4b3782208c9d.1736126524.git.suhail@bayesians.ca> (raw)
In-Reply-To: <cover.1736126524.git.suhail@bayesians.ca>
* gnu/packages/lisp.scm (jpm): Ensure jpm respects JANET_HEADERPATH and
JANET_LIBPATH if set by user. Ensure gcc/g++ is able to find header files and
compilation-related utilities.
Change-Id: Ic7218dbd10e6fabddded50894b82492de8cabc88
---
gnu/packages/lisp.scm | 32 +++++++++++++++++++++++++-------
1 file changed, 25 insertions(+), 7 deletions(-)
diff --git a/gnu/packages/lisp.scm b/gnu/packages/lisp.scm
index f99ad68828..eb3063d3d9 100644
--- a/gnu/packages/lisp.scm
+++ b/gnu/packages/lisp.scm
@@ -30,6 +30,7 @@
;;; Copyright © 2024 bigbug <bigbookofbug@proton.me>
;;; Copyright © 2024 Ashish SHUKLA <ashish.is@lostca.se>
;;; Copyright © 2024 Omar Bassam <omar.bassam88@gmail.com>
+;;; Copyright © 2024 Suhail Singh <suhail@bayesians.ca>
;;; Copyright © 2024 David Pflug <david@pflug.io>
;;; Copyright © 2024 Janneke Nieuwenhuizen <janneke@gnu.org>
;;;
@@ -965,22 +966,39 @@ (define-public jpm
(setenv "PREFIX"
#$output)))
(replace 'install
- (lambda _
+ (lambda* (#:key inputs #:allow-other-keys)
(for-each (lambda (dir)
(mkdir-p (string-append #$output "/" dir)))
'("lib/janet/jpm" "share/man/man1"))
(invoke "janet" "bootstrap.janet"
"configs/linux_config.janet")
- (wrap-program (string-append #$output "/bin/jpm")
- `("JANET_HEADERPATH" ":" =
- (,(string-append #$janet "/include/janet")))
- `("JANET_LIBPATH" ":" =
- (,(string-append #$janet "/lib")))))))))
+ (let ((gcc-toolchain (assoc-ref inputs "gcc-toolchain"))
+ (core-min (assoc-ref inputs "coreutils-minimal")))
+ (wrap-program (string-append #$output "/bin/jpm")
+ `("JANET_HEADERPATH" ":" prefix
+ (,(string-append #$janet "/include/janet")))
+ `("JANET_LIBPATH" ":" prefix
+ (,(string-append #$janet "/lib")))
+ `("C_INCLUDE_PATH" ":" prefix
+ (,(string-append gcc-toolchain "/include")))
+ `("CPLUS_INCLUDE_PATH" ":" prefix
+ (,(string-append gcc-toolchain "/include/c++")
+ ,(string-append gcc-toolchain "/include")))
+ `("LIBRARY_PATH" ":" prefix
+ (,(string-append gcc-toolchain "/lib")
+ ,(string-append gcc-toolchain "/lib64")))
+ `("PATH" ":" prefix
+ (,(string-append gcc-toolchain "/bin")
+ ,(string-append core-min "/bin"))))))))))
(inputs (list bash-minimal
coreutils-minimal
curl
gcc
- git-minimal/pinned))
+ git-minimal/pinned
+ ;; Lazily resolve the gcc-toolchain to avoid a circular
+ ;; dependency.
+ (module-ref (resolve-interface '(gnu packages commencement))
+ 'gcc-toolchain)))
(propagated-inputs (list janet))
(native-search-paths
(list $SSL_CERT_DIR $SSL_CERT_FILE))
next prev parent reply other threads:[~2025-01-06 1:31 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-01-06 1:22 [bug#75394] [PATCH v14 0/2] Add jpm Suhail Singh
2024-10-08 3:22 ` Suhail Singh [this message]
2025-01-06 2:14 ` bug#75394: " jgart via Guix-patches via
2025-01-07 1:56 ` [bug#75394] " Suhail Singh
2025-01-07 2:51 ` jgart via Guix-patches via
2025-01-07 3:09 ` Suhail Singh
2025-01-07 7:15 ` Omar Bassam
2025-01-08 15:30 ` Suhail Singh
2024-10-08 3:31 ` [bug#75394] [PATCH v14 1/2] gnu: Add jpm package Suhail Singh
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=68d09c78846a198ba4499f89f53e4b3782208c9d.1736126524.git.suhail@bayesians.ca \
--to=suhailsingh247@gmail.com \
--cc=75394@debbugs.gnu.org \
--cc=cox.katherine.e+guix@gmail.com \
--cc=glv@posteo.net \
--cc=jgart@dismail.de \
--cc=me@bonfacemunyoki.com \
--cc=sharlatanus@gmail.com \
/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).