Ignore:
Timestamp:
Jun 1, 2020, 7:58:31 PM (4 years ago)
Author:
Petra Seibert <petra.seibert [at) univie.ac.at>
Branches:
master, ctbto, dev
Children:
5bee29a
Parents:
5920b7f
Message:

changes related to makefile, structure and names of top-level sections

File:
1 edited

Legend:

Unmodified
Added
Removed
  • For_developers/Sphinx/source/Installation/local.rst

    rf20342a ra9d33f6  
    1111         
    1212   
    13 .. _Python 3: https://docs.python.org/3/
    14 .. _Python3: https://www.python.org/downloads/
    15 .. _Anaconda Python3: https://www.anaconda.com/distribution/#download-section
    16 
     13.. _Python3: https://www.python.org/
     14.. _Anaconda Python3: https://www.anaconda.com/distribution/
    1715.. _numpy: http://www.numpy.org/
    1816.. _ecmwf-api-client: https://confluence.ecmwf.int/display/WEBAPI/ECMWF+Web+API+Home
    1917.. _cdsapi: https://cds.climate.copernicus.eu/api-how-to
    2018.. _genshi: https://genshi.edgewall.org/
    21 .. _eccodes for python: https://packages.debian.org/sid/python3-eccodes
     19.. _eccodes for python: https://pypi.org/project/eccodes-python/
    2220.. _eccodes for conda: https://anaconda.org/conda-forge/eccodes
    2321.. _gfortran: https://gcc.gnu.org/wiki/GFortran
     
    3028.. _ECMWF ectrans site: https://confluence.ecmwf.int/display/ECAC/Unattended+file+transfer+-+ectrans
    3129.. _ECaccess Presentation: https://confluence.ecmwf.int/download/attachments/45759146/ECaccess.pdf
    32 .. _ECMWF's instructions on gateway server: https://confluence.ecmwf.int/display/ECAC/ECaccess+Home
     30.. _ECMWF instructions on gateway servers: https://confluence.ecmwf.int/display/ECAC/ECaccess+Home
    3331.. _Computing Representative: https://www.ecmwf.int/en/about/contact-us/computing-representatives
    3432.. _MARS access: https://confluence.ecmwf.int//display/WEBAPI/Access+MARS
    35 
    3633.. _download section: https://www.flexpart.eu/downloads
    3734
    38  
    39    
    40    
    41    
     35     
    4236.. _ref-local-mode:
    43 
    44 
    4537
    4638.. _ref-req-local:
     
    5446and libraries, since the preparation of the extraction and the post-processing is done on the local machine:
    5547
    56 +-------------------------------------------------+-----------------+
    57 |  Python part                                    | Fortran part    |
    58 +-------------------------------------------------+-----------------+
    59 | 1. `Python3`_                                   | 1. `gfortran`_  |
    60 | 2. `numpy`_                                     | 2. `fftw3`_     |
    61 | 3. `genshi`_                                    | 3. `eccodes`_   |
    62 | 4. `eccodes for python`_                        | 4. `emoslib`_   |
    63 | 5. `ecmwf-api-client`_ (everything except ERA5) |                 |
    64 | 6. `cdsapi`_ (just for ERA5 and member user)    |                 |
    65 +-------------------------------------------------+-----------------+
     48+------------------------------------------------+----------------+
     49|  Python code                                   | Fortran code   |
     50+------------------------------------------------+----------------+
     51| * `Python3`_                                   | * `gfortran`_  |
     52| * `numpy`_                                     | * `fftw3`_     |
     53| * `genshi`_                                    | * `eccodes`_   |
     54| * `eccodes for python`_                        | * `emoslib`_   |
     55| * `ecmwf-api-client`_ (everything except ERA5) |                |
     56| * `cdsapi`_ (just for ERA5 and member user)    |                |
     57+------------------------------------------------+----------------+
    6658
    6759
     
    265257
    266258
    267 
    268259.. _ref-install-local:
    269260
     
    271262==================
    272263
    273 First, adapt the Fortran ``makefile`` for your environment (if necessary) and insert it into ``setup.sh`` script (see :ref:`Fortran Makefile <ref-convert>` for more information).
    274 They can be found at ``flex_extract_vX.X/Source/Fortran/``, where ``vX.X`` should be substituted by the current flex_extract version number.
    275 
    276 .. caution::   
    277    It is necessary to adapt **ECCODES_INCLUDE_DIR** and **ECCODES_LIB** in these
    278    ``makefiles`` if other than standard paths are used.
    279 
    280 Thus, go to the ``Fortran`` source directory and open the ``makefile`` of your
    281 choice, and check / modify with an editor of your choice:
    282 
    283 .. code-block:: bash
    284 
    285    cd flex_extract_vX.X/Source/Fortran
    286    nedit makefile_fast
     264   
     265The Fortran program called ``calc_etadot`` will be compiled during the
     266installation process. A suitable makefile (``makefile_local_gfortran``) for the compilation is set by default.
     267This may be overwritten by the ``MAKEFILE`` parameter in ``setup.sh``.
     268
     269However, you may have to adapt the makefile for your environment (the current default makefile works on Debian stretch and similar GNU/Linux distributions). If you use a new name for it, you will have to insert it into ``setup.sh``
     270For details on the makefile and how to adapt them, see :ref:`Fortran Makefile <ref-convert>`.
     271
    287272 
    288 Set the paths to the ``eccodes`` library on your local machine, if necessary.
    289 
    290 .. caution::
    291    This can vary from system to system.
    292    It is suggested to use a command like
    293 
    294    .. code-block:: bash
    295 
    296       # for the ECCODES_INCLUDE_DIR path do:
    297       $ dpkg -L libeccodes-dev | grep eccodes.mod
    298       # for the ECCODES_LIB path do:
    299       $ dpkg -L libeccodes-dev | grep libeccodes.so
    300      
    301    to find out the path to the ``eccodes`` library.
    302    
    303 Assign these paths to the parameters **ECCODES_INCLUDE_DIR**
    304 and **ECCODES_LIB** in the makefile, and save it.
    305 
    306 .. code-block:: bash
    307 
    308    # these are the paths on Debian Buster:
    309    ECCODES_INCLUDE_DIR=/usr/lib/x86_64-linux-gnu/fortran/gfortran-mod-15/
    310    ECCODES_LIB= -L/usr/lib -leccodes_f90 -leccodes -lm 
    311    
    312    
    313 The Fortran program called ``calc_etadot`` will be compiled during the
    314 installation process. Therefore, the name of the ``makefile`` to be used needs to be given in  ``setup.sh``.
    315 
    316273In the root directory of ``flex_extract``, open the ``setup.sh`` script
    317274with an editor and adapt the installation parameters in the section labelled with
     
    330287   #
    331288   TARGET='local'
    332    MAKEFILE='makefile_fast'
    333289   ECUID=None
    334290   ECGID=None
     
    357313        Install flex_extract_v7.1 software at local in directory <path-to-flex_extract>/flex_extract_v7.1
    358314
    359         Using makefile: makefile_fast
     315        Using makefile: makefile_local_gfortran
    360316        gfortran   -O3 -march=native -Bstatic -leccodes_f90 -leccodes -Bdynamic -lm -ljasper -lemosR64 -I. -I/usr/local/include -fdefault-real-8 -fopenmp -fconvert=big-endian   -c     ./rwgrib2.f90
    361317        gfortran   -O3 -march=native -Bstatic -leccodes_f90 -leccodes -Bdynamic -lm -ljasper -lemosR64 -I. -I/usr/local/include -fdefault-real-8 -fopenmp -fconvert=big-endian   -c     ./phgrreal.f90
Note: See TracChangeset for help on using the changeset viewer.
hosted by ZAMG