GNU bug report logs -
#72925
Adding JPM package for Janet
Previous Next
Full log
View this message in rfc822 format
[Message part 1 (text/plain, inline)]
On Thu, 3 Oct 2024 at 00:39, Suhail Singh <suhailsingh247 <at> gmail.com> wrote:
> Omar Bassam <omar.bassam88 <at> gmail.com> writes:
>
> >> When running "jpm --cc=gcc --local install sh" I get the same error.
> >>
> >> I was finally able to get it to succeed by having cc symlink to gcc and
> >> adding the directory containing the symlink to PATH. So I believe that
> >> the package definition you've submitted is correct. However, I'm
> >> wondering what (if anything) needs to be done about the issue I
> >> encountered.
> >>
> >> Specifically, it's unclear why passing "-cc=gcc" didn't work (nor did
> >> setting "CC=gcc", but perhaps JPM ignores the latter?). Is this an
> >> upstream bug? Were my expectations misplaced? Should the JPM package
> >> in Guix provide "cc" as well?
> >>
> >
> > No, this is not really a Janet or JPM issue but rather the fact that
> > you are overriding the gcc compiler with a symlinked binary instead of
> > the absolute path.
>
> I don't understand.
>
> All four variants below fail in exactly the same way:
>
> #+begin_src sh
> jpm --cc=gcc -l install sh
> #+end_src
>
> #+begin_src sh
> jpm --cc=/home/user/.guix-profile/bin/gcc -l install sh
> #+end_src
>
> #+begin_src sh
> jpm
> --cc=/gnu/store/x2kv3zw2k7ql211m5kvb6yw401gab0x9-gcc-toolchain-14.2.0/bin/gcc
> -l install sh
> #+end_src
>
> #+begin_src sh
> jpm --cc=/gnu/store/lq9y7sd4mvffs4hqp3hkr9fnd384pnkj-gcc-14.2.0/bin/gcc
> -l install sh
> #+end_src
>
> Note that the last variant uses an absolute path.
>
> Either I'm not using the "--cc" option correctly. Or for some
> dependency of "sh" (specifically, posix-spawn) the compiler has been
> hardcoded to "cc" and it's not picking up the option being passed to
> jpm.
>
> Further, if the above work for you in a "--pure" guix shell (where it
> doesn't for me), that's surprising.
>
> It is _only_ when I provide a fake "cc" (which is simply a symlink to
> gcc) that things work.
>
> --
> Suhail
>
I believe this is a library specific thing. I don't think this should be
related to this patch.
Also, if you are running a guix shell with --pure flag, try adding
coreutils to your shell because jpm calls the "cp" command when building
libraries.
I tried with "jpm install -l spork" and with "jpm install -l sh" and it
works fine. I believe the --cc flag is meant to be used for the jpm build
command.
[Message part 2 (text/html, inline)]
This bug report was last modified 137 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.