* guix environment and ld?
@ 2019-02-08 19:59 zimoun
2019-02-08 21:48 ` Christopher Baines
0 siblings, 1 reply; 4+ messages in thread
From: zimoun @ 2019-02-08 19:59 UTC (permalink / raw)
To: help-guix
Hi,
I am working on the package Gmsh.
Well, say the upstream repo is cloned and I am following the upstream readme.
Basically, it is a CMake build system for C++ code with some Fortran.
So, if I am doing:
mkdir build-1 && cd build-1
guix environment gmsh --pure
cmake .. && make
./gmsh -info # ok :-)
If I am doing:
mkdir build-2 && cd build-2
guix environment --pure --ad-hoc \
cmake make binutils glibc gfortran@5.5.0 gcc@5.5.0
cmake .. && make
./gmsh -info # ok :-)
Now, I would like to build a version with PETSc.
mkdir build-3 && cd build-3
guix environment --pure --ad-hoc \
cmake make binutils glibc gfortran@5.5.0 gcc@5.5.0 \
petsc
cmake .. && make
./gmsh -info # fail!
and ldd ./gmsh returns libpetsc.3.10 not found.
If I check the CMake file, then the PETSc library is found and all
seem alright. And libpetsc.3.10 is in the environment profile.
Hum? I am a bit confused. Do I miss something?
Note it builds fine with:
mkdir build-4 && cd build-4
guix environment gmsh --pure --ad-hoc petsc
cmake .. && make
./gmsh -info # ok
I know that `guix environment gmsh' "imports" more than cmake make
binutils glibc gfortran@5.5.0 gcc@5.5.0 but they are the minimal set
to build gmsh as the build-2 shows.
So, I do not suspect that the issue comes from that.
Well, I am packaging the friend solver of Gmsh ;-)
http://getdp.info/
Side question: guix environment --ad-hoc gcc@5.5.0 gfortran@5.5.0
warns about " ambiguous package specification `gcc@5.5.0'". Is it
expected? because it is not ambiguous.
Other side question and maybe related: it warns about "collision
encountered" between gcc and gfortran with fto1 cc1 liblto_plugin.la
cc1plus mkheaders. Does the issue come from that? If yes, how to
avoid the collision?
Thank you for any insight and/or comment.
All the best,
simon
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: guix environment and ld?
2019-02-08 19:59 guix environment and ld? zimoun
@ 2019-02-08 21:48 ` Christopher Baines
2019-02-11 11:12 ` zimoun
0 siblings, 1 reply; 4+ messages in thread
From: Christopher Baines @ 2019-02-08 21:48 UTC (permalink / raw)
To: zimoun; +Cc: help-guix
[-- Attachment #1: Type: text/plain, Size: 979 bytes --]
zimoun <zimon.toutoune@gmail.com> writes:
> Hi,
>
> I am working on the package Gmsh.
>
> Well, say the upstream repo is cloned and I am following the upstream readme.
> Basically, it is a CMake build system for C++ code with some Fortran.
>
> So, if I am doing:
> mkdir build-1 && cd build-1
> guix environment gmsh --pure
> cmake .. && make
> ./gmsh -info # ok :-)
>
> If I am doing:
> mkdir build-2 && cd build-2
> guix environment --pure --ad-hoc \
> cmake make binutils glibc gfortran@5.5.0 gcc@5.5.0
> cmake .. && make
> ./gmsh -info # ok :-)
>
> Now, I would like to build a version with PETSc.
>
> mkdir build-3 && cd build-3
> guix environment --pure --ad-hoc \
> cmake make binutils glibc gfortran@5.5.0 gcc@5.5.0 \
> petsc
> cmake .. && make
> ./gmsh -info # fail!
One tip, try using gcc-toolchain@5.5.0 rather than binutils, glibc and
gcc@5.5.0. I'm not quite sure why, but I've had it help me with other
compilation issues.
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 962 bytes --]
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: guix environment and ld?
2019-02-08 21:48 ` Christopher Baines
@ 2019-02-11 11:12 ` zimoun
2019-02-12 16:43 ` Ludovic Courtès
0 siblings, 1 reply; 4+ messages in thread
From: zimoun @ 2019-02-11 11:12 UTC (permalink / raw)
To: Christopher Baines; +Cc: help-guix
Hi Chris,
Thank you for the tip!
With gcc-toolchain, it seems to work fine.
Me too, I am not sure why.
Maybe because of the comment in the definition of make-gcc-toolchain:
"to make sure ld-wrapper comes before Binutils' ld in the user's profile."
Cheers,
simon
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: guix environment and ld?
2019-02-11 11:12 ` zimoun
@ 2019-02-12 16:43 ` Ludovic Courtès
0 siblings, 0 replies; 4+ messages in thread
From: Ludovic Courtès @ 2019-02-12 16:43 UTC (permalink / raw)
To: zimoun; +Cc: help-guix
Hello zimoun!
zimoun <zimon.toutoune@gmail.com> skribis:
> With gcc-toolchain, it seems to work fine.
>
> Me too, I am not sure why.
> Maybe because of the comment in the definition of make-gcc-toolchain:
> "to make sure ld-wrapper comes before Binutils' ld in the user's profile."
Exactly: the ‘ld’ wrapper is really needed, and the ‘gcc-toolchain’
metapackage makes sure you have everything (also libc, binutils, and
all.)
Ludo’.
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2019-02-12 16:43 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-02-08 19:59 guix environment and ld? zimoun
2019-02-08 21:48 ` Christopher Baines
2019-02-11 11:12 ` zimoun
2019-02-12 16:43 ` Ludovic Courtès
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/guix.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.