From 72110692aa1b3da95919b0d4b04589ae6596d21e Mon Sep 17 00:00:00 2001 From: Jos de Kloe Date: Thu, 20 Sep 2018 08:57:01 +0200 Subject: [PATCH 01/18] add a line to run the problematic test on epel7 and dump the result is a log file --- eccodes.spec | 1 + 1 file changed, 1 insertion(+) diff --git a/eccodes.spec b/eccodes.spec index 483b989..78b905b 100644 --- a/eccodes.spec +++ b/eccodes.spec @@ -331,6 +331,7 @@ cd build # (unfortunately this issue is not public) LD_LIBRARY_PATH=%{buildroot}/%{_libdir} \ LIBRARY_PATH=%{buildroot}/%{_libdir} \ +ctest3 -V %{?_smp_mflags} -R eccodes_t_bufr_dump_encode_C > output_test_98_eccodes_t_bufr_dump_encode_C.log ctest3 -V %{?_smp_mflags} %files From 543ba24a4824ef51570629fdcb818f3620355917 Mon Sep 17 00:00:00 2001 From: Jos de Kloe Date: Thu, 20 Sep 2018 08:58:55 +0200 Subject: [PATCH 02/18] and enable the aarch64 case again ... --- eccodes.spec | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/eccodes.spec b/eccodes.spec index 78b905b..197d169 100644 --- a/eccodes.spec +++ b/eccodes.spec @@ -100,10 +100,10 @@ ExcludeArch: s390x # as explained in bugzilla #1562084 ExcludeArch: armv7hl -%if 0%{?rhel} >= 7 -# as explained in bugzilla #1629377 -ExcludeArch: aarch64 -%endif +#%if 0%%{?rhel} >= 7 +## as explained in bugzilla #1629377 +#ExcludeArch: aarch64 +#%%endif %description ecCodes is a package developed by ECMWF which provides an application From ca45d522790280600e64e647443e3cc9d375c83e Mon Sep 17 00:00:00 2001 From: Jos de Kloe Date: Thu, 20 Sep 2018 09:28:28 +0200 Subject: [PATCH 03/18] try again --- eccodes.spec | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/eccodes.spec b/eccodes.spec index 197d169..c94b0f9 100644 --- a/eccodes.spec +++ b/eccodes.spec @@ -329,10 +329,13 @@ cd build # so a patch has been added to solve this for now. # See: https://software.ecmwf.int/issues/browse/SUP-1812 # (unfortunately this issue is not public) +echo "------ START DEBUG OUTPUT" LD_LIBRARY_PATH=%{buildroot}/%{_libdir} \ LIBRARY_PATH=%{buildroot}/%{_libdir} \ -ctest3 -V %{?_smp_mflags} -R eccodes_t_bufr_dump_encode_C > output_test_98_eccodes_t_bufr_dump_encode_C.log -ctest3 -V %{?_smp_mflags} +ECCODES_TEST_VERBOSE_OUTPUT=1 ECCODES_DEBUG=1 \ +ctest3 -VV %{?_smp_mflags} -R eccodes_t_bufr_dump_encode_C > output_test_98_eccodes_t_bufr_dump_encode_C.log +echo "------ END DEBUG OUTPUT" +# ctest3 -V %%{?_smp_mflags} %files %license LICENSE From 563a940cd3b48e7c9e02d02ee4d531f64b85a9a6 Mon Sep 17 00:00:00 2001 From: Jos de Kloe Date: Thu, 20 Sep 2018 10:23:32 +0200 Subject: [PATCH 04/18] and try once more --- eccodes.spec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/eccodes.spec b/eccodes.spec index c94b0f9..31314d9 100644 --- a/eccodes.spec +++ b/eccodes.spec @@ -333,7 +333,7 @@ echo "------ START DEBUG OUTPUT" LD_LIBRARY_PATH=%{buildroot}/%{_libdir} \ LIBRARY_PATH=%{buildroot}/%{_libdir} \ ECCODES_TEST_VERBOSE_OUTPUT=1 ECCODES_DEBUG=1 \ -ctest3 -VV %{?_smp_mflags} -R eccodes_t_bufr_dump_encode_C > output_test_98_eccodes_t_bufr_dump_encode_C.log +ctest3 -VV %{?_smp_mflags} -R eccodes_t_bufr_dump_encode_C echo "------ END DEBUG OUTPUT" # ctest3 -V %%{?_smp_mflags} From 5be33312603acd8fb7216abe2def2dfac1c76986 Mon Sep 17 00:00:00 2001 From: Jos de Kloe Date: Thu, 20 Sep 2018 10:47:52 +0200 Subject: [PATCH 05/18] next try --- eccodes.spec | 1 - 1 file changed, 1 deletion(-) diff --git a/eccodes.spec b/eccodes.spec index 31314d9..05ea7f7 100644 --- a/eccodes.spec +++ b/eccodes.spec @@ -332,7 +332,6 @@ cd build echo "------ START DEBUG OUTPUT" LD_LIBRARY_PATH=%{buildroot}/%{_libdir} \ LIBRARY_PATH=%{buildroot}/%{_libdir} \ -ECCODES_TEST_VERBOSE_OUTPUT=1 ECCODES_DEBUG=1 \ ctest3 -VV %{?_smp_mflags} -R eccodes_t_bufr_dump_encode_C echo "------ END DEBUG OUTPUT" # ctest3 -V %%{?_smp_mflags} From eb84fd68e591acff2955aabcd3d9c6d8b3f8b303 Mon Sep 17 00:00:00 2001 From: Jos de Kloe Date: Thu, 20 Sep 2018 11:35:00 +0200 Subject: [PATCH 06/18] revert insertion of debug code --- eccodes.spec | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) diff --git a/eccodes.spec b/eccodes.spec index 05ea7f7..483b989 100644 --- a/eccodes.spec +++ b/eccodes.spec @@ -100,10 +100,10 @@ ExcludeArch: s390x # as explained in bugzilla #1562084 ExcludeArch: armv7hl -#%if 0%%{?rhel} >= 7 -## as explained in bugzilla #1629377 -#ExcludeArch: aarch64 -#%%endif +%if 0%{?rhel} >= 7 +# as explained in bugzilla #1629377 +ExcludeArch: aarch64 +%endif %description ecCodes is a package developed by ECMWF which provides an application @@ -329,12 +329,9 @@ cd build # so a patch has been added to solve this for now. # See: https://software.ecmwf.int/issues/browse/SUP-1812 # (unfortunately this issue is not public) -echo "------ START DEBUG OUTPUT" LD_LIBRARY_PATH=%{buildroot}/%{_libdir} \ LIBRARY_PATH=%{buildroot}/%{_libdir} \ -ctest3 -VV %{?_smp_mflags} -R eccodes_t_bufr_dump_encode_C -echo "------ END DEBUG OUTPUT" -# ctest3 -V %%{?_smp_mflags} +ctest3 -V %{?_smp_mflags} %files %license LICENSE From 1b35c600b0701c4493cdacc2bfc8e8fc34d4e15b Mon Sep 17 00:00:00 2001 From: Gwyn Ciesla Date: Tue, 17 Sep 2019 09:45:57 -0500 Subject: [PATCH 07/18] "Adding package.cfg file" --- package.cfg | 2 ++ 1 file changed, 2 insertions(+) create mode 100644 package.cfg diff --git a/package.cfg b/package.cfg new file mode 100644 index 0000000..66ea79d --- /dev/null +++ b/package.cfg @@ -0,0 +1,2 @@ +[koji] +targets = epel8 epel8-playground \ No newline at end of file From 78fe5405970a4fdacf622c066533c855c8c18dcf Mon Sep 17 00:00:00 2001 From: Jos de Kloe Date: Sun, 27 Oct 2019 15:42:17 +0100 Subject: [PATCH 08/18] updated to upstream version 2.14.1 --- .gitignore | 4 ++ README.md | 13 +++- eccodes-32bit.patch | 10 +-- eccodes-soversion.patch | 32 +++++---- eccodes.spec | 141 ++++++++++++++++++---------------------- 5 files changed, 100 insertions(+), 100 deletions(-) diff --git a/.gitignore b/.gitignore index ffbff0a..17470ea 100644 --- a/.gitignore +++ b/.gitignore @@ -6,3 +6,7 @@ /eccodes-2.9.0-Source.tar.gz /eccodes_test_data_20181010.tar.gz /eccodes-2.9.2-Source.tar.gz +/eccodes-2.12.0-Source.tar.gz +/eccodes-2.12.5-Source.tar.gz +/eccodes-2.13.0-Source.tar.gz +/eccodes-2.14.1-Source.tar.gz diff --git a/README.md b/README.md index df5cd52..035f9e0 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,14 @@ # eccodes -The eccodes package \ No newline at end of file +The eccodes package. + +EcCodes is a package developed by ECMWF which provides an application +programming interface and a set of tools for decoding and encoding +messages in the following formats: + + * WMO FM-92 GRIB edition 1 and edition 2 + * WMO FM-94 BUFR edition 3 and edition 4 + * WMO GTS abbreviated header (only decoding). + +For further details see: +https://confluence.ecmwf.int/display/ECC/What+is+ecCodes diff --git a/eccodes-32bit.patch b/eccodes-32bit.patch index 76fbedf..3f116e7 100644 --- a/eccodes-32bit.patch +++ b/eccodes-32bit.patch @@ -1,6 +1,6 @@ ---- eccodes-2.9.2-Source.orig/src/grib_api_prototypes.h 2018-11-09 15:55:26.000000000 +0100 -+++ eccodes-2.9.2-Source/src/grib_api_prototypes.h 2018-11-24 15:06:47.892920252 +0100 -@@ -869,8 +869,8 @@ double grib_ieeefloat_error(double x); +--- eccodes-2.14.1-Source.unchanged/src/grib_api_prototypes.h 2019-10-10 13:33:52.000000000 +0200 ++++ eccodes-2.14.1-Source/src/grib_api_prototypes.h 2019-10-27 11:20:05.496702520 +0100 +@@ -872,8 +872,8 @@ double grib_ieeefloat_error(double x); double grib_long_to_ieee(unsigned long x); int grib_nearest_smaller_ieee_float(double a, double *x); unsigned long grib_ieee_to_long(double x); @@ -11,8 +11,8 @@ int grib_ieee_decode_array(grib_context *c, unsigned char *buf, size_t nvals, int bytes, double *val); int grib_ieee_decode_array(grib_context *c, unsigned char *buf, size_t nvals, int bytes, double *val); int grib_ieee_encode_array(grib_context *c, double *val, size_t nvals, int bytes, unsigned char *buf); ---- eccodes-2.9.2-Source.orig/src/grib_ieeefloat.c 2018-11-09 15:55:26.000000000 +0100 -+++ eccodes-2.9.2-Source/src/grib_ieeefloat.c 2018-11-24 15:06:47.892920252 +0100 +--- eccodes-2.14.1-Source.unchanged/src/grib_ieeefloat.c 2019-10-10 13:33:52.000000000 +0200 ++++ eccodes-2.14.1-Source/src/grib_ieeefloat.c 2019-10-27 11:20:05.497702497 +0100 @@ -392,14 +392,14 @@ unsigned long grib_ieee_to_long(double x * grib_encode_unsigned_long. */ diff --git a/eccodes-soversion.patch b/eccodes-soversion.patch index e91210e..35edc92 100644 --- a/eccodes-soversion.patch +++ b/eccodes-soversion.patch @@ -1,25 +1,23 @@ ---- eccodes-2.7.0-Source.orig/fortran/CMakeLists.txt 2018-03-02 10:52:20.000000000 +0100 -+++ eccodes-2.7.0-Source/fortran/CMakeLists.txt 2018-03-10 10:16:43.847822505 +0100 -@@ -43,7 +43,8 @@ if( HAVE_FORTRAN ) +--- eccodes-2.14.1-Source.unchanged/fortran/CMakeLists.txt 2019-10-10 13:33:52.000000000 +0200 ++++ eccodes-2.14.1-Source/fortran/CMakeLists.txt 2019-10-27 11:25:48.269661718 +0100 +@@ -43,7 +43,9 @@ if( HAVE_FORTRAN ) ecbuild_add_library( TARGET eccodes_f90 SOURCES grib_fortran.c grib_f90.f90 eccodes_f90.f90 grib_kinds.h GENERATED grib_f90.f90 eccodes_f90.f90 - LIBS eccodes ) + LIBS eccodes + SOVERSION ${ECCODES_SOVERSION_F90}) - add_custom_command( TARGET eccodes_f90 POST_BUILD - COMMAND ${CMAKE_COMMAND} -E make_directory ${CMAKE_BINARY_DIR}/include - COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_Fortran_MODULE_DIRECTORY}/${CMAKE_CFG_INTDIR}/eccodes.mod ${CMAKE_BINARY_DIR}/include ---- eccodes-2.7.0-Source.orig/src/CMakeLists.txt 2018-03-02 10:52:20.000000000 +0100 -+++ eccodes-2.7.0-Source/src/CMakeLists.txt 2018-03-10 10:16:43.848822480 +0100 -@@ -435,8 +435,8 @@ ecbuild_add_library(TARGET eccodes - ${grib_api_srcs} ++ + if( DEFINED ecbuild_VERSION AND NOT ${ecbuild_VERSION} VERSION_LESS 3.1 ) + # Installed module directory is not in the PUBLIC INCLUDES! + target_include_directories( eccodes_f90 PUBLIC $ ) +--- eccodes-2.14.1-Source.unchanged/src/CMakeLists.txt 2019-10-10 13:33:52.000000000 +0200 ++++ eccodes-2.14.1-Source/src/CMakeLists.txt 2019-10-27 11:27:56.115531419 +0100 +@@ -438,6 +438,7 @@ ecbuild_add_library(TARGET eccodes GENERATED grib_api_version.c LIBS ${ECCODES_EXTRA_LIBRARIES} ${CMAKE_THREAD_LIBS_INIT} ${CMATH_LIBRARIES} -- TEMPLATES ${grib_api_extra_srcs}) -- -+ TEMPLATES ${grib_api_extra_srcs} -+ SOVERSION ${ECCODES_SOVERSION}) - - install( FILES grib_api.h eccodes.h eccodes_windef.h DESTINATION ${INSTALL_INCLUDE_DIR} ) - install( FILES ${CMAKE_CURRENT_BINARY_DIR}/eccodes_version.h DESTINATION ${INSTALL_INCLUDE_DIR} ) + TEMPLATES ${grib_api_extra_srcs} ++ SOVERSION ${ECCODES_SOVERSION} + INSTALL_HEADERS_LIST + grib_api.h + eccodes.h diff --git a/eccodes.spec b/eccodes.spec index adf3704..a139740 100644 --- a/eccodes.spec +++ b/eccodes.spec @@ -1,5 +1,5 @@ Name: eccodes -Version: 2.9.2 +Version: 2.14.1 Release: 1%{?dist} Summary: WMO data format decoding and encoding @@ -8,15 +8,22 @@ Summary: WMO data format decoding and encoding %global so_version_f90 0.1 %global datapack_date 20181010 -# latest rawhide grib_api version is 1.27.0-2 +# latest rawhide grib_api version is 1.27.0-5 # but this version number is to be updated as soon as we know # what the final release of grib_api by upstream will be. -# latest upstream grib_api release is 1.27.0 (09-Sep-2018) -%global final_grib_api_version 1.27.0-2 +# latest upstream grib_api release is 1.28.0 (05-Dec-2018) +# see https://confluence.ecmwf.int/display/GRIB/Home +%global final_grib_api_version 1.28.1-1%{?dist} + +%ifarch i686 ppc64 s390x armv7hl + %global obsolete_grib_api 0 +%else + %global obsolete_grib_api 1 +%endif # license remarks: -# most of eccodes is licensed ASL 2.0 but a special case must be noted. -# these 2 files: +# Most of eccodes is licensed ASL 2.0 but a special case must be noted. +# These 2 files: # src/grib_yacc.c # src/grib_yacc.h # contain a special exception clause that allows them to be @@ -37,11 +44,6 @@ Patch1: eccodes-32bit.patch # Add soversion to the shared libraries, since upstream refuses to do so # https://software.ecmwf.int/issues/browse/SUP-1809 Patch2: eccodes-soversion.patch -# remove rpath from cmake/pkg-config.pc.in -Patch3: eccodes-rpath.patch -# fix compile flags in fortran checks -# this is needed due to rpath removal -Patch4: eccodes-fortran-check.patch # note that the requests to make the other issues public are filed here: # https://software.ecmwf.int/issues/browse/SUP-2073 @@ -55,16 +57,14 @@ BuildRequires: jasper-devel BuildRequires: libjpeg-devel BuildRequires: libpng-devel BuildRequires: netcdf-devel -BuildRequires: numpy BuildRequires: openjpeg2-devel -# BuildRequires: python2-devel # For tests BuildRequires: perl(Getopt::Long) BuildRequires: perl(Test::More) # the data is needed by the library and all tools provided in the main package -# the other way arpund, the data package could be installed without +# the other way around, the data package could be installed without # installing the base package. It will probably be pretty useless, # unless a user wishes to read and study all these grib and bufr # file format definitions. @@ -85,7 +85,11 @@ Requires: %{name}-data = %{version}-%{release} # "Please note that GRIB-API support is being discontinued at the end of 2018." # So the old grib_api will need to be obsoleted. +%if 0%{obsolete_grib_api} +# as stated in the note above, setting provides seems not correct here +# Provides: grib_api = %%{final_grib_api_version} Obsoletes: grib_api < %{final_grib_api_version} +%endif # as explained in bugzilla #1562066 ExcludeArch: i686 @@ -113,8 +117,7 @@ in the following formats: * WMO GTS abbreviated header (only decoding). A useful set of command line tools provide quick access to the messages. C, -Fortran 90 and Python (1) interfaces provide access to the main ecCodes -functionality. +and Fortran 90 interfaces provide access to the main ecCodes functionality. ecCodes is an evolution of GRIB-API. It is designed to provide the user with a simple set of functions to access data from several formats with a key/value @@ -122,7 +125,7 @@ approach. For GRIB encoding and decoding, the GRIB-API functionality is provided fully in ecCodes with only minor interface and behaviour changes. Interfaces for C, -Fortran 90 and Python (1) are all maintained as in GRIB-API. However, the +and Fortran 90 are all maintained as in GRIB-API. However, the GRIB-API Fortran 77 interface is no longer available. In addition, a new set of functions with the prefix "codes_" is provided to @@ -137,12 +140,6 @@ and behaviour. A significant difference compared with GRIB-API tools is that bufr_dump produces output in JSON format suitable for many web based applications. -(1) Note: for now only a python2 interface is provided by upstream, -and since Fedora is phasing out python2 this interface has -been removed from this package starting with Fedora 30. -As soon as upstream provides a python3 interface that one will -be added here. - ##################################################### %package devel Summary: Contains ecCodes development files @@ -150,28 +147,14 @@ Requires: %{name}%{?_isa} = %{version}-%{release} Requires: gcc-gfortran%{?_isa} Requires: jasper-devel%{?_isa} +%if 0%{obsolete_grib_api} +# Provides: grib_api-devel = %%{final_grib_api_version} Obsoletes: grib_api-devel < %{final_grib_api_version} +%endif %description devel Header files and libraries for ecCodes. -##################################################### -#%%package -n python2-%%{name} -#Summary: A python2 interface to ecCodes -#Requires: %%{name}%%{?_isa} = %%{version}-%%{release} -#Requires: gcc-gfortran%%{?_isa} -#Requires: jasper-devel%%{?_isa} -# -## a sub package python2-grib_api did not exist -## so no obsoletes needed here -# -#%%description -n python2-%%{name} -#A python2 interface to ecCodes. Also a legacy interface to gribapi is provided. - -##################################################### -# note: python3 is not yet supported by eccodes -# but upstream intents to make it available before the end of 2018 - ##################################################### %package data Summary: Data needed by the eccodes library and tools @@ -194,13 +177,7 @@ BuildArch: noarch %description doc This package contains the html documentation for ecCodes and a fair number of example programs and scripts to use it -in C, Fortran 90, and Python (1). - -(1) Note: for now only a python2 interface is provided by upstream, -and since Fedora is phasing out python2 this interface has -been removed from this package starting with Fedora 30. -As soon as upstream provides a python3 interface that one will -be added here. +in C, and Fortran 90. ##################################################### %prep @@ -236,25 +213,38 @@ cd build # * ECCODES_OMP_THREADS , enable OMP threads # * EXTRA_TESTS , enable extended regression testing # +#-- The following features are set to AUTO by default and +# explicitely switched on to ensure they don't vanish unnoticed +# in case of dependency problems during the build: +# * ENABLE_JPG +# ^ ENABLE_FORTRAN +# * ENABLE_NETCDF +# NetCDF is only needed to create the grib_to_netcdf convert tool +# +# * ENABLE_PYTHON has value AUTO as default, so if python2 is available +# during a package build it will build an interface for it. +# To make sure it does not do so, explicitely switch it off. +# Python3 support has been moved to an additional project now, +# so python handling has been removed completely from this spec file. +# #-- Also add an explicit option to not use rpath # # Note: -DINSTALL_LIB_DIR=%%{_lib} is needed because otherwise # the library so files get installed in /usr/lib in stead # of /usr/lib64 on x86_64. -# Note: -DPYTHON_EXECUTABLE was added to prevent deprecation warnings -# during running of tests which breaks -# Test #184: eccodes_p_grib_keys_iterator_test %cmake3 -DINSTALL_LIB_DIR=%{_lib} \ -DENABLE_ECCODES_OMP_THREADS=ON \ -DENABLE_EXTRA_TESTS=ON \ + -DENABLE_JPG=ON \ -DENABLE_PNG=ON \ - -DCMAKE_SKIP_RPATH=TRUE \ + -DENABLE_FORTRAN=ON \ + -DENABLE_NETCDF=ON \ + -DCMAKE_SKIP_INSTALL_RPATH=TRUE \ -DECCODES_SOVERSION=%{so_version} \ -DECCODES_SOVERSION_F90=%{so_version_f90} \ -DENABLE_PYTHON=OFF \ .. -# -DPYTHON_EXECUTABLE=%%{_bindir}/python2 \ %make_build @@ -292,19 +282,26 @@ mkdir -p %{buildroot}%{_datadir}/doc/%{name}/examples/C cp examples/C/*.c %{buildroot}%{_datadir}/doc/%{name}/examples/C mkdir -p %{buildroot}%{_datadir}/doc/%{name}/examples/F90 cp examples/F90/*.f90 %{buildroot}%{_datadir}/doc/%{name}/examples/F90 -#mkdir -p %%{buildroot}%%{_datadir}/doc/%%{name}/examples/python -#cp examples/python/*.py %%{buildroot}%%{_datadir}/doc/%%{name}/examples/python -#cp examples/python/*.c %%{buildroot}%%{_datadir}/doc/%%{name}/examples/python -#cp examples/python/*.csv %%{buildroot}%%{_datadir}/doc/%%{name}/examples/python -# adapt a shebang to make it point explicitely to python2 -#sed -i -e 's/\/bin\/env python/\/usr\/bin\/python2/' \ -# %%{buildroot}%%{_datadir}/doc/%%{name}/examples/python/high_level_api.py +# also not needed for x86_64 +# maybe they fixed it for all archs? +#%%ifarch i686 armv7hl +# # pass (nothing to do) +#%%else +# # it seems pkgconfig files end up in lib in stead of lib64 now +# # so move them to the right place +# mv %%{buildroot}/%%{_usr}/lib/pkgconfig/ \ +# %%{buildroot}/%%{_libdir}/pkgconfig/ +#%%endif -# move cmake files to the cmake folder below libdir -# as suggested in the review request -mkdir -p %{buildroot}%{_libdir}/cmake/%{name}/ -mv %{buildroot}%{_datadir}/%{name}/cmake/* %{buildroot}%{_libdir}/cmake/%{name}/ +# It seems the cmake options +# -DCMAKE_SKIP_RPATH=TRUE +# -DCMAKE_SKIP_INSTALL_RPATH=TRUE +# have no effect on the generated *.pc files. +# These still contain an rpath reference, so patch them and remove +# the rpath using sed +sed -i 's|^libs=.*$|libs=-L${libdir} -leccodes|g' %{buildroot}/%{_libdir}/pkgconfig/eccodes.pc +sed -i 's|^libs=.*$|libs=-L${libdir} -leccodes_f90 -leccodes|g' %{buildroot}/%{_libdir}/pkgconfig/eccodes_f90.pc %ldconfig_scriptlets @@ -319,29 +316,17 @@ cd build # 'eccodes_t_bufr_dump_(de|en)code_C' tests run. # These tests compile on the fly generated C code, and # without this setting the loader does not find the libraries. -# -# These fail due to build flag issues, i.e. the test script does a -# test build of some on the fly generated fortran code, but cannot -# find the necessary *.mod fortran module definition files. -# There is no easy way to define this as environment setting, -# so a patch has been added to solve this for now. -# See: https://software.ecmwf.int/issues/browse/SUP-1812 -# (unfortunately this issue is not public) + LD_LIBRARY_PATH=%{buildroot}/%{_libdir} \ LIBRARY_PATH=%{buildroot}/%{_libdir} \ ctest3 -V %{?_smp_mflags} %files %license LICENSE -%doc README ChangeLog AUTHORS +%doc README.md ChangeLog AUTHORS NEWS NOTICE %{_bindir}/* %{_libdir}/*.so.* -#%%files -n python2-%%{name} -#%%{python2_sitearch}/%%{name} -#%%{python2_sitearch}/%%{name}-*-py*.egg-info -#%%{python2_sitearch}/gribapi - %files devel %{_includedir}/* %{_fmoddir}/%{name}.mod @@ -362,6 +347,8 @@ ctest3 -V %{?_smp_mflags} %doc %{_datadir}/doc/%{name}/ %changelog +* Sun Oct 27 2019 Jos de Kloe - 2.14.1-1 +- Upgrade to upstream version 2.14.1 * Sat Nov 24 2018 Jos de Kloe - 2.9.2-1 - Upgrade to upstream version 2.9.2 From 82b0b3cbf1580f76b182a1671ec31ade45de0c9c Mon Sep 17 00:00:00 2001 From: Jos de Kloe Date: Sun, 27 Oct 2019 15:48:06 +0100 Subject: [PATCH 09/18] first epel8 version --- .gitignore | 1 + eccodes-32bit.patch | 8 ++--- eccodes-soversion.patch | 32 ++++++++--------- eccodes.spec | 77 ++++++++++++----------------------------- 4 files changed, 42 insertions(+), 76 deletions(-) diff --git a/.gitignore b/.gitignore index d516662..1b658ad 100644 --- a/.gitignore +++ b/.gitignore @@ -3,3 +3,4 @@ /eccodes-2.12.0-Source.tar.gz /eccodes-2.12.5-Source.tar.gz /eccodes-2.13.0-Source.tar.gz +/eccodes-2.14.1-Source.tar.gz diff --git a/eccodes-32bit.patch b/eccodes-32bit.patch index 6161926..3f116e7 100644 --- a/eccodes-32bit.patch +++ b/eccodes-32bit.patch @@ -1,5 +1,5 @@ ---- eccodes-2.13.0-Source.orig/src/grib_api_prototypes.h 2019-07-08 14:06:45.000000000 +0200 -+++ eccodes-2.13.0-Source/src/grib_api_prototypes.h 2019-07-25 12:58:22.124808129 +0200 +--- eccodes-2.14.1-Source.unchanged/src/grib_api_prototypes.h 2019-10-10 13:33:52.000000000 +0200 ++++ eccodes-2.14.1-Source/src/grib_api_prototypes.h 2019-10-27 11:20:05.496702520 +0100 @@ -872,8 +872,8 @@ double grib_ieeefloat_error(double x); double grib_long_to_ieee(unsigned long x); int grib_nearest_smaller_ieee_float(double a, double *x); @@ -11,8 +11,8 @@ int grib_ieee_decode_array(grib_context *c, unsigned char *buf, size_t nvals, int bytes, double *val); int grib_ieee_decode_array(grib_context *c, unsigned char *buf, size_t nvals, int bytes, double *val); int grib_ieee_encode_array(grib_context *c, double *val, size_t nvals, int bytes, unsigned char *buf); ---- eccodes-2.13.0-Source.orig/src/grib_ieeefloat.c 2019-07-08 14:06:45.000000000 +0200 -+++ eccodes-2.13.0-Source/src/grib_ieeefloat.c 2019-07-25 12:58:22.125808103 +0200 +--- eccodes-2.14.1-Source.unchanged/src/grib_ieeefloat.c 2019-10-10 13:33:52.000000000 +0200 ++++ eccodes-2.14.1-Source/src/grib_ieeefloat.c 2019-10-27 11:20:05.497702497 +0100 @@ -392,14 +392,14 @@ unsigned long grib_ieee_to_long(double x * grib_encode_unsigned_long. */ diff --git a/eccodes-soversion.patch b/eccodes-soversion.patch index 5db7e7b..35edc92 100644 --- a/eccodes-soversion.patch +++ b/eccodes-soversion.patch @@ -1,25 +1,23 @@ ---- eccodes-2.13.0-Source.orig/fortran/CMakeLists.txt 2019-07-08 14:06:44.000000000 +0200 -+++ eccodes-2.13.0-Source/fortran/CMakeLists.txt 2019-07-25 12:58:27.343673693 +0200 -@@ -43,7 +43,8 @@ if( HAVE_FORTRAN ) +--- eccodes-2.14.1-Source.unchanged/fortran/CMakeLists.txt 2019-10-10 13:33:52.000000000 +0200 ++++ eccodes-2.14.1-Source/fortran/CMakeLists.txt 2019-10-27 11:25:48.269661718 +0100 +@@ -43,7 +43,9 @@ if( HAVE_FORTRAN ) ecbuild_add_library( TARGET eccodes_f90 SOURCES grib_fortran.c grib_f90.f90 eccodes_f90.f90 grib_kinds.h GENERATED grib_f90.f90 eccodes_f90.f90 - LIBS eccodes ) + LIBS eccodes + SOVERSION ${ECCODES_SOVERSION_F90}) - add_custom_command( TARGET eccodes_f90 POST_BUILD - COMMAND ${CMAKE_COMMAND} -E make_directory ${CMAKE_BINARY_DIR}/include - COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_Fortran_MODULE_DIRECTORY}/${CMAKE_CFG_INTDIR}/eccodes.mod ${CMAKE_BINARY_DIR}/include ---- eccodes-2.13.0-Source.orig/src/CMakeLists.txt 2019-07-08 14:06:45.000000000 +0200 -+++ eccodes-2.13.0-Source/src/CMakeLists.txt 2019-07-25 12:58:27.343673693 +0200 -@@ -437,8 +437,8 @@ ecbuild_add_library(TARGET eccodes - ${grib_api_srcs} ++ + if( DEFINED ecbuild_VERSION AND NOT ${ecbuild_VERSION} VERSION_LESS 3.1 ) + # Installed module directory is not in the PUBLIC INCLUDES! + target_include_directories( eccodes_f90 PUBLIC $ ) +--- eccodes-2.14.1-Source.unchanged/src/CMakeLists.txt 2019-10-10 13:33:52.000000000 +0200 ++++ eccodes-2.14.1-Source/src/CMakeLists.txt 2019-10-27 11:27:56.115531419 +0100 +@@ -438,6 +438,7 @@ ecbuild_add_library(TARGET eccodes GENERATED grib_api_version.c LIBS ${ECCODES_EXTRA_LIBRARIES} ${CMAKE_THREAD_LIBS_INIT} ${CMATH_LIBRARIES} -- TEMPLATES ${grib_api_extra_srcs}) -- -+ TEMPLATES ${grib_api_extra_srcs} -+ SOVERSION ${ECCODES_SOVERSION}) - - install( FILES grib_api.h eccodes.h eccodes_windef.h DESTINATION ${INSTALL_INCLUDE_DIR} ) - install( FILES ${CMAKE_CURRENT_BINARY_DIR}/eccodes_version.h DESTINATION ${INSTALL_INCLUDE_DIR} ) + TEMPLATES ${grib_api_extra_srcs} ++ SOVERSION ${ECCODES_SOVERSION} + INSTALL_HEADERS_LIST + grib_api.h + eccodes.h diff --git a/eccodes.spec b/eccodes.spec index a6832dd..7af4ec0 100644 --- a/eccodes.spec +++ b/eccodes.spec @@ -1,6 +1,6 @@ Name: eccodes -Version: 2.13.0 -Release: 2%{?dist} +Version: 2.14.1 +Release: 1%{?dist} Summary: WMO data format decoding and encoding # force the shared libraries to have these so versions @@ -8,7 +8,7 @@ Summary: WMO data format decoding and encoding %global so_version_f90 0.1 %global datapack_date 20181010 -# latest rawhide grib_api version is 1.27.0-4 +# latest rawhide grib_api version is 1.27.0-5 # but this version number is to be updated as soon as we know # what the final release of grib_api by upstream will be. # latest upstream grib_api release is 1.28.0 (05-Dec-2018) @@ -86,7 +86,8 @@ Requires: %{name}-data = %{version}-%{release} # So the old grib_api will need to be obsoleted. %if 0%{obsolete_grib_api} -Provides: grib_api = %{final_grib_api_version} +# as stated in the note above, setting provides seems not correct here +# Provides: grib_api = %%{final_grib_api_version} Obsoletes: grib_api < %{final_grib_api_version} %endif @@ -94,8 +95,8 @@ Obsoletes: grib_api < %{final_grib_api_version} ExcludeArch: i686 # as explained in bugzilla #1562071 # note: this is no longer part of fc30/rawhide -# but the exclude is still needed for EPEL-7 -#ExcludeArch: ppc64 +# but the exclude is still needed for EPEL-7 and EPEL-8 +ExcludeArch: ppc64 # as explained in bugzilla #1562076 ExcludeArch: s390x # as explained in bugzilla #1562084 @@ -147,7 +148,7 @@ Requires: gcc-gfortran%{?_isa} Requires: jasper-devel%{?_isa} %if 0%{obsolete_grib_api} -Provides: grib_api-devel = %{final_grib_api_version} +# Provides: grib_api-devel = %%{final_grib_api_version} Obsoletes: grib_api-devel < %{final_grib_api_version} %endif @@ -244,10 +245,6 @@ cd build -DECCODES_SOVERSION_F90=%{so_version_f90} \ -DENABLE_PYTHON=OFF \ .. -# note: -# with -DCMAKE_SKIP_RPATH=TRUE -# LD_LIBRARY_PATH and #LIBRARY_PATH need to be defined before running ctest. -# with -DCMAKE_SKIP_INSTALL_RPATH=TRUE this seems not needed %make_build @@ -286,14 +283,16 @@ cp examples/C/*.c %{buildroot}%{_datadir}/doc/%{name}/examples/C mkdir -p %{buildroot}%{_datadir}/doc/%{name}/examples/F90 cp examples/F90/*.f90 %{buildroot}%{_datadir}/doc/%{name}/examples/F90 -%ifarch i686 armv7hl - # pass (nothing to do) -%else - # it seems pkgconfig files end up in lib in stead of lib64 now - # so move them to the right place - mv %{buildroot}/%{_usr}/lib/pkgconfig/ \ - %{buildroot}/%{_libdir}/pkgconfig/ -%endif +# also not needed for x86_64 +# maybe they fixed it for all archs? +#%%ifarch i686 armv7hl +# # pass (nothing to do) +#%%else +# # it seems pkgconfig files end up in lib in stead of lib64 now +# # so move them to the right place +# mv %%{buildroot}/%%{_usr}/lib/pkgconfig/ \ +# %%{buildroot}/%%{_libdir}/pkgconfig/ +#%%endif # It seems the cmake options # -DCMAKE_SKIP_RPATH=TRUE @@ -317,18 +316,9 @@ cd build # 'eccodes_t_bufr_dump_(de|en)code_C' tests run. # These tests compile on the fly generated C code, and # without this setting the loader does not find the libraries. -# -# These fail due to build flag issues, i.e. the test script does a -# test build of some on the fly generated fortran code, but cannot -# find the necessary *.mod fortran module definition files. -# There is no easy way to define this as environment setting, -# so a patch has been added to solve this for now. -# See: https://software.ecmwf.int/issues/browse/SUP-1812 -# (unfortunately this issue is not public) - -#LD_LIBRARY_PATH=%%{buildroot}/%%{_libdir} \ -#LIBRARY_PATH=%%{buildroot}/%%{_libdir} \ +LD_LIBRARY_PATH=%{buildroot}/%{_libdir} \ +LIBRARY_PATH=%{buildroot}/%{_libdir} \ ctest3 -V %{?_smp_mflags} %files @@ -357,31 +347,8 @@ ctest3 -V %{?_smp_mflags} %doc %{_datadir}/doc/%{name}/ %changelog -* Sat Aug 10 2019 Jos de Kloe - 2.13.0-2 -- apply bugfix to pc files contribuited by Emanuele Di Giacomo - -* Thu Jul 25 2019 Jos de Kloe - 2.13.0-1 -- Upgrade to upstream version 2.13.0 - -* Wed Jul 24 2019 Fedora Release Engineering - 2.12.5-2 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild - -* Thu May 09 2019 Jos de Kloe - 2.12.5-1 -- Upgrade to upstream version 2.12.5 - -* Mon Mar 18 2019 Orion Poplawski - 2.12.0-3 -- Rebuild for netcdf 4.6.3 - -* Thu Feb 21 2019 Jos de Kloe - 2.12.0-2 -- bump final_grib_api_version global variable to 1.27.1, so just above the - actual final version, to prevent the obsoletes to be disabled if the release - gets bumped. See BZ #1677968 - -* Sun Feb 17 2019 Jos de Kloe - 2.12.0-1 -- Upgrade to upstream version 2.12.0 - -* Thu Jan 31 2019 Fedora Release Engineering - 2.9.2-2 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild +* Sun Oct 27 2019 Jos de Kloe - 2.14.1-1 +- Upgrade to upstream version 2.14.1 * Sat Nov 24 2018 Jos de Kloe - 2.9.2-1 - Upgrade to upstream version 2.9.2 From e282745de3acaaa452c81c220cde69adb3a12af3 Mon Sep 17 00:00:00 2001 From: Jos de Kloe Date: Sun, 27 Oct 2019 15:50:05 +0100 Subject: [PATCH 10/18] update sources list --- .gitignore | 6 ------ sources | 8 ++++---- 2 files changed, 4 insertions(+), 10 deletions(-) diff --git a/.gitignore b/.gitignore index 17470ea..1b658ad 100644 --- a/.gitignore +++ b/.gitignore @@ -1,11 +1,5 @@ -/eccodes-2.7.0-Source.tar.gz /eccodes_test_data.tar.gz -/eccodes-2.7.3-Source.tar.gz -/eccodes-2.8.0-Source.tar.gz -/eccodes-2.8.2-Source.tar.gz -/eccodes-2.9.0-Source.tar.gz /eccodes_test_data_20181010.tar.gz -/eccodes-2.9.2-Source.tar.gz /eccodes-2.12.0-Source.tar.gz /eccodes-2.12.5-Source.tar.gz /eccodes-2.13.0-Source.tar.gz diff --git a/sources b/sources index 7b2c40f..f646642 100644 --- a/sources +++ b/sources @@ -1,5 +1,5 @@ -SHA512 (eccodes-2.8.2-Source.tar.gz) = 942de24390df9de64a768e2f351c9acef5b0550a59695016b9753b22fbff260f8a6f9780240dbb2402bec372ee4c8224a68f3d70699a5df42b23c0a4c073114d -SHA512 (eccodes_test_data.tar.gz) = 0f13137584525f12e184068501cc13a58fb8bb16ada680ca7f1575c6066fd2bc5995ec7afffb175c38958e71d991cea4b3972ad01402b54d2550e442241ffc7b -SHA512 (eccodes-2.9.0-Source.tar.gz) = c485255d85d78600fbb4828d9d6eaf2e03a425b7eb8fe5cb1a5f5f822df8b830eddeaa06013327ca1f7247b0012e1ee78814a164a5ccf4b1e90c1a62a35431ea SHA512 (eccodes_test_data_20181010.tar.gz) = 24c24ec9e01d230cf542abe5c131f05b8e627dd9d170c666628bb5fd8f7b1a6aa11a35456b8d742c59f54c6aabac78658efd68b0c50779d466aba3d35b4a0231 -SHA512 (eccodes-2.9.2-Source.tar.gz) = 94d077bb0f348c4d64883a4f0877439c123786c73d2b64e4bdfb3f7eb28e445ff1e0eeb57140261906b8aef8e22fd3d614528f1821877ebe6bcb9d38393921d9 +SHA512 (eccodes-2.12.0-Source.tar.gz) = 3dc876bde2a6c81a43bcc64ecb12969f28eae3cfbc8fed7da7797fc722dc8b446ac7be5178f55b7d395653e0718437b842296a7d4d11b372b8692404c76aa4ad +SHA512 (eccodes-2.12.5-Source.tar.gz) = ab1267dffdb3d0dbcdd65f23db2d77bc7bd8f3241083374c75bc62ebf70b7d29d8af9f657d6da05a47e363151c8d995adfadca7bbf95ebb24a27303d80f081a4 +SHA512 (eccodes-2.13.0-Source.tar.gz) = bbde1b7092caad20772b21cd06040938f99e763f77a6622820e3cc2fba5c0765178822be4b3c33b41a927757da85f311c0c4f057500ca58d257dde304e7eeca3 +SHA512 (eccodes-2.14.1-Source.tar.gz) = 864b530642884baa0c3c56eee646a61af7d659e711c7ed4d08a5cc2d68812ecb96b8efabf40c4c9d5dcb3a0edeb1caddffea2ec3438571d3e90dc9cca1dabebe From 9d279afcaef9443fa03d95f8a869ca5b786b529f Mon Sep 17 00:00:00 2001 From: Jos de Kloe Date: Sun, 27 Oct 2019 15:52:56 +0100 Subject: [PATCH 11/18] updated sources list --- sources | 1 + 1 file changed, 1 insertion(+) diff --git a/sources b/sources index 0f7be28..f646642 100644 --- a/sources +++ b/sources @@ -2,3 +2,4 @@ SHA512 (eccodes_test_data_20181010.tar.gz) = 24c24ec9e01d230cf542abe5c131f05b8e6 SHA512 (eccodes-2.12.0-Source.tar.gz) = 3dc876bde2a6c81a43bcc64ecb12969f28eae3cfbc8fed7da7797fc722dc8b446ac7be5178f55b7d395653e0718437b842296a7d4d11b372b8692404c76aa4ad SHA512 (eccodes-2.12.5-Source.tar.gz) = ab1267dffdb3d0dbcdd65f23db2d77bc7bd8f3241083374c75bc62ebf70b7d29d8af9f657d6da05a47e363151c8d995adfadca7bbf95ebb24a27303d80f081a4 SHA512 (eccodes-2.13.0-Source.tar.gz) = bbde1b7092caad20772b21cd06040938f99e763f77a6622820e3cc2fba5c0765178822be4b3c33b41a927757da85f311c0c4f057500ca58d257dde304e7eeca3 +SHA512 (eccodes-2.14.1-Source.tar.gz) = 864b530642884baa0c3c56eee646a61af7d659e711c7ed4d08a5cc2d68812ecb96b8efabf40c4c9d5dcb3a0edeb1caddffea2ec3438571d3e90dc9cca1dabebe From a9b3d7b5ad87f3428e422d854a4acacc5eae9df8 Mon Sep 17 00:00:00 2001 From: Jos de Kloe Date: Sat, 27 Jun 2020 14:20:30 +0200 Subject: [PATCH 12/18] adapt to epel8 --- eccodes.spec | 62 +++++++++------------------------------------------- 1 file changed, 10 insertions(+), 52 deletions(-) diff --git a/eccodes.spec b/eccodes.spec index a96498e..a959afb 100644 --- a/eccodes.spec +++ b/eccodes.spec @@ -1,6 +1,6 @@ Name: eccodes Version: 2.18.0 -Release: 2%{?dist} +Release: 1%{?dist} Summary: WMO data format decoding and encoding # force the shared libraries to have these so versions @@ -94,11 +94,20 @@ Obsoletes: grib_api < %{final_grib_api_version} # as explained in bugzilla #1562066 ExcludeArch: i686 +# as explained in bugzilla #1562071 +# note: this is no longer part of fc30/rawhide +# but the exclude is still needed for EPEL-7 and EPEL-8 +ExcludeArch: ppc64 # as explained in bugzilla #1562076 ExcludeArch: s390x # as explained in bugzilla #1562084 ExcludeArch: armv7hl +%if 0%{?rhel} >= 7 +# as explained in bugzilla #1629377 +ExcludeArch: aarch64 +%endif + %description ecCodes is a package developed by ECMWF which provides an application programming interface and a set of tools for decoding and encoding messages @@ -225,14 +234,6 @@ cd build # the library so files get installed in /usr/lib in stead # of /usr/lib64 on x86_64. -# Build with -fallow-argument-mismatch for gcc 10 compatibility -# otherwise the fortran interface fails to compile -# (thanks for the hint Orion) -# Reported upstream at https://jira.ecmwf.int/browse/SUP-3081 -# note that setting FCFLAGS is not sufficient, i.e. this doesn't work: -# export FCFLAGS="%%{build_fflags} -fallow-argument-mismatch" -# defining the -DCMAKE_Fortran_FLAGS for camke is required to let it compile. - %cmake3 -DINSTALL_LIB_DIR=%{_lib} \ -DENABLE_ECCODES_OMP_THREADS=ON \ -DENABLE_EXTRA_TESTS=ON \ @@ -243,7 +244,6 @@ cd build -DCMAKE_SKIP_INSTALL_RPATH=TRUE \ -DECCODES_SOVERSION=%{so_version} \ -DECCODES_SOVERSION_F90=%{so_version_f90} \ - -DCMAKE_Fortran_FLAGS="-fallow-argument-mismatch" \ -DENABLE_PYTHON=OFF \ .. @@ -348,54 +348,12 @@ ctest3 -V %{?_smp_mflags} %doc %{_datadir}/doc/%{name}/ %changelog -* Sat Jun 27 2020 Jos de Kloe - 2.18.0-2 -- Rebuild after fixing mistake in ExcludeArch statements - * Sat Jun 27 2020 Jos de Kloe - 2.18.0-1 - Upgrade to upstream version 2.18.0 -* Sun Mar 15 2020 Jos de Kloe - 2.17.0-1 -- Upgrade to upstream version 2.17.0 -- Add explcit BR to perl(File::Compare) as needed by the tests now - -* Sat Feb 08 2020 Jos de Kloe - 2.16.0-1 -- Upgrade to upstream version 2.16.0 - -* Tue Jan 28 2020 Fedora Release Engineering - 2.15.0-2 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild - -* Sun Dec 15 2019 Jos de Kloe - 2.15.0-1 -- Upgrade to upstream version 2.15.0 - * Sun Oct 27 2019 Jos de Kloe - 2.14.1-1 - Upgrade to upstream version 2.14.1 -* Sat Aug 10 2019 Jos de Kloe - 2.13.0-2 -- apply bugfix to pc files contribuited by Emanuele Di Giacomo - -* Thu Jul 25 2019 Jos de Kloe - 2.13.0-1 -- Upgrade to upstream version 2.13.0 - -* Wed Jul 24 2019 Fedora Release Engineering - 2.12.5-2 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild - -* Thu May 09 2019 Jos de Kloe - 2.12.5-1 -- Upgrade to upstream version 2.12.5 - -* Mon Mar 18 2019 Orion Poplawski - 2.12.0-3 -- Rebuild for netcdf 4.6.3 - -* Thu Feb 21 2019 Jos de Kloe - 2.12.0-2 -- bump final_grib_api_version global variable to 1.27.1, so just above the - actual final version, to prevent the obsoletes to be disabled if the release - gets bumped. See BZ #1677968 - -* Sun Feb 17 2019 Jos de Kloe - 2.12.0-1 -- Upgrade to upstream version 2.12.0 - -* Thu Jan 31 2019 Fedora Release Engineering - 2.9.2-2 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild - * Sat Nov 24 2018 Jos de Kloe - 2.9.2-1 - Upgrade to upstream version 2.9.2 From e37933b64a19c255a987ec8ee60c9e9f0a513efb Mon Sep 17 00:00:00 2001 From: Jos de Kloe Date: Sat, 27 Jun 2020 15:02:09 +0200 Subject: [PATCH 13/18] updated sources file --- sources | 1 - 1 file changed, 1 deletion(-) diff --git a/sources b/sources index f4f819f..4062163 100644 --- a/sources +++ b/sources @@ -1,3 +1,2 @@ SHA512 (eccodes-2.18.0-Source.tar.gz) = 8daf7f2e1aed055ca6402881f5473e4ae90ba24cc779005f57f99adc7468da459c7539e64f455e2122dd83df29992fd7a6dad2700c8331c4083226e091fbb629 SHA512 (eccodes_test_data_20200626.tar.gz) = 553eb69f3664c2f847c5ee7a84066e814ef03b3148ae2c13d845891038336daca815673650f1d06efee4f4a1ddaa4326f2ddfbe81d29382e3f25608b249b8d9e - From dc5f405a24e8eaf6d072f73d9841ef40cb17f2c6 Mon Sep 17 00:00:00 2001 From: Troy Dawson Date: Thu, 24 Sep 2020 17:06:37 +0000 Subject: [PATCH 14/18] remove package.cfg per new epel-playground policy --- package.cfg | 2 -- 1 file changed, 2 deletions(-) delete mode 100644 package.cfg diff --git a/package.cfg b/package.cfg deleted file mode 100644 index 66ea79d..0000000 --- a/package.cfg +++ /dev/null @@ -1,2 +0,0 @@ -[koji] -targets = epel8 epel8-playground \ No newline at end of file From 8f1bff3cafdd4db89ef11820185e21dffc0254b6 Mon Sep 17 00:00:00 2001 From: Jos de Kloe Date: Mon, 11 Oct 2021 20:38:37 +0200 Subject: [PATCH 15/18] update to version 2.23.0 for epel8 --- .gitignore | 2 +- eccodes-32bit.patch | 32 -------------------------------- eccodes-soversion.patch | 31 +++++++++++++++---------------- eccodes.spec | 29 +++++++++++++++++++---------- sources | 2 +- 5 files changed, 36 insertions(+), 60 deletions(-) delete mode 100644 eccodes-32bit.patch diff --git a/.gitignore b/.gitignore index 29f4bf6..cb5cc65 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,2 @@ -/eccodes-2.18.0-Source.tar.gz /eccodes_test_data_20200626.tar.gz +/eccodes-2.23.0-Source.tar.gz diff --git a/eccodes-32bit.patch b/eccodes-32bit.patch deleted file mode 100644 index f019811..0000000 --- a/eccodes-32bit.patch +++ /dev/null @@ -1,32 +0,0 @@ ---- eccodes-2.18.0-Source.unchanged/src/grib_api_prototypes.h 2020-06-24 11:11:27.000000000 +0200 -+++ eccodes-2.18.0-Source/src/grib_api_prototypes.h 2020-06-27 09:23:17.543758993 +0200 -@@ -860,8 +860,8 @@ double grib_ieeefloat_error(double x); - double grib_long_to_ieee(unsigned long x); - int grib_nearest_smaller_ieee_float(double a, double* x); - unsigned long grib_ieee_to_long(double x); --unsigned long grib_ieee64_to_long(double x); --double grib_long_to_ieee64(unsigned long x); -+uint64_t grib_ieee64_to_long(double x); -+double grib_long_to_ieee64(uint64_t x); - int grib_ieee_decode_array(grib_context* c, unsigned char* buf, size_t nvals, int bytes, double* val); - int grib_ieee_decode_array(grib_context* c, unsigned char* buf, size_t nvals, int bytes, double* val); - int grib_ieee_encode_array(grib_context* c, double* val, size_t nvals, int bytes, unsigned char* buf); ---- eccodes-2.18.0-Source.unchanged/src/grib_ieeefloat.c 2020-06-24 11:11:27.000000000 +0200 -+++ eccodes-2.18.0-Source/src/grib_ieeefloat.c 2020-06-27 09:23:17.545758944 +0200 -@@ -443,14 +443,14 @@ unsigned long grib_ieee_to_long(double x - * grib_encode_unsigned_long. - */ - --unsigned long grib_ieee64_to_long(double x) -+uint64_t grib_ieee64_to_long(double x) - { - unsigned long lval; - memcpy(&lval, &x, 8); - return lval; - } - --double grib_long_to_ieee64(unsigned long x) -+double grib_long_to_ieee64(uint64_t x) - { - double dval; - memcpy(&dval, &x, 8); diff --git a/eccodes-soversion.patch b/eccodes-soversion.patch index defa647..78e9b89 100644 --- a/eccodes-soversion.patch +++ b/eccodes-soversion.patch @@ -1,21 +1,20 @@ ---- eccodes-2.18.0-Source.unchanged/fortran/CMakeLists.txt 2020-06-24 11:11:27.000000000 +0200 -+++ eccodes-2.18.0-Source/fortran/CMakeLists.txt 2020-06-27 09:23:33.020376062 +0200 -@@ -45,7 +45,9 @@ if( HAVE_FORTRAN ) - ecbuild_add_library( TARGET eccodes_f90 - SOURCES grib_fortran.c grib_f90.f90 eccodes_f90.f90 grib_kinds.h - GENERATED grib_f90.f90 eccodes_f90.f90 -- LIBS eccodes ) -+ LIBS eccodes -+ SOVERSION ${ECCODES_SOVERSION_F90}) -+ +--- eccodes-2.23.0-Source.unchanged/fortran/CMakeLists.txt 2021-08-25 11:35:41.000000000 +0200 ++++ eccodes-2.23.0-Source/fortran/CMakeLists.txt 2021-09-01 08:40:58.089840900 +0200 +@@ -49,7 +49,8 @@ if( HAVE_FORTRAN ) + GENERATED grib_f90.f90 eccodes_f90.f90 + PUBLIC_INCLUDES $ + $ +- PRIVATE_LIBS eccodes ${ECCODES_PTHREADS_LIBRARIES} ) ++ PRIVATE_LIBS eccodes ${ECCODES_PTHREADS_LIBRARIES} ++ SOVERSION ${ECCODES_SOVERSION_F90}) + if( DEFINED ecbuild_VERSION AND NOT ${ecbuild_VERSION} VERSION_LESS 3.1 ) # Installed module directory is not in the PUBLIC INCLUDES! - target_include_directories( eccodes_f90 PUBLIC $ ) ---- eccodes-2.18.0-Source.unchanged/src/CMakeLists.txt 2020-06-24 11:11:27.000000000 +0200 -+++ eccodes-2.18.0-Source/src/CMakeLists.txt 2020-06-27 09:27:13.845630950 +0200 -@@ -442,6 +442,7 @@ ecbuild_add_library( TARGET eccodes - GENERATED grib_api_version.c - LIBS ${ECCODES_EXTRA_LIBRARIES} ${CMAKE_THREAD_LIBS_INIT} ${CMATH_LIBRARIES} +--- eccodes-2.23.0-Source.unchanged/src/CMakeLists.txt 2021-08-25 11:35:41.000000000 +0200 ++++ eccodes-2.23.0-Source/src/CMakeLists.txt 2021-09-01 08:31:13.559364510 +0200 +@@ -444,6 +444,7 @@ ecbuild_add_library( TARGET eccodes + PRIVATE_LIBS ${ECCODES_EXTRA_LIBRARIES} ${CMAKE_THREAD_LIBS_INIT} ${AEC_LIBRARIES} ${PNG_LIBRARIES} + PUBLIC_LIBS ${CMATH_LIBRARIES} ${THREADS_LIBRARIES} TEMPLATES ${grib_api_extra_srcs} + SOVERSION ${ECCODES_SOVERSION} INSTALL_HEADERS_LIST diff --git a/eccodes.spec b/eccodes.spec index a959afb..dce4f59 100644 --- a/eccodes.spec +++ b/eccodes.spec @@ -1,5 +1,5 @@ Name: eccodes -Version: 2.18.0 +Version: 2.23.0 Release: 1%{?dist} Summary: WMO data format decoding and encoding @@ -8,11 +8,12 @@ Summary: WMO data format decoding and encoding %global so_version_f90 0.1 %global datapack_date 20200626 -# latest fedora-32 grib_api version is 1.27.0-7 +# latest fedora-35 grib_api version is 1.27.0-12 # but this version number is to be updated as soon as we know # what the final release of grib_api by upstream will be. # latest upstream grib_api release is 1.28.0 (05-Dec-2018) -# see https://confluence.ecmwf.int/display/GRIB/Home +# as was written on https://confluence.ecmwf.int/display/GRIB/Home +# (Note that this page is no longer available, 17-Oct-2020) %global final_grib_api_version 1.28.1-1%{?dist} %ifarch i686 ppc64 s390x armv7hl @@ -37,13 +38,15 @@ Source0: https://software.ecmwf.int/wiki/download/attachments/45757960/ec # now and then so rename the datapack using the download date # to make it versioned in fedora Source1: http://download.ecmwf.org/test-data/eccodes/eccodes_test_data.tar.gz#/eccodes_test_data_%{datapack_date}.tar.gz -# Support 32-bit -# https://software.ecmwf.int/issues/browse/SUP-1813 -# (unfortunately this issue is not public) -Patch1: eccodes-32bit.patch + # Add soversion to the shared libraries, since upstream refuses to do so # https://software.ecmwf.int/issues/browse/SUP-1809 -Patch2: eccodes-soversion.patch +Patch1: eccodes-soversion.patch + +# Disable versionNumberOfSuperblock checking, since the test expects 0 but +# on Fedora rawhide the code returns a value of 2. +# Issue reported upstream as: https://jira.ecmwf.int/browse/SUP-3497 +Patch2: eccodes-test-grib_to_netcdf.patch # note that the requests to make the other issues public are filed here: # https://software.ecmwf.int/issues/browse/SUP-2073 @@ -244,7 +247,8 @@ cd build -DCMAKE_SKIP_INSTALL_RPATH=TRUE \ -DECCODES_SOVERSION=%{so_version} \ -DECCODES_SOVERSION_F90=%{so_version_f90} \ - -DENABLE_PYTHON=OFF \ + -DCMAKE_Fortran_FLAGS="-fPIC" \ + -DENABLE_PYTHON2=OFF \ .. %make_build @@ -317,6 +321,8 @@ cd build # 'eccodes_t_bufr_dump_(de|en)code_C' tests run. # These tests compile on the fly generated C code, and # without this setting the loader does not find the libraries. +# * this is a 'non-standard' use of ctest3 so it does currently not +# work with the %%ctest macro. LD_LIBRARY_PATH=%{buildroot}/%{_libdir} \ LIBRARY_PATH=%{buildroot}/%{_libdir} \ @@ -348,6 +354,9 @@ ctest3 -V %{?_smp_mflags} %doc %{_datadir}/doc/%{name}/ %changelog +* Mon Oct 11 2021 Jos de Kloe - 2.23.0-1 +- Upgrade to upstream version 2.23.0 + * Sat Jun 27 2020 Jos de Kloe - 2.18.0-1 - Upgrade to upstream version 2.18.0 @@ -397,7 +406,7 @@ ctest3 -V %{?_smp_mflags} - Implement so version because upstream refuses to do so - Add fix for test failure 184 and ldconfig_scriptlets and move unversioned so file to devel package - as suggested by Robert-André Mauchin + as suggested by Robert-Andre Mauchin - Add a documentation and a data sub-package - Change the license and add a note explaining why this was done diff --git a/sources b/sources index 4062163..30a5938 100644 --- a/sources +++ b/sources @@ -1,2 +1,2 @@ -SHA512 (eccodes-2.18.0-Source.tar.gz) = 8daf7f2e1aed055ca6402881f5473e4ae90ba24cc779005f57f99adc7468da459c7539e64f455e2122dd83df29992fd7a6dad2700c8331c4083226e091fbb629 SHA512 (eccodes_test_data_20200626.tar.gz) = 553eb69f3664c2f847c5ee7a84066e814ef03b3148ae2c13d845891038336daca815673650f1d06efee4f4a1ddaa4326f2ddfbe81d29382e3f25608b249b8d9e +SHA512 (eccodes-2.23.0-Source.tar.gz) = df8e9f25396d91ae0adb1b1502cdb6c1473d80caf79ce3fe9318ecc63194fd1c7dc7424fccf44aabf8c06ea343d59093bb21e75f6e5466f21ce44cb514e07350 From b12b53ab4b8060ff0cb1de8b22217a02087749de Mon Sep 17 00:00:00 2001 From: Jos de Kloe Date: Mon, 11 Oct 2021 20:50:04 +0200 Subject: [PATCH 16/18] add eccodes-test-grib_to_netcdf.patch --- eccodes-test-grib_to_netcdf.patch | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 eccodes-test-grib_to_netcdf.patch diff --git a/eccodes-test-grib_to_netcdf.patch b/eccodes-test-grib_to_netcdf.patch new file mode 100644 index 0000000..eff2a26 --- /dev/null +++ b/eccodes-test-grib_to_netcdf.patch @@ -0,0 +1,15 @@ +--- eccodes-2.23.0-Source.unchanged/tests/grib_to_netcdf.sh 2021-08-25 11:35:41.000000000 +0200 ++++ eccodes-2.23.0-Source/tests/grib_to_netcdf.sh 2021-09-02 10:31:33.417295119 +0200 +@@ -64,8 +64,10 @@ if [ $ECCODES_ON_WINDOWS -eq 0 ]; then + set -e + if [ $stat -eq 0 ]; then + have_netcdf4=1 +- res=`${tools_dir}/grib_get -TA -p identifier,versionNumberOfSuperblock $tempNetcdf` +- [ "$res" = "HDF5 0" ] ++# res=`${tools_dir}/grib_get -TA -p identifier,versionNumberOfSuperblock $tempNetcdf` ++# [ "$res" = "HDF5 0" ] ++ res=`${tools_dir}/grib_get -TA -p identifier $tempNetcdf` ++ [ "$res" = "HDF5" ] + fi + fi + From f4b82949a1171fff58340a7059a1f57092e32341 Mon Sep 17 00:00:00 2001 From: Jos de Kloe Date: Thu, 18 May 2023 16:51:08 +0200 Subject: [PATCH 17/18] upgrade to new upstream version 2.30.0, and ensure AEC is enabled, and SPDX license migration. --- .gitignore | 2 + eccodes-soversion.patch | 15 +++--- eccodes.spec | 102 ++++++++++++++++++++++-------------- eccodes_create_man_pages.sh | 28 ++++++++++ sources | 4 +- 5 files changed, 104 insertions(+), 47 deletions(-) create mode 100755 eccodes_create_man_pages.sh diff --git a/.gitignore b/.gitignore index cb5cc65..afa1b7e 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,4 @@ /eccodes_test_data_20200626.tar.gz /eccodes-2.23.0-Source.tar.gz +/eccodes-2.30.0-Source.tar.gz +/eccodes_test_data_20220526.tar.gz diff --git a/eccodes-soversion.patch b/eccodes-soversion.patch index 78e9b89..6646502 100644 --- a/eccodes-soversion.patch +++ b/eccodes-soversion.patch @@ -1,5 +1,5 @@ ---- eccodes-2.23.0-Source.unchanged/fortran/CMakeLists.txt 2021-08-25 11:35:41.000000000 +0200 -+++ eccodes-2.23.0-Source/fortran/CMakeLists.txt 2021-09-01 08:40:58.089840900 +0200 +--- eccodes-2.29.0-Source.unchanged/fortran/CMakeLists.txt 2023-03-14 12:55:29.000000000 +0100 ++++ eccodes-2.29.0-Source/fortran/CMakeLists.txt 2023-03-26 13:20:18.495793176 +0200 @@ -49,7 +49,8 @@ if( HAVE_FORTRAN ) GENERATED grib_f90.f90 eccodes_f90.f90 PUBLIC_INCLUDES $ @@ -10,13 +10,14 @@ if( DEFINED ecbuild_VERSION AND NOT ${ecbuild_VERSION} VERSION_LESS 3.1 ) # Installed module directory is not in the PUBLIC INCLUDES! ---- eccodes-2.23.0-Source.unchanged/src/CMakeLists.txt 2021-08-25 11:35:41.000000000 +0200 -+++ eccodes-2.23.0-Source/src/CMakeLists.txt 2021-09-01 08:31:13.559364510 +0200 -@@ -444,6 +444,7 @@ ecbuild_add_library( TARGET eccodes +--- eccodes-2.29.0-Source.unchanged/src/CMakeLists.txt 2023-03-14 12:55:29.000000000 +0100 ++++ eccodes-2.29.0-Source/src/CMakeLists.txt 2023-03-26 13:20:18.518792626 +0200 +@@ -438,6 +438,8 @@ ecbuild_add_library( TARGET eccodes PRIVATE_LIBS ${ECCODES_EXTRA_LIBRARIES} ${CMAKE_THREAD_LIBS_INIT} ${AEC_LIBRARIES} ${PNG_LIBRARIES} PUBLIC_LIBS ${CMATH_LIBRARIES} ${THREADS_LIBRARIES} - TEMPLATES ${grib_api_extra_srcs} -+ SOVERSION ${ECCODES_SOVERSION} + TEMPLATES ${eccodes_extra_src_files} ++ SOVERSION ${ECCODES_SOVERSION} ++ INSTALL_HEADERS_LIST grib_api.h eccodes.h diff --git a/eccodes.spec b/eccodes.spec index dce4f59..fa69ab5 100644 --- a/eccodes.spec +++ b/eccodes.spec @@ -1,14 +1,14 @@ Name: eccodes -Version: 2.23.0 +Version: 2.30.0 Release: 1%{?dist} Summary: WMO data format decoding and encoding # force the shared libraries to have these so versions %global so_version 0.1 %global so_version_f90 0.1 -%global datapack_date 20200626 +%global datapack_date 20220526 -# latest fedora-35 grib_api version is 1.27.0-12 +# latest fedora-38/rawhide grib_api version is 1.27.0-18 # but this version number is to be updated as soon as we know # what the final release of grib_api by upstream will be. # latest upstream grib_api release is 1.28.0 (05-Dec-2018) @@ -16,44 +16,44 @@ Summary: WMO data format decoding and encoding # (Note that this page is no longer available, 17-Oct-2020) %global final_grib_api_version 1.28.1-1%{?dist} -%ifarch i686 ppc64 s390x armv7hl +%ifarch i686 ppc64 armv7hl %global obsolete_grib_api 0 %else %global obsolete_grib_api 1 %endif # license remarks: -# Most of eccodes is licensed ASL 2.0 but a special case must be noted. +# Most of eccodes is licensed ASL 2.0 (which is identical to the SPDX +# identifier Apache-2.0) but a special case must be noted. # These 2 files: # src/grib_yacc.c # src/grib_yacc.h # contain a special exception clause that allows them to be # relicensed if they are included in a larger project -License: ASL 2.0 +License: Apache-2.0 + +URL: https://confluence.ecmwf.int/display/ECC/ecCodes+Home +Source0: https://confluence.ecmwf.int/download/attachments/45757960/eccodes-%{version}-Source.tar.gz -URL: https://software.ecmwf.int/wiki/display/ECC/ecCodes+Home -Source0: https://software.ecmwf.int/wiki/download/attachments/45757960/eccodes-%{version}-Source.tar.gz # note: this data package is unversioned upstream but still it is updated # now and then so rename the datapack using the download date # to make it versioned in fedora Source1: http://download.ecmwf.org/test-data/eccodes/eccodes_test_data.tar.gz#/eccodes_test_data_%{datapack_date}.tar.gz +# a custom script to create man pages +Source2: eccodes_create_man_pages.sh + # Add soversion to the shared libraries, since upstream refuses to do so -# https://software.ecmwf.int/issues/browse/SUP-1809 +# https://jira.ecmwf.int/browse/SUP-1809 Patch1: eccodes-soversion.patch -# Disable versionNumberOfSuperblock checking, since the test expects 0 but -# on Fedora rawhide the code returns a value of 2. -# Issue reported upstream as: https://jira.ecmwf.int/browse/SUP-3497 -Patch2: eccodes-test-grib_to_netcdf.patch - # note that the requests to make the other issues public are filed here: -# https://software.ecmwf.int/issues/browse/SUP-2073 +# https://jira.ecmwf.int/browse/SUP-2073 # (and again, unfortunately this issue is not public) BuildRequires: cmake3 -BuildRequires: gcc +BuildRequires: gcc-c++ BuildRequires: gcc-gfortran BuildRequires: /usr/bin/git BuildRequires: jasper-devel @@ -61,12 +61,16 @@ BuildRequires: libjpeg-devel BuildRequires: libpng-devel BuildRequires: netcdf-devel BuildRequires: openjpeg2-devel +BuildRequires: libaec-devel # For tests BuildRequires: perl(Getopt::Long) BuildRequires: perl(Test::More) BuildRequires: perl(File::Compare) +# For creation of man pages +BuildRequires: help2man + # the data is needed by the library and all tools provided in the main package # the other way around, the data package could be installed without # installing the base package. It will probably be pretty useless, @@ -102,9 +106,9 @@ ExcludeArch: i686 # but the exclude is still needed for EPEL-7 and EPEL-8 ExcludeArch: ppc64 # as explained in bugzilla #1562076 -ExcludeArch: s390x +#ExcludeArch: s390x # as explained in bugzilla #1562084 -ExcludeArch: armv7hl +#ExcludeArch: armv7hl %if 0%{?rhel} >= 7 # as explained in bugzilla #1629377 @@ -188,24 +192,17 @@ in C, and Fortran 90. %autosetup -n %{name}-%{version}-Source -p1 # unpack the test data below build -mkdir build -cd build +mkdir -p %{_vpath_builddir} +pushd %{_vpath_builddir} tar xf %SOURCE1 - -# remove executable permissions from c files -cd .. -chmod 644 tigge/*.c -chmod 644 tools/*.c - -# remove executable permissions from the authors and license file -chmod 644 AUTHORS LICENSE +popd %build -cd build + +pushd %{_vpath_builddir} #-- The following features are disabled by default and not switched on: # -# * AEC , support for Adaptive Entropy Coding # * MEMFS , Memory based access to definitions/samples # * MEMORY_MANAGEMENT , enable memory management # * ALIGN_MEMORY , enable memory alignment @@ -237,6 +234,11 @@ cd build # the library so files get installed in /usr/lib in stead # of /usr/lib64 on x86_64. +# added -DCMAKE_Fortran_FLAGS="-fPIC" +# because the koji build crashes with the error that it needs this setting +# when I try to build for armv7hl (other archs do not complain ......) +# I have no idea what causes this difference in behaviour. + %cmake3 -DINSTALL_LIB_DIR=%{_lib} \ -DENABLE_ECCODES_OMP_THREADS=ON \ -DENABLE_EXTRA_TESTS=ON \ @@ -249,18 +251,20 @@ cd build -DECCODES_SOVERSION_F90=%{so_version_f90} \ -DCMAKE_Fortran_FLAGS="-fPIC" \ -DENABLE_PYTHON2=OFF \ + -DENABLE_AEC=ON \ .. %make_build +popd + # copy some include files to the build dir -# that are otherwise not found when creating the debugsource subpackage -cd .. -cp fortran/eccodes_constants.h build/fortran/ -cp fortran/grib_api_constants.h build/fortran/ +# that are otherwise not found when creating the debugsource sub-package +cp fortran/eccodes_constants.h %{_vpath_builddir}/fortran/ +cp fortran/grib_api_constants.h %{_vpath_builddir}/fortran/ %install -%make_install -C build +%make_install -C %{_vpath_builddir} mkdir -p %{buildroot}%{_fmoddir} mv %{buildroot}%{_includedir}/*.mod %{buildroot}%{_fmoddir}/ @@ -273,8 +277,6 @@ rm %{buildroot}%{_datadir}/%{name}/definitions/installDefinitions.sh # copy the html documentation to the install directory mkdir -p %{buildroot}%{_datadir}/doc/%{name}/ cp -r html %{buildroot}%{_datadir}/doc/%{name}/ -# and remove an unneeded Makefile from the html directory -rm %{buildroot}%{_datadir}/doc/%{name}/html/Makefile.am # copy the example scripts/programs to the install directory # but dont copy the shell scripts and Makefiles, since these @@ -288,6 +290,21 @@ cp examples/C/*.c %{buildroot}%{_datadir}/doc/%{name}/examples/C mkdir -p %{buildroot}%{_datadir}/doc/%{name}/examples/F90 cp examples/F90/*.f90 %{buildroot}%{_datadir}/doc/%{name}/examples/F90 +# create man pages for the tools that support the --help option +# since upstream does not provide them. +# Source2 points to the script eccodes_create_man_pages.sh +# used to generate the man pages. +LD_LIBRARY_PATH=%{buildroot}/%{_libdir} \ +%{SOURCE2} %{_vpath_builddir}/bin \ + %{_vpath_builddir}/man + +# copy the created man pages to the install directory +mkdir -p %{buildroot}%{_datadir}/man/man1 +cp %{_vpath_builddir}/man/*.1 %{buildroot}%{_datadir}/man/man1 + +# Fix permissions +chmod 644 AUTHORS LICENSE + # also not needed for x86_64 # maybe they fixed it for all archs? #%%ifarch i686 armv7hl @@ -311,7 +328,7 @@ sed -i 's|^libs=.*$|libs=-L${libdir} -leccodes_f90 -leccodes|g' %{buildroot}/%{_ %ldconfig_scriptlets %check -cd build +cd %{_vpath_builddir} # notes: # * the LD_LIBRARY_PATH setting is required to let the tests @@ -333,6 +350,7 @@ ctest3 -V %{?_smp_mflags} %doc README.md ChangeLog AUTHORS NEWS NOTICE %{_bindir}/* %{_libdir}/*.so.* +%{_mandir}/man1/*.1* %files devel %{_includedir}/* @@ -354,6 +372,14 @@ ctest3 -V %{?_smp_mflags} %doc %{_datadir}/doc/%{name}/ %changelog +* Thu May 18 2023 Jos de Kloe - 2.30.0-1 +- Upgrade to upstream version 2.30.0 +- explicitly switch on ENABLE_AEC +- migrated to SPDX license + +* Wed Jun 1 2022 Jos de Kloe - 2.26.0-1 +- Upgrade to upstream version 2.26.0 + * Mon Oct 11 2021 Jos de Kloe - 2.23.0-1 - Upgrade to upstream version 2.23.0 diff --git a/eccodes_create_man_pages.sh b/eccodes_create_man_pages.sh new file mode 100755 index 0000000..6ca4bfe --- /dev/null +++ b/eccodes_create_man_pages.sh @@ -0,0 +1,28 @@ +#!/bin/sh + +# a simple script to create man pages for tools +# provided in the bin dir after installation of eccodes. +# +# Written by: J. de Kloe, 2022. + +BINDIR=$1 +DESTDIR=$2 + +if [ ! -e "$DESTDIR" ] ; then + mkdir -p "$DESTDIR" +fi + +for TOOL in "$BINDIR"/* +do + BASENAME=$(basename "$TOOL") + help2man --no-info --output="${DESTDIR}/${BASENAME}.1" "${TOOL}" +done + +# currently (29-Aug-2022) help2man fails on these 5 tools: +# help2man: can't get `--help' info from ../bin/bufr_count +# help2man: can't get `--help' info from ../bin/codes_count +# help2man: can't get `--help' info from ../bin/grib2ppm +# help2man: can't get `--help' info from ../bin/grib_count +# help2man: can't get `--help' info from ../bin/gts_count + +echo "done" diff --git a/sources b/sources index 30a5938..83a0a88 100644 --- a/sources +++ b/sources @@ -1,2 +1,2 @@ -SHA512 (eccodes_test_data_20200626.tar.gz) = 553eb69f3664c2f847c5ee7a84066e814ef03b3148ae2c13d845891038336daca815673650f1d06efee4f4a1ddaa4326f2ddfbe81d29382e3f25608b249b8d9e -SHA512 (eccodes-2.23.0-Source.tar.gz) = df8e9f25396d91ae0adb1b1502cdb6c1473d80caf79ce3fe9318ecc63194fd1c7dc7424fccf44aabf8c06ea343d59093bb21e75f6e5466f21ce44cb514e07350 +SHA512 (eccodes_test_data_20220526.tar.gz) = 0457878caad6a3395daf60e27cfb72121526065b0cf4da144c7499b8d38bebae0952ddbd20ef0eb53fad77ada60160039340da01001f19fbb7fb1ccbb3d0547a +SHA512 (eccodes-2.30.0-Source.tar.gz) = 07b67cef67cefb32ad4581813ed8814f9394d27846c8bc41b78b1504d296f84547d1fb72ce4813f214fe09b9391449995dd53cf9ae7d27721e2b34353ee58b00 From b8a25a59b578be6096956c76c5cd0ed20b422df9 Mon Sep 17 00:00:00 2001 From: Jos de Kloe Date: Thu, 18 May 2023 17:17:17 +0200 Subject: [PATCH 18/18] updated readme and rpmlintrc --- README.md | 15 +++++++++++ eccodes.rpmlintrc | 63 ++++++++--------------------------------------- 2 files changed, 25 insertions(+), 53 deletions(-) diff --git a/README.md b/README.md index 035f9e0..f4658ba 100644 --- a/README.md +++ b/README.md @@ -12,3 +12,18 @@ messages in the following formats: For further details see: https://confluence.ecmwf.int/display/ECC/What+is+ecCodes + +Note for end users: +epel policy is to keep software versions stable for a given epel version +unless there is a strong reason why an update is needed +(for example security issues or malfunction). + +Since eccodes depends on a large collection of table definitions +that are included in the package, after some time these tables +(holding the WMO file format definitions for GRIB and BUFR files, +which are updated every 6 months) will become outdated, and new files +using these formats can not be used. + +If this is a problem for you, please raise the issue in bugzilla. +Since this is a malfunction from user perspective this is a +reason to update the package. diff --git a/eccodes.rpmlintrc b/eccodes.rpmlintrc index 60064d2..b6c8fb4 100644 --- a/eccodes.rpmlintrc +++ b/eccodes.rpmlintrc @@ -1,56 +1,13 @@ -# use like this: -# rpmlint --file eccodes.rpmlintrc *.rpm -# example: addFilter ("^foo-.*regex-match-for-rpmlint-warning") -# these are invalid spelling warnings. GRIB and BUFR are correct, since these are -# the names of the data files that this software handles. -# the description itself is a 1-to-1 copy of what the (UK-based) upstream -# writes, and I am not going to translate this to US spelling ... -addFilter ("W: spelling-error %description -l en_US behaviour -> behavior") -addFilter ("W: spelling-error %description -l en_US grib ->") -addFilter ("W: spelling-error %description -l en_US bufr ->") +# Disable warning on duplicate files. +# This package uses a huge number (1990 cases at the time of wrinting) +# duplicates in the tables definitions, and patching this is totally +# out of scope for my limited time. +addFilter(r" W: files-duplicate ") +addFilter(r" E: files-duplicated-waste ") -# this data file with wrong line ending has been added to the software on purpose -# for testing purposes, so this is no mistake -addFilter ("eccodes-doc.noarch: W: wrong-file-end-of-line-encoding /usr/share/doc/eccodes/examples/python/flight_data.csv") +# Disable warnings on missing man pages. +# The tools that have --help output have been fixed by using help2man. +# The remaining ones have no help output whatsoever and are not easy to fix. +addFilter(r" W: no-manual-page-for-binary ") -# these data files are no scripts. The dataformat just has an unfortunate first line -# starting with #! so it resembles a shebang line. -# see also comment #3 in the review request at https://bugzilla.redhat.com/show_bug.cgi?id=1508950 -addFilter ("^eccodes-data.noarch: E: wrong-script-interpreter /usr/share/eccodes/definitions/grib1/local.82.0.def") -addFilter ("^eccodes-data.noarch: E: non-executable-script /usr/share/eccodes/definitions/grib1/local.82.0.def") -addFilter ("^eccodes-data.noarch: E: wrong-script-interpreter /usr/share/eccodes/definitions/grib1/local.82.83.def") -addFilter ("^eccodes-data.noarch: E: non-executable-script /usr/share/eccodes/definitions/grib1/local.82.83.def") - -# this is a false error (its an rpmlint bug). -# the spec file now uses %ldconfig_scriptlets in stead of the old ldconfig-postin/postun -# see also comment #18 in the review request at https://bugzilla.redhat.com/show_bug.cgi?id=1508950 -addFilter ("^eccodes.x86_64: E: library-without-ldconfig-postin /usr/lib64/libeccodes.so.0.1") -addFilter ("^eccodes.x86_64: E: library-without-ldconfig-postun /usr/lib64/libeccodes.so.0.1") -addFilter ("^eccodes.x86_64: E: library-without-ldconfig-postin /usr/lib64/libeccodes_f90.so.0.1") -addFilter ("^eccodes.x86_64: E: library-without-ldconfig-postun /usr/lib64/libeccodes_f90.so.0.1") - -# this is an rpmlint bug -# see also comment #8 in the review request at https://bugzilla.redhat.com/show_bug.cgi?id=1508950 -addFilter ("eccodes-debuginfo.x86_64: E: useless-provides debuginfo\(build-id\)") - -# there is no full compatibility between the old grib_api and the new eccodes -# so only obsoletes can be used bu no provides. -# see also comment #21 in the review request at https://bugzilla.redhat.com/show_bug.cgi?id=1508950 -addFilter ("^eccodes.x86_64: W: obsolete-not-provided grib_api") -addFilter ("^eccodes-devel.x86_64: W: obsolete-not-provided grib_api-devel") -addFilter ("^eccodes-devel.x86_64: W: only-non-binary-in-usr-lib") - -# documentation is in a dedicated doc subpackage, -# so these warnings have no merit -addFilter ("python2-eccodes.x86_64: W: no-documentation") -addFilter ("eccodes-debugsource.x86_64: W: no-documentation") -addFilter ("eccodes-devel.x86_64: W: no-documentation") -addFilter ("eccodes-data.noarch: W: no-documentation") - -# temporary disable the man page warning, since it obscures other problems that -# may be more important, and it has already been reported upstream -# see also comment #3 in the review request at https://bugzilla.redhat.com/show_bug.cgi?id=1508950 -addFilter ("eccodes.x86_64: W: no-manual-page-for-binary") - -# addFilter ("")