Vous regardez une version antérieure (v. /display/EDDSDLTEL/GEM+5.1.1) de cette page.

afficher les différences afficher l'historique de la page

Vous regardez la version actuelle de cette page. (v. 1) afficher la version suivante »

1) Create directory

First create yourself a directory under your home(!) (so it gets backup up) in which you want to create the executable.
I usually call mine:

     ~/gem/v_5.1.1/Abs/...

2) Populate directory

Go into the executable directory you created above.

a) Clone the Git repository you want

For example:

             git clone ~winger/gem/v_5.1.1/Abs/UQAM_development_FLake_CLASS/gem

then change into 'gem' directory:

             cd gem

b) Create working directories

So the object files, libraries and executables will not be under your home, create links for the directories 'build' and 'work'. Pick a place under which you want to keep the object files, libraries and executables, for example:

            work_space=~/projects/def-professor/${USER}/GEM_WORK_DIR

Create the directories and the links:

            mkdir -p ${work_space}/build
            mkdir -p ${work_space}/work
            ln -s ${work_space}/build
            ln -s ${work_space}/work

3) Create the executables

a) Acquire compiler:

            module add intel/2021.2.0 fftw-intel-2021

b) Set the variable 'abs_dir' to the name of your executable directory (needed under d))

            abs_dir=$(pwd)

c) Change into 'build' directory:

            cd build

d) Create make files and dependencies

            cmake   -DCOMPILER=intel   -DCMAKE_VERBOSE_MAKEFILE=ON    -DWORK_PREFIX=${abs_dir}/work    ${abs_dir}/project

e) Compile and create executable

            make work

You can add the key '-j4' to use 4 cores in parallel:

            make -j4 work



3) Modify the source code

Once you set the environment the variables $gemdyn and $rpnphy will get set, pointing to the source code in the environment:

 ${gemdyn}/src/*/*
 ${rpnphy}/src/*/*

You can check there which routines you want to modify. Once you know which routine(s) you want to modify go back into your "executable directory". Then "check out" all the routines you want to modify with:
     rde co subroutine.F90
or
     rde co comdeck.cdk

You can also check out several routines at the same time.
Once you modified or copied the routines you want you need to compile them and then recreate the executable, following points b) 2) to 4) above.


  • Aucune étiquette