mirror of https://github.com/ecmwf/eccodes.git
Variable for grib2 tables version added
This commit is contained in:
parent
c4b2a8687b
commit
e064b4dc95
|
@ -6,29 +6,30 @@ if(HAVE_INSTALL_ECCODES_SAMPLES)
|
||||||
PERMISSIONS OWNER_WRITE OWNER_READ GROUP_READ WORLD_READ )
|
PERMISSIONS OWNER_WRITE OWNER_READ GROUP_READ WORLD_READ )
|
||||||
# set to the newest GRIB2 tablesVersion
|
# set to the newest GRIB2 tablesVersion
|
||||||
if(NOT HAVE_MEMFS)
|
if(NOT HAVE_MEMFS)
|
||||||
|
set(GRB2TABVERS '30')
|
||||||
add_custom_target(set_grib2_latest_tables_version)
|
add_custom_target(set_grib2_latest_tables_version)
|
||||||
add_custom_command(TARGET set_grib2_latest_tables_version
|
add_custom_command(TARGET set_grib2_latest_tables_version
|
||||||
POST_BUILD
|
POST_BUILD
|
||||||
COMMAND bash -c "cd ${CMAKE_INSTALL_PREFIX}/${ECCODES_SAMPLES_SUFF}; for F in GRIB2.tmpl *_grib2.tmpl ; do grib_set -s tablesVersion=30 $F tmp; mv tmp $F; done"
|
COMMAND bash -c "cd ${CMAKE_INSTALL_PREFIX}/${ECCODES_SAMPLES_SUFF}; for F in GRIB2.tmpl *_grib2.tmpl ; do grib_set -s tablesVersion=${GRB2TABVERS} $F tmp; mv tmp $F; done"
|
||||||
VERBATIM
|
VERBATIM
|
||||||
WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${ECCODES_SAMPLES_SUFF}
|
WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${ECCODES_SAMPLES_SUFF}
|
||||||
)
|
)
|
||||||
add_custom_command(TARGET set_grib2_latest_tables_version
|
add_custom_command(TARGET set_grib2_latest_tables_version
|
||||||
POST_BUILD
|
POST_BUILD
|
||||||
COMMAND bash -c "cd ${CMAKE_INSTALL_PREFIX}/share/eccodes/ifs_samples/grib1_mlgrib2; for F in *_ml.tmpl ; do grib_set -s tablesVersion=30 $F tmp; mv tmp $F; done"
|
COMMAND bash -c "cd ${CMAKE_INSTALL_PREFIX}/share/eccodes/ifs_samples/grib1_mlgrib2; for F in *_ml.tmpl ; do grib_set -s tablesVersion=${GRB2TABVERS} $F tmp; mv tmp $F; done"
|
||||||
VERBATIM
|
VERBATIM
|
||||||
WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${ECCODES_SAMPLES_SUFF}
|
WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${ECCODES_SAMPLES_SUFF}
|
||||||
)
|
)
|
||||||
add_custom_command(TARGET set_grib2_latest_tables_version
|
add_custom_command(TARGET set_grib2_latest_tables_version
|
||||||
POST_BUILD
|
POST_BUILD
|
||||||
COMMAND bash -c "cd ${CMAKE_INSTALL_PREFIX}/share/eccodes/ifs_samples/grib1_mlgrib2_ieee64; for F in *_ml.tmpl ; do grib_set -s tablesVersion=30 $F tmp; mv tmp $F; done"
|
COMMAND bash -c "cd ${CMAKE_INSTALL_PREFIX}/share/eccodes/ifs_samples/grib1_mlgrib2_ieee64; for F in *_ml.tmpl ; do grib_set -s tablesVersion=${GRB2TABVERS} $F tmp; mv tmp $F; done"
|
||||||
VERBATIM
|
VERBATIM
|
||||||
WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${ECCODES_SAMPLES_SUFF}
|
WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${ECCODES_SAMPLES_SUFF}
|
||||||
)
|
)
|
||||||
if(HAVE_AEC)
|
if(HAVE_AEC)
|
||||||
add_custom_command(TARGET set_grib2_latest_tables_version
|
add_custom_command(TARGET set_grib2_latest_tables_version
|
||||||
POST_BUILD
|
POST_BUILD
|
||||||
COMMAND bash -c "cd ${CMAKE_INSTALL_PREFIX}/share/eccodes/ifs_samples/grib1_mlgrib2_ccsds; for F in *_ml.tmpl gg_sfc_grib2.tmpl ; do grib_set -s tablesVersion=30 $F tmp; mv tmp $F; done"
|
COMMAND bash -c "cd ${CMAKE_INSTALL_PREFIX}/share/eccodes/ifs_samples/grib1_mlgrib2_ccsds; for F in *_ml.tmpl gg_sfc_grib2.tmpl ; do grib_set -s tablesVersion=${GRB2TABVERS} $F tmp; mv tmp $F; done"
|
||||||
VERBATIM
|
VERBATIM
|
||||||
WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${ECCODES_SAMPLES_SUFF}
|
WORKING_DIRECTORY ${CMAKE_INSTALL_PREFIX}/${ECCODES_SAMPLES_SUFF}
|
||||||
)
|
)
|
||||||
|
|
Loading…
Reference in New Issue