Thanks a lot to both for answering ! It worked nicely with Scott's
solution. I guess the -DCOMPILER=MANUAL was the key.
And yes, I actually have been using Dave's solution in the past but I
wanted to do it now without these links. ....
Cheers
Vlad
On 11/5/22 15:48, David A Case wrote:
> On Sat, Nov 05, 2022, Vlad Cojocaru via AMBER wrote:
>>
>> Does anyone have any idea how to stop cmake from using the default
>> gcc version ?
>
> Scott's solution is the elegant one. But here's the alternative I use: I
> allow cmake to use the default gcc, but make sure the compilers in my
> PATH
> are the ones I want to use.
>
> As an example, I create a /home/case/gcc11bin folder with three entries:
> gcc, g++ and gfortran. Each of these points to the compiler I want, e.g.
> ln -s /usr/bin/gcc-11 gcc
> ln -s /usr/bin/g++-11 g++
> ln -s /usr/bin/gfortran-11 gfortran
>
> Then, *for just the session when I compile Amber*, I do this:
> export PATH=/home/case/gcc11bin:$PATH
>
> I can then run cmake with no extra flags.
>
> ....dac
>
--
Dr. Vlad Cojocaru (PD, Habil.)
----------------------------------------------
Guest Scientist / Fmr. Project Group Leader
Max Planck Institute for Molecular Biomedicine
Röntgenstrasse 20, 48149 Münster, Germany
----------------------------------------------
Email: vlad.cojocaru.mpi-muenster.mpg.de
http://www.mpi-muenster.mpg.de/43241/cojocaru
_______________________________________________
AMBER mailing list
AMBER.ambermd.org
http://lists.ambermd.org/mailman/listinfo/amber
Received on Sat Nov 05 2022 - 12:30:02 PDT