From: "Suhail Singh" <suhailsingh247@gmail.com>
To: Omar Bassam <omar.bassam88@gmail.com>
Cc: Sharlatan Hellseher <sharlatanus@gmail.com>,
72925@debbugs.gnu.org, Guillaume Le Vaillant <glv@posteo.net>,
Katherine Cox-Buday <cox.katherine.e+guix@gmail.com>,
Munyoki Kilyungi <me@bonfacemunyoki.com>,
jgart <jgart@dismail.de>, Suhail Singh <suhailsingh247@gmail.com>
Subject: [bug#72925] Adding JPM package for Janet
Date: Thu, 03 Oct 2024 09:40:00 -0400 [thread overview]
Message-ID: <87jzep2tlb.fsf_-_@gmail.com> (raw)
In-Reply-To: <CAGSr2rZk1GVda4kE7qKLKbqB=Dv_gjZSnxt4hU68w_j4aAq-8w@mail.gmail.com> (Omar Bassam's message of "Thu, 3 Oct 2024 10:14:20 +0300")
Omar Bassam <omar.bassam88@gmail.com> writes:
> I just have some questions before submitting v8 if you don't mind. just to
> make sure I understand correctly.
Questions are always welcome :)
>> Specifically, in the file "configs/linux_config.janet", among other
>> things, the below are set
>>
>> #+begin_src janet
>> :c++ "c++"
>> :c++-link "c++"
>> :cc "cc"
>> :cc-link "cc"
>> #+end_src
>>
>> Since Guix, as far as I know, doesn't have packages that provide c++ nor
>> cc, I believe the above need to be patched to refer to gcc and g++
>> respectively.
>>
>> So we need to substitute the above "c++" and "cc" in the
> "configs/linux_config.janet" to point to the absolute path for the gcc and
> g++ packages?
I believe there are multiple ways to make this work. I haven't tested
this, so take my opinions as speculative.
If we replace "cc" and "c++" with the _absolute path_ for "gcc" and
"g++" respectively from the Guix store, then I don't think we need to
specify gcc-toolchain as a propagated input. Upon reflecting on this,
this is probably the better approach.
If, however, we replace "cc" and "c++" with the _strings_ "gcc" and
"g++", then I believe we may need to specify gcc-toolchain in the
propagated inputs. IIUC, in this case we would replace the command that
JPM invokes when building. By additionally having gcc-toolchain in the
propagated inputs we'll ensure that they're available in the PATH.
> Should we also replace other commands that are hard-coded like "cp" and
> "chown" from coreutils the same way I did in my first initial patch?
I don't believe this is necessary. There's a question regd. whether or
not coreutils needs to be added to the propagated inputs, however. I
don't have a definitive answer, but the way to test it would be to run
it in a pure container and see if things work without having to
explicitly specify coreutils. If you're unable to test it, let me know
when you send v8 and I can test it on your behalf.
For reference, I use something like the below:
#+begin_src sh
guix shell --pure -CPWN \
-E '.*GTK.*|.*XDG.*|.*DISPLAY.*|TERM|INSIDE_EMACS' \
-p /path/to/profile
#+end_src
> Further, I believe JPM should have a few propagated inputs:
>> - gcc-toolchain
>> - curl
>> - git
>> - nss-certs.
>>
>> I understand why we need gcc-toolchain. But why do we need curl, git and
> nss-certs?
linux_config.janet also specifies:
#+begin_src janet
...
:curlpath "curl"
...
:gitpath "git"
...
#+end_src
Whether Guix packaging picks these up automatically or not, I haven't
tested, but it seems for common usage of JPM these dependencies ought to
be available. Similar to the case of "gcc" and "g++", it might be
better to replace these with references to the respective binaries in
the Guix store instead (as opposed to propagating them as I had
previously suggested).
Regarding nss-certs, it provides certificates for Certification
Authorities which, IIUC, would be relevant for HTTPS URLs (e.g. fetching
dependencies over git+https).
To summarize, here's what I believe is needed. Add nss-certs to the
propagated inputs, and for the below replace their occurrence in
linux_config.janet with references to binaries in the store:
- cc -> absolute path of gcc
- c++ -> absolute path of g++
- curl -> absolute path of curl
- git -> absolute path of git
--
Suhail
next prev parent reply other threads:[~2024-10-03 13:42 UTC|newest]
Thread overview: 30+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-09-01 8:31 [bug#72925] Adding JPM package for Janet Omar Bassam
2024-09-04 8:22 ` [bug#72925] [PATCH] adding jpm package Omar Bassam
2024-09-05 14:50 ` Omar Bassam
2024-09-18 13:18 ` [bug#72925] Adding JPM package for Janet Suhail Singh
2024-09-18 15:34 ` Omar Bassam
2024-09-18 16:16 ` Suhail Singh
2024-09-30 8:12 ` [bug#72925] [PATCH v3] adding jpm package Omar Bassam
2024-10-01 0:06 ` Suhail Singh
2024-10-02 15:09 ` Omar Bassam
2024-10-02 18:21 ` Suhail Singh
2024-10-02 19:04 ` jgart via Guix-patches via
2024-10-02 19:12 ` Omar Bassam
2024-10-02 20:14 ` Suhail Singh
2024-10-02 20:27 ` Omar Bassam
2024-10-02 20:33 ` jgart via Guix-patches via
2024-10-02 21:39 ` Suhail Singh
2024-10-02 21:52 ` Omar Bassam
2024-10-02 22:07 ` Suhail Singh
2024-10-03 1:40 ` Suhail Singh
2024-10-03 7:14 ` Omar Bassam
2024-10-03 13:40 ` Suhail Singh [this message]
2024-10-03 19:45 ` [bug#72925] Adding JPM package for Janet Omar Bassam
2024-10-03 22:04 ` Omar Bassam
2024-10-04 16:00 ` Omar Bassam
2024-10-02 20:27 ` [bug#72925] [PATCH v3] adding jpm package jgart via Guix-patches via
2024-10-02 14:36 ` [bug#72925] [PATCH v5] gnu: add " Omar Bassam
2024-10-02 14:50 ` [bug#72925] [PATCH v6] " Omar Bassam
2024-10-02 14:51 ` [bug#72925] [PATCH v7] " Omar Bassam
2024-10-04 15:17 ` Omar Bassam
2024-10-04 15:57 ` [bug#72925] [PATCH v8] " Omar Bassam
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=87jzep2tlb.fsf_-_@gmail.com \
--to=suhailsingh247@gmail.com \
--cc=72925@debbugs.gnu.org \
--cc=cox.katherine.e+guix@gmail.com \
--cc=glv@posteo.net \
--cc=jgart@dismail.de \
--cc=me@bonfacemunyoki.com \
--cc=omar.bassam88@gmail.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).