From be19a6b8c43faac0bfef9d5efac39efa91831f1d Mon Sep 17 00:00:00 2001 From: Jos de Kloe Date: Fri, 3 Jun 2022 10:14:54 +0200 Subject: [PATCH 1/6] first version for epel9. Disable all ExcludeArch exceptions at first to see what happens. --- .gitignore | 2 + README.md | 13 +- eccodes-soversion.patch | 23 +++ eccodes.spec | 350 ++++++++++++++++++++++++++++++++++++++++ sources | 2 + 5 files changed, 389 insertions(+), 1 deletion(-) create mode 100644 .gitignore create mode 100644 eccodes-soversion.patch create mode 100644 eccodes.spec create mode 100644 sources diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..b3652b6 --- /dev/null +++ b/.gitignore @@ -0,0 +1,2 @@ +/eccodes-2.26.0-Source.tar.gz +/eccodes_test_data_20220526.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-soversion.patch b/eccodes-soversion.patch new file mode 100644 index 0000000..0cf8084 --- /dev/null +++ b/eccodes-soversion.patch @@ -0,0 +1,23 @@ +--- eccodes-2.26.0-Source.unchanged/fortran/CMakeLists.txt 2022-05-18 13:20:10.000000000 +0200 ++++ eccodes-2.26.0-Source/fortran/CMakeLists.txt 2022-05-26 14:15:01.080533587 +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! +--- eccodes-2.26.0-Source.unchanged/src/CMakeLists.txt 2022-05-18 13:20:10.000000000 +0200 ++++ eccodes-2.26.0-Source/src/CMakeLists.txt 2022-05-26 14:18:49.300260787 +0200 +@@ -437,6 +437,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 ${eccodes_extra_src_files} ++ SOVERSION ${ECCODES_SOVERSION} ++ + INSTALL_HEADERS_LIST + grib_api.h + eccodes.h diff --git a/eccodes.spec b/eccodes.spec new file mode 100644 index 0000000..f1a0e71 --- /dev/null +++ b/eccodes.spec @@ -0,0 +1,350 @@ +Name: eccodes +Version: 2.26.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 20220526 + +# latest fedora-36 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) +# 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 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: +# 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 + +URL: https://confluence.ecmwf.int/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 + +# Add soversion to the shared libraries, since upstream refuses to do so +# https://software.ecmwf.int/issues/browse/SUP-1809 +Patch1: eccodes-soversion.patch + +# note that the requests to make the other issues public are filed here: +# https://software.ecmwf.int/issues/browse/SUP-2073 +# (and again, unfortunately this issue is not public) + +BuildRequires: cmake3 +BuildRequires: gcc +BuildRequires: gcc-gfortran +BuildRequires: /usr/bin/git +BuildRequires: jasper-devel +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) + +# 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, +# unless a user wishes to read and study all these grib and bufr +# file format definitions. +Requires: %{name}-data = %{version}-%{release} + +# NOTE: upstream writes: +# """ +# 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 are all maintained as in GRIB-API. +# However, the GRIB-API Fortran 77 interface is no longer available. +# """ +# Therefore, since the library name and pkg-config file content changes +# and fortran77 support was removed, this replacement package cannot be +# considered compatible enough and no Provides can be defined. +# +# Furthermore, upstream writes: +# "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 +## 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 +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). + +A useful set of command line tools provide quick access to the messages. C, +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 +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, +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 +operate on all the supported message formats. These functions have the same +interface and behaviour as the "grib_" functions. + +A selection of GRIB-API tools has been included in ecCodes (ecCodes GRIB +tools), while new tools are available for the BUFR (ecCodes BUFR tools) and +GTS formats. The new tools have been developed to be as similar as possible +to the existing GRIB-API tools maintaining, where possible, the same options +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. + +##################################################### +%package devel +Summary: Contains ecCodes development files +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 data +Summary: Data needed by the eccodes library and tools +BuildArch: noarch + +%description data +This package provides all tables and definitions needed +to encode and decode grib and bufr files, and includes +both the official WMO tables and a number of often used +local definitions by ECMWF and other meteorological centers. + +##################################################### +%package doc +Summary: Documentation and example code +BuildArch: noarch + +# a sub package grib_api-doc did not exist +# so no obsoletes needed here + +%description doc +This package contains the html documentation for ecCodes +and a fair number of example programs and scripts to use it +in C, and Fortran 90. + +##################################################### +%prep +%autosetup -n %{name}-%{version}-Source -p1 + +# unpack the test data below build +mkdir -p %{_vpath_builddir} +pushd %{_vpath_builddir} +tar xf %SOURCE1 +popd + +%build + +#-- 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 +# * GRIB_TIMER , enable timer +# * ECCODES_THREADS , enable POSIX threads +# +#-- The following features are disabled by default and switched on: +# * PNG , support for PNG decoding/encoding +# * 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. + +# 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 \ + -DENABLE_JPG=ON \ + -DENABLE_PNG=ON \ + -DENABLE_FORTRAN=ON \ + -DENABLE_NETCDF=ON \ + -DCMAKE_SKIP_INSTALL_RPATH=TRUE \ + -DECCODES_SOVERSION=%{so_version} \ + -DECCODES_SOVERSION_F90=%{so_version_f90} \ + -DCMAKE_Fortran_FLAGS="-fPIC" \ + -DENABLE_PYTHON2=OFF + +# note the final '..' is no longer needed to the cmake3 call. +# this is now hidden in the %%cmake3 macro + +%cmake_build + +# copy some include files to the build dir +# 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 +%cmake_install +mkdir -p %{buildroot}%{_fmoddir} +mv %{buildroot}%{_includedir}/*.mod %{buildroot}%{_fmoddir}/ + +# remove a script that does not belong in the doc section +# and triggers an rpmlint error +rm %{buildroot}%{_datadir}/%{name}/definitions/installDefinitions.sh +# by the way, is there a way in the files section to include a directory +# but exclude a given file in it? I could not find such a trick. + +# copy the html documentation to the install directory +mkdir -p %{buildroot}%{_datadir}/doc/%{name}/ +cp -r html %{buildroot}%{_datadir}/doc/%{name}/ + +# copy the example scripts/programs to the install directory +# but dont copy the shell scripts and Makefiles, since these +# are part of the cmake test setup and not usefull as example. +# Use %%{_datadir}/doc/%%{name}/ rather than %%{_datadir}/%%{name}/ +# otherwise the rpmbuild will create a lot off unnecessary +# pyc and pyo files. + +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 + +# 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 +# -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 + +%check +cd %{_vpath_builddir} + +# notes: +# * the LD_LIBRARY_PATH setting is required to let the tests +# run inside the build dir, otherwise they are broken due to +# the removal of rpath +# * the LIBRARY_PATH setting is needed te let the +# '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} \ +ctest3 -V %{?_smp_mflags} + +%files +%license LICENSE +%doc README.md ChangeLog AUTHORS NEWS NOTICE +%{_bindir}/* +%{_libdir}/*.so.* + +%files devel +%{_includedir}/* +%{_fmoddir}/%{name}.mod +%{_fmoddir}/grib_api.mod +%{_libdir}/pkgconfig/%{name}.pc +%{_libdir}/pkgconfig/%{name}_f90.pc +%{_libdir}/*.so +%dir %{_libdir}/cmake/%{name} +%{_libdir}/cmake/%{name}/* + +%files data +%dir %{_datadir}/%{name} +%{_datadir}/%{name}/definitions/ +%{_datadir}/%{name}/samples/ +%{_datadir}/%{name}/ifs_samples/ + +%files doc +%doc %{_datadir}/doc/%{name}/ + +%changelog +* Fri Jun 3 2022 Jos de Kloe - 2.26.0-1 +- First epel9 version diff --git a/sources b/sources new file mode 100644 index 0000000..6d7fcc8 --- /dev/null +++ b/sources @@ -0,0 +1,2 @@ +SHA512 (eccodes-2.26.0-Source.tar.gz) = cd4fd2048ad98a4a5c82a0a233b2e64eb67a195d42637607423669351b6cd295b111a382f6d9ecb05ffe25f79599bf3963550ca27d84e7f9ef55e499e183a35f +SHA512 (eccodes_test_data_20220526.tar.gz) = 0457878caad6a3395daf60e27cfb72121526065b0cf4da144c7499b8d38bebae0952ddbd20ef0eb53fad77ada60160039340da01001f19fbb7fb1ccbb3d0547a From b16ee825e435bb099513812713ce436adb640245 Mon Sep 17 00:00:00 2001 From: Jos de Kloe Date: Fri, 3 Jun 2022 10:42:21 +0200 Subject: [PATCH 2/6] General clean-up; remove unneeded ExcludeArch statements; remove all old grib_api references, since there is nothing to obselete for epel9. Also update an url. --- eccodes.spec | 76 +--------------------------------------------------- 1 file changed, 1 insertion(+), 75 deletions(-) diff --git a/eccodes.spec b/eccodes.spec index f1a0e71..b3e42cc 100644 --- a/eccodes.spec +++ b/eccodes.spec @@ -8,20 +8,6 @@ Summary: WMO data format decoding and encoding %global so_version_f90 0.1 %global datapack_date 20220526 -# latest fedora-36 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) -# 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 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: @@ -40,13 +26,9 @@ Source0: https://software.ecmwf.int/wiki/download/attachments/45757960/ec Source1: http://download.ecmwf.org/test-data/eccodes/eccodes_test_data.tar.gz#/eccodes_test_data_%{datapack_date}.tar.gz # 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 -# note that the requests to make the other issues public are filed here: -# https://software.ecmwf.int/issues/browse/SUP-2073 -# (and again, unfortunately this issue is not public) - BuildRequires: cmake3 BuildRequires: gcc BuildRequires: gcc-gfortran @@ -70,43 +52,6 @@ BuildRequires: perl(File::Compare) # file format definitions. Requires: %{name}-data = %{version}-%{release} -# NOTE: upstream writes: -# """ -# 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 are all maintained as in GRIB-API. -# However, the GRIB-API Fortran 77 interface is no longer available. -# """ -# Therefore, since the library name and pkg-config file content changes -# and fortran77 support was removed, this replacement package cannot be -# considered compatible enough and no Provides can be defined. -# -# Furthermore, upstream writes: -# "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 -## 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 @@ -147,11 +92,6 @@ 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. @@ -171,9 +111,6 @@ local definitions by ECMWF and other meteorological centers. Summary: Documentation and example code BuildArch: noarch -# a sub package grib_api-doc did not exist -# so no obsoletes needed here - %description doc This package contains the html documentation for ecCodes and a fair number of example programs and scripts to use it @@ -280,17 +217,6 @@ 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 -# 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 # -DCMAKE_SKIP_INSTALL_RPATH=TRUE From 814ebdee0608df1318261c71c449a63108909837 Mon Sep 17 00:00:00 2001 From: Jos de Kloe Date: Thu, 18 May 2023 17:22:41 +0200 Subject: [PATCH 3/6] upgrade to new upstream version 2.30.0, and ensure AEC is enabled, and SPDX license migration. --- .gitignore | 1 + README.md | 15 +++++++++++++ eccodes-soversion.patch | 10 ++++----- eccodes.rpmlintrc | 13 +++++++++++ eccodes.spec | 43 +++++++++++++++++++++++++++++++------ eccodes_create_man_pages.sh | 28 ++++++++++++++++++++++++ sources | 2 +- 7 files changed, 99 insertions(+), 13 deletions(-) create mode 100644 eccodes.rpmlintrc create mode 100755 eccodes_create_man_pages.sh diff --git a/.gitignore b/.gitignore index b3652b6..1ac409f 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,3 @@ /eccodes-2.26.0-Source.tar.gz /eccodes_test_data_20220526.tar.gz +/eccodes-2.30.0-Source.tar.gz 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-soversion.patch b/eccodes-soversion.patch index 0cf8084..6646502 100644 --- a/eccodes-soversion.patch +++ b/eccodes-soversion.patch @@ -1,5 +1,5 @@ ---- eccodes-2.26.0-Source.unchanged/fortran/CMakeLists.txt 2022-05-18 13:20:10.000000000 +0200 -+++ eccodes-2.26.0-Source/fortran/CMakeLists.txt 2022-05-26 14:15:01.080533587 +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,9 +10,9 @@ if( DEFINED ecbuild_VERSION AND NOT ${ecbuild_VERSION} VERSION_LESS 3.1 ) # Installed module directory is not in the PUBLIC INCLUDES! ---- eccodes-2.26.0-Source.unchanged/src/CMakeLists.txt 2022-05-18 13:20:10.000000000 +0200 -+++ eccodes-2.26.0-Source/src/CMakeLists.txt 2022-05-26 14:18:49.300260787 +0200 -@@ -437,6 +437,8 @@ 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 ${eccodes_extra_src_files} diff --git a/eccodes.rpmlintrc b/eccodes.rpmlintrc new file mode 100644 index 0000000..b6c8fb4 --- /dev/null +++ b/eccodes.rpmlintrc @@ -0,0 +1,13 @@ + +# 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 ") + +# 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 ") + diff --git a/eccodes.spec b/eccodes.spec index b3e42cc..81a1106 100644 --- a/eccodes.spec +++ b/eccodes.spec @@ -1,5 +1,5 @@ Name: eccodes -Version: 2.26.0 +Version: 2.30.0 Release: 1%{?dist} Summary: WMO data format decoding and encoding @@ -9,28 +9,33 @@ Summary: WMO data format decoding and encoding %global datapack_date 20220526 # 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://software.ecmwf.int/wiki/download/attachments/45757960/eccodes-%{version}-Source.tar.gz +Source0: https://confluence.ecmwf.int/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://jira.ecmwf.int/browse/SUP-1809 Patch1: eccodes-soversion.patch BuildRequires: cmake3 -BuildRequires: gcc +BuildRequires: gcc-c++ BuildRequires: gcc-gfortran BuildRequires: /usr/bin/git BuildRequires: jasper-devel @@ -45,6 +50,9 @@ 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, @@ -130,7 +138,6 @@ popd #-- 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 @@ -178,7 +185,8 @@ popd -DECCODES_SOVERSION=%{so_version} \ -DECCODES_SOVERSION_F90=%{so_version_f90} \ -DCMAKE_Fortran_FLAGS="-fPIC" \ - -DENABLE_PYTHON2=OFF + -DENABLE_PYTHON2=OFF \ + -DENABLE_AEC=ON # note the final '..' is no longer needed to the cmake3 call. # this is now hidden in the %%cmake3 macro @@ -217,6 +225,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 + # It seems the cmake options # -DCMAKE_SKIP_RPATH=TRUE # -DCMAKE_SKIP_INSTALL_RPATH=TRUE @@ -251,6 +274,7 @@ ctest3 -V %{?_smp_mflags} %doc README.md ChangeLog AUTHORS NEWS NOTICE %{_bindir}/* %{_libdir}/*.so.* +%{_mandir}/man1/*.1* %files devel %{_includedir}/* @@ -272,5 +296,10 @@ 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 + * Fri Jun 3 2022 Jos de Kloe - 2.26.0-1 - First epel9 version 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 6d7fcc8..83a0a88 100644 --- a/sources +++ b/sources @@ -1,2 +1,2 @@ -SHA512 (eccodes-2.26.0-Source.tar.gz) = cd4fd2048ad98a4a5c82a0a233b2e64eb67a195d42637607423669351b6cd295b111a382f6d9ecb05ffe25f79599bf3963550ca27d84e7f9ef55e499e183a35f SHA512 (eccodes_test_data_20220526.tar.gz) = 0457878caad6a3395daf60e27cfb72121526065b0cf4da144c7499b8d38bebae0952ddbd20ef0eb53fad77ada60160039340da01001f19fbb7fb1ccbb3d0547a +SHA512 (eccodes-2.30.0-Source.tar.gz) = 07b67cef67cefb32ad4581813ed8814f9394d27846c8bc41b78b1504d296f84547d1fb72ce4813f214fe09b9391449995dd53cf9ae7d27721e2b34353ee58b00 From 87163d333cf6cf35bd56737cc7329601297768e6 Mon Sep 17 00:00:00 2001 From: Jos de Kloe Date: Sat, 9 Sep 2023 15:57:29 +0200 Subject: [PATCH 4/6] Upgrade to upstream version 2.31.0 at user request. See bg2236797 --- .gitignore | 1 + eccodes-soversion.patch | 10 +++++----- eccodes.spec | 5 ++++- sources | 1 + 4 files changed, 11 insertions(+), 6 deletions(-) diff --git a/.gitignore b/.gitignore index 1ac409f..2939489 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,4 @@ /eccodes-2.26.0-Source.tar.gz /eccodes_test_data_20220526.tar.gz /eccodes-2.30.0-Source.tar.gz +/eccodes-2.31.0-Source.tar.gz diff --git a/eccodes-soversion.patch b/eccodes-soversion.patch index 6646502..0fe79eb 100644 --- a/eccodes-soversion.patch +++ b/eccodes-soversion.patch @@ -1,5 +1,5 @@ ---- 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 +--- eccodes-2.31.0-Source.unchanged/fortran/CMakeLists.txt 2023-07-11 12:23:31.000000000 +0200 ++++ eccodes-2.31.0-Source/fortran/CMakeLists.txt 2023-07-27 16:51:03.866574555 +0200 @@ -49,7 +49,8 @@ if( HAVE_FORTRAN ) GENERATED grib_f90.f90 eccodes_f90.f90 PUBLIC_INCLUDES $ @@ -10,9 +10,9 @@ if( DEFINED ecbuild_VERSION AND NOT ${ecbuild_VERSION} VERSION_LESS 3.1 ) # Installed module directory is not in the PUBLIC INCLUDES! ---- 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 +--- eccodes-2.31.0-Source.unchanged/src/CMakeLists.txt 2023-07-11 12:23:31.000000000 +0200 ++++ eccodes-2.31.0-Source/src/CMakeLists.txt 2023-07-27 16:51:03.887574092 +0200 +@@ -427,6 +427,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 ${eccodes_extra_src_files} diff --git a/eccodes.spec b/eccodes.spec index 81a1106..320c9e1 100644 --- a/eccodes.spec +++ b/eccodes.spec @@ -1,5 +1,5 @@ Name: eccodes -Version: 2.30.0 +Version: 2.31.0 Release: 1%{?dist} Summary: WMO data format decoding and encoding @@ -296,6 +296,9 @@ ctest3 -V %{?_smp_mflags} %doc %{_datadir}/doc/%{name}/ %changelog +* Sat Sep 09 2023 Jos de Kloe - 2.31.0-1 +- Upgrade to upstream version 2.31.0 + * Thu May 18 2023 Jos de Kloe - 2.30.0-1 - Upgrade to upstream version 2.30.0 - explicitly switch on ENABLE_AEC diff --git a/sources b/sources index 83a0a88..88bfe9e 100644 --- a/sources +++ b/sources @@ -1,2 +1,3 @@ SHA512 (eccodes_test_data_20220526.tar.gz) = 0457878caad6a3395daf60e27cfb72121526065b0cf4da144c7499b8d38bebae0952ddbd20ef0eb53fad77ada60160039340da01001f19fbb7fb1ccbb3d0547a SHA512 (eccodes-2.30.0-Source.tar.gz) = 07b67cef67cefb32ad4581813ed8814f9394d27846c8bc41b78b1504d296f84547d1fb72ce4813f214fe09b9391449995dd53cf9ae7d27721e2b34353ee58b00 +SHA512 (eccodes-2.31.0-Source.tar.gz) = f3fe70ad0a765ae6e9d23b1b0c6ac96ad81a8324b15b7ebbcc958ffa1a046079d4a9953d720a8c15ac421897059a74c96ea678254f59c88538e3dd4970da131c From 5ed17e85e53eee7b0d7b8001ada7939f5155806e Mon Sep 17 00:00:00 2001 From: Jos de Kloe Date: Fri, 29 Dec 2023 14:01:02 +0100 Subject: [PATCH 5/6] import rawhide changes --- .gitignore | 2 + eccodes-soversion.patch | 10 +- eccodes.spec | 297 +++++++++++++++++++++++++++++++++++++--- sources | 2 + 4 files changed, 287 insertions(+), 24 deletions(-) diff --git a/.gitignore b/.gitignore index 2939489..5f2b0c5 100644 --- a/.gitignore +++ b/.gitignore @@ -2,3 +2,5 @@ /eccodes_test_data_20220526.tar.gz /eccodes-2.30.0-Source.tar.gz /eccodes-2.31.0-Source.tar.gz +/eccodes-2.33.0-Source.tar.gz +/eccodes_test_data_20231216.tar.gz diff --git a/eccodes-soversion.patch b/eccodes-soversion.patch index 0fe79eb..03b520c 100644 --- a/eccodes-soversion.patch +++ b/eccodes-soversion.patch @@ -1,5 +1,5 @@ ---- eccodes-2.31.0-Source.unchanged/fortran/CMakeLists.txt 2023-07-11 12:23:31.000000000 +0200 -+++ eccodes-2.31.0-Source/fortran/CMakeLists.txt 2023-07-27 16:51:03.866574555 +0200 +--- eccodes-2.32.1-Source.unchanged/fortran/CMakeLists.txt 2023-10-26 17:16:35.000000000 +0200 ++++ eccodes-2.32.1-Source/fortran/CMakeLists.txt 2023-10-29 15:39:34.397319711 +0100 @@ -49,7 +49,8 @@ if( HAVE_FORTRAN ) GENERATED grib_f90.f90 eccodes_f90.f90 PUBLIC_INCLUDES $ @@ -10,9 +10,9 @@ if( DEFINED ecbuild_VERSION AND NOT ${ecbuild_VERSION} VERSION_LESS 3.1 ) # Installed module directory is not in the PUBLIC INCLUDES! ---- eccodes-2.31.0-Source.unchanged/src/CMakeLists.txt 2023-07-11 12:23:31.000000000 +0200 -+++ eccodes-2.31.0-Source/src/CMakeLists.txt 2023-07-27 16:51:03.887574092 +0200 -@@ -427,6 +427,8 @@ ecbuild_add_library( TARGET eccodes +--- eccodes-2.32.1-Source.unchanged/src/CMakeLists.txt 2023-10-26 17:16:35.000000000 +0200 ++++ eccodes-2.32.1-Source/src/CMakeLists.txt 2023-10-29 15:39:34.397319711 +0100 +@@ -411,6 +411,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 ${eccodes_extra_src_files} diff --git a/eccodes.spec b/eccodes.spec index 320c9e1..3add048 100644 --- a/eccodes.spec +++ b/eccodes.spec @@ -1,12 +1,34 @@ +%if 0%{?el9} +%undefine __cmake_in_source_build +%endif + Name: eccodes -Version: 2.31.0 +Version: 2.33.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 20220526 + +# note that the test_data package provided on the ECMWF version +# is unversioned, so use the download date to discriminate +# between different versions. +%global datapack_date 20231216 + +# 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) +# 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 armv7hl + %global obsolete_grib_api 0 +%else + %global obsolete_grib_api 1 +%endif # license remarks: # Most of eccodes is licensed ASL 2.0 (which is identical to the SPDX @@ -25,7 +47,7 @@ Source0: https://confluence.ecmwf.int/download/attachments/45757960/eccod # 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 +Source1: https://get.ecmwf.int/repository/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 @@ -34,6 +56,10 @@ Source2: eccodes_create_man_pages.sh # https://jira.ecmwf.int/browse/SUP-1809 Patch1: eccodes-soversion.patch +# note that the requests to make the other issues public are filed here: +# https://jira.ecmwf.int/browse/SUP-2073 +# (and again, unfortunately this issue is not public) + BuildRequires: cmake3 BuildRequires: gcc-c++ BuildRequires: gcc-gfortran @@ -60,6 +86,30 @@ BuildRequires: help2man # file format definitions. Requires: %{name}-data = %{version}-%{release} +# NOTE: upstream writes: +# """ +# 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 are all maintained as in GRIB-API. +# However, the GRIB-API Fortran 77 interface is no longer available. +# """ +# Therefore, since the library name and pkg-config file content changes +# and fortran77 support was removed, this replacement package cannot be +# considered compatible enough and no Provides can be defined. +# +# Furthermore, upstream writes: +# "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 + %description ecCodes is a package developed by ECMWF which provides an application programming interface and a set of tools for decoding and encoding messages @@ -100,6 +150,11 @@ 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. @@ -119,6 +174,9 @@ local definitions by ECMWF and other meteorological centers. Summary: Documentation and example code BuildArch: noarch +# a sub package grib_api-doc did not exist +# so no obsoletes needed here + %description doc This package contains the html documentation for ecCodes and a fair number of example programs and scripts to use it @@ -157,12 +215,6 @@ popd # * 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 @@ -184,9 +236,7 @@ popd -DCMAKE_SKIP_INSTALL_RPATH=TRUE \ -DECCODES_SOVERSION=%{so_version} \ -DECCODES_SOVERSION_F90=%{so_version_f90} \ - -DCMAKE_Fortran_FLAGS="-fPIC" \ - -DENABLE_PYTHON2=OFF \ - -DENABLE_AEC=ON + -DCMAKE_Fortran_FLAGS="-fPIC" # note the final '..' is no longer needed to the cmake3 call. # this is now hidden in the %%cmake3 macro @@ -240,6 +290,17 @@ 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 +# # 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 # -DCMAKE_SKIP_INSTALL_RPATH=TRUE @@ -296,13 +357,211 @@ ctest3 -V %{?_smp_mflags} %doc %{_datadir}/doc/%{name}/ %changelog -* Sat Sep 09 2023 Jos de Kloe - 2.31.0-1 +* Sun Dec 17 2023 Orion Poplawski - 2.33.0-1 +- Update to 2.33.0 + +* Sun Nov 26 2023 Jos de Kloe - 2.32.1-2 +- rebuild after so name jump of libjasper + +* Thu Nov 02 2023 Jos de Kloe - 2.32.1-1 +- Upgrade to upstream version 2.32.1 and add updated test_data package + +* Thu Jul 27 2023 Jos de Kloe - 2.31.0-1 - Upgrade to upstream version 2.31.0 -* 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 Jul 19 2023 Fedora Release Engineering - 2.30.0-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild -* Fri Jun 3 2022 Jos de Kloe - 2.26.0-1 -- First epel9 version +* Sun Apr 16 2023 Jos de Kloe - 2.30.0-1 +- Upgrade to upstream version 2.30.0 + +* Sun Mar 26 2023 Jos de Kloe - 2.29.0-1 +- Upgrade to upstream version 2.29.0 + Note that the source code now uses g++ in stead of gcc for compilation. + +* Sun Feb 12 2023 Jos de Kloe - 2.28.0-1 +- Upgrade to upstream version 2.28.0 + +* Thu Jan 19 2023 Fedora Release Engineering - 2.27.1-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild + +* Sat Dec 10 2022 Jos de Kloe - 2.27.1-1 +- Upgrade to upstream version 2.27.1 and SPDX migration + +* Wed Sep 14 2022 Jos de Kloe - 2.27.0-2 +- fix problem with use of _sourcedir + +* Mon Aug 29 2022 Jos de Kloe - 2.27.0-1 +- Upgrade to upstream version 2.27.0 +- Added generation of man pages for tools that support the --help option + +* Thu Jul 21 2022 Fedora Release Engineering - 2.26.0-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild + +* Thu May 26 2022 Jos de Kloe - 2.26.0-1 +- Upgrade to upstream version 2.26.0 + +* Fri May 20 2022 Sandro Mani - 2.25.0-2 +- Rebuild for gdal-3.5.0 and/or openjpeg-2.5.0 + +* Sun Mar 06 2022 Jos de Kloe - 2.25.0-1 +- Upgrade to upstream version 2.25.0 +- Add new BR libaec-devel + +* Mon Feb 14 2022 Mamoru TASAKA - 2.24.0-4 +- jasper3: use wrapper entry point for jpeg2000 decoder + +* Sun Feb 13 2022 Josef Ridky - 2.24.0-3 +- Rebuilt for libjasper.so.6 + +* Thu Jan 20 2022 Fedora Release Engineering - 2.24.0-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild + +* Thu Dec 09 2021 Jos de Kloe - 2.24.0-1 +- Upgrade to upstream version 2.24.0 +- Remove no longer needed patch2 (grib_to_netcdf test fix) + +* Wed Dec 1 2021 Mamoru TASAKA - 2.23.0-2 +- Patch grib_api_internal.h for big endian test suite issue (upstream bug SUP-2410) + +* Thu Sep 02 2021 Jos de Kloe - 2.23.0-1 +- Upgrade to upstream version 2.23.0 + +* Wed Aug 11 2021 Orion Poplawski - 2.22.1-4 +- Rebuild for netcdf 4.8.0 + +* Tue Aug 10 2021 Orion Poplawski - 2.22.1-3 +- Rebuild for netcdf 4.8.0 + +* Wed Jul 21 2021 Fedora Release Engineering - 2.22.1-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild + +* Sat Jun 19 2021 Jos de Kloe - 2.22.1-1 +- Upgrade to upstream version 2.22.1 + +* Mon May 24 2021 Jos de Kloe - 2.22.0-1 +- Upgrade to upstream version 2.22.0 + +* Sun Mar 28 2021 Jos de Kloe - 2.21.0-1 +- Upgrade to upstream version 2.21.0 + +* Tue Jan 26 2021 Fedora Release Engineering - 2.20.0-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild + +* Sat Jan 23 2021 Jos de Kloe - 2.20.0-1 +- Upgrade to upstream version 2.20.0 + +* Fri Nov 13 2020 Jos de Kloe - 2.19.1-1 +- Upgrade to upstream version 2.19.1 + +* Sat Oct 17 2020 Jos de Kloe - 2.19.0-1 +- Upgrade to upstream version 2.19.0 and remove patch 1 +- Add -fpic to the fortran flags (needed for compiling on armv7hl) + +* Wed Aug 05 2020 Jos de Kloe - 2.18.0-5 +- Adapt the spec file to use the new style cmake macros + +* Sat Aug 01 2020 Fedora Release Engineering - 2.18.0-4 +- Second attempt - Rebuilt for + https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild + +* Mon Jul 27 2020 Fedora Release Engineering - 2.18.0-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild + +* 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 + +* Sun Oct 7 2018 Jos de Kloe - 2.9.0-1 +- Upgrade to upstream version 2.9.0 + +* Sat Sep 15 2018 Jos de Kloe - 2.8.2-4 +- add Excludearch for aarch64 on epel7 + +* Sat Sep 15 2018 Jos de Kloe - 2.8.2-3 +- Explicitely disable python in cmake call and use ctest3 rather than ctest + to ensure the build runs on EPEL-7 as well + +* Thu Sep 13 2018 Jos de Kloe - 2.8.2-2 +- Remove python2 sub-package as per Mass Python 2 Package Removal for f30 + +* Sun Sep 9 2018 Jos de Kloe - 2.8.2-1 +- Upgrade to version 2.8.2 + +* Fri Aug 17 2018 Jos de Kloe - 2.8.0-3 +- rebuild with patch provided by Matthew Krupcale for f28 + +* Thu Jul 12 2018 Fedora Release Engineering - 2.8.0-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild + +* Thu Jul 5 2018 Jos de Kloe - 2.8.0-1 +- Upgrade to version 2.8.0 + +* Tue May 08 2018 Jos de Kloe - 2.7.3-1 +- Upgrade to version 2.7.3 +- adjust latest grib_api version to 1.26.1-1 + +* Thu Mar 29 2018 Jos de Kloe - 2.7.0-2 +- added ExcludeArch statements for the failing architectures + +* Thu Mar 22 2018 Jos de Kloe - 2.7.0-1 +- Upgrade to version 2.7.0 +- Fix rpath and some permission issues +- Remove Provides, add post/postun sections, add LD_LIBRARY_PATH +- Fix failing tests in check section +- 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-Andre Mauchin +- Add a documentation and a data sub-package +- Change the license and add a note explaining why this was done + +* Fri Mar 24 2017 Orion Poplawski - 2.2.0-1 +- Initial Fedora package diff --git a/sources b/sources index 88bfe9e..3faa9cf 100644 --- a/sources +++ b/sources @@ -1,3 +1,5 @@ SHA512 (eccodes_test_data_20220526.tar.gz) = 0457878caad6a3395daf60e27cfb72121526065b0cf4da144c7499b8d38bebae0952ddbd20ef0eb53fad77ada60160039340da01001f19fbb7fb1ccbb3d0547a SHA512 (eccodes-2.30.0-Source.tar.gz) = 07b67cef67cefb32ad4581813ed8814f9394d27846c8bc41b78b1504d296f84547d1fb72ce4813f214fe09b9391449995dd53cf9ae7d27721e2b34353ee58b00 SHA512 (eccodes-2.31.0-Source.tar.gz) = f3fe70ad0a765ae6e9d23b1b0c6ac96ad81a8324b15b7ebbcc958ffa1a046079d4a9953d720a8c15ac421897059a74c96ea678254f59c88538e3dd4970da131c +SHA512 (eccodes-2.33.0-Source.tar.gz) = 4afc2a9e59da54093eb318a1447904faac7371df980a57ce21e04ef98d1d7e02f10ef363a497d29f086b1f17a86ba4e46bf14898cd227eae8bbe0297c62b4183 +SHA512 (eccodes_test_data_20231216.tar.gz) = 86767a308841849c7ece006e9f6c68123dc07d8640b038e25529b91ab495d3f10ad5356e9100ef238de6756c67917be13a676f4ab0708fb381021c746e00183e From ec509e7c135d1f4a846e95360b6dfa82cd97b222 Mon Sep 17 00:00:00 2001 From: Jos de Kloe Date: Sun, 1 Sep 2024 12:51:55 +0200 Subject: [PATCH 6/6] update to version 2.36.0 --- .gitignore | 2 ++ eccodes-soversion.patch | 12 ++++----- eccodes-thread-init-fix.patch | 47 +++++++++++++++++++++++++++++++++++ eccodes.spec | 18 +++++++++++--- sources | 2 ++ 5 files changed, 71 insertions(+), 10 deletions(-) create mode 100644 eccodes-thread-init-fix.patch diff --git a/.gitignore b/.gitignore index 5f2b0c5..3d7e578 100644 --- a/.gitignore +++ b/.gitignore @@ -4,3 +4,5 @@ /eccodes-2.31.0-Source.tar.gz /eccodes-2.33.0-Source.tar.gz /eccodes_test_data_20231216.tar.gz +/eccodes-2.36.0-Source.tar.gz +/eccodes_test_data_20240217.tar.gz diff --git a/eccodes-soversion.patch b/eccodes-soversion.patch index 03b520c..5a3e406 100644 --- a/eccodes-soversion.patch +++ b/eccodes-soversion.patch @@ -1,6 +1,6 @@ ---- eccodes-2.32.1-Source.unchanged/fortran/CMakeLists.txt 2023-10-26 17:16:35.000000000 +0200 -+++ eccodes-2.32.1-Source/fortran/CMakeLists.txt 2023-10-29 15:39:34.397319711 +0100 -@@ -49,7 +49,8 @@ if( HAVE_FORTRAN ) +--- eccodes-2.35.0-Source.unchanged/fortran/CMakeLists.txt 2024-04-11 12:13:21.000000000 +0200 ++++ eccodes-2.35.0-Source/fortran/CMakeLists.txt 2024-05-04 16:18:42.732436699 +0200 +@@ -46,7 +46,8 @@ if( HAVE_FORTRAN ) GENERATED grib_f90.f90 eccodes_f90.f90 PUBLIC_INCLUDES $ $ @@ -10,9 +10,9 @@ if( DEFINED ecbuild_VERSION AND NOT ${ecbuild_VERSION} VERSION_LESS 3.1 ) # Installed module directory is not in the PUBLIC INCLUDES! ---- eccodes-2.32.1-Source.unchanged/src/CMakeLists.txt 2023-10-26 17:16:35.000000000 +0200 -+++ eccodes-2.32.1-Source/src/CMakeLists.txt 2023-10-29 15:39:34.397319711 +0100 -@@ -411,6 +411,8 @@ ecbuild_add_library( TARGET eccodes +--- eccodes-2.35.0-Source.unchanged/src/CMakeLists.txt 2024-04-11 12:13:21.000000000 +0200 ++++ eccodes-2.35.0-Source/src/CMakeLists.txt 2024-05-04 16:18:42.733436675 +0200 +@@ -416,6 +416,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 ${eccodes_extra_src_files} diff --git a/eccodes-thread-init-fix.patch b/eccodes-thread-init-fix.patch new file mode 100644 index 0000000..0f28ec9 --- /dev/null +++ b/eccodes-thread-init-fix.patch @@ -0,0 +1,47 @@ +--- eccodes-2.36.0-Source.unchanged/src/accessor/grib_accessor_class_bufr_elements_table.cc 2024-06-24 12:52:58.000000000 +0200 ++++ eccodes-2.36.0-Source/src/accessor/grib_accessor_class_bufr_elements_table.cc 2024-07-23 19:38:30.211681092 +0200 +@@ -1,4 +1,3 @@ +- + /* + * (C) Copyright 2005- ECMWF. + * +@@ -28,7 +27,7 @@ static void thread_init() + static int once = 0; + static omp_nest_lock_t mutex1; + +-void thread_init() ++static void thread_init() + { + GRIB_OMP_CRITICAL(lock_grib_accessor_class_bufr_elements_table_c) + { +--- eccodes-2.36.0-Source.unchanged/src/accessor/grib_accessor_class_codetable.cc 2024-06-24 12:52:58.000000000 +0200 ++++ eccodes-2.36.0-Source/src/accessor/grib_accessor_class_codetable.cc 2024-07-23 19:38:30.248680436 +0200 +@@ -20,7 +20,7 @@ grib_accessor_class* grib_accessor_class + static pthread_once_t once = PTHREAD_ONCE_INIT; + static pthread_mutex_t mutex1 = PTHREAD_MUTEX_INITIALIZER; + +-void thread_init() ++static void thread_init() + { + pthread_mutexattr_t attr; + pthread_mutexattr_init(&attr); +@@ -32,7 +32,7 @@ void thread_init() + static int once = 0; + static omp_nest_lock_t mutex1; + +-void thread_init() ++static void thread_init() + { + GRIB_OMP_CRITICAL(lock_grib_accessor_class_codetable_c) + { +--- eccodes-2.36.0-Source.unchanged/src/accessor/grib_accessor_class_smart_table.cc 2024-06-24 12:52:58.000000000 +0200 ++++ eccodes-2.36.0-Source/src/accessor/grib_accessor_class_smart_table.cc 2024-07-23 19:38:30.248680436 +0200 +@@ -30,7 +30,7 @@ static void thread_init() + static int once = 0; + static omp_nest_lock_t mutex; + +-void thread_init() ++static void thread_init() + { + GRIB_OMP_CRITICAL(lock_grib_accessor_class_smart_table_c) + { diff --git a/eccodes.spec b/eccodes.spec index 3add048..a3120fc 100644 --- a/eccodes.spec +++ b/eccodes.spec @@ -3,7 +3,7 @@ %endif Name: eccodes -Version: 2.33.0 +Version: 2.36.0 Release: 1%{?dist} Summary: WMO data format decoding and encoding @@ -14,7 +14,7 @@ Summary: WMO data format decoding and encoding # note that the test_data package provided on the ECMWF version # is unversioned, so use the download date to discriminate # between different versions. -%global datapack_date 20231216 +%global datapack_date 20240217 # 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 @@ -56,6 +56,13 @@ Source2: eccodes_create_man_pages.sh # https://jira.ecmwf.int/browse/SUP-1809 Patch1: eccodes-soversion.patch +# Add a patch to solve the multiple definition of thread_init() +# that was introduced in eccodes v2.36.0 +# This patch was provided upstream on 22-Jul-2024, see this github commit: +# https://github.com/ecmwf/eccodes/commit/809fb997282dd97058862261b1a36647f919f3b2 +Patch2: eccodes-thread-init-fix.patch + + # note that the requests to make the other issues public are filed here: # https://jira.ecmwf.int/browse/SUP-2073 # (and again, unfortunately this issue is not public) @@ -79,8 +86,8 @@ 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 +# 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, # unless a user wishes to read and study all these grib and bufr # file format definitions. @@ -357,6 +364,9 @@ ctest3 -V %{?_smp_mflags} %doc %{_datadir}/doc/%{name}/ %changelog +* Sun Sep 01 2024 Jos de Kloe - 2.36.0-1 +- Update to 2.36.0 + * Sun Dec 17 2023 Orion Poplawski - 2.33.0-1 - Update to 2.33.0 diff --git a/sources b/sources index 3faa9cf..bf89350 100644 --- a/sources +++ b/sources @@ -3,3 +3,5 @@ SHA512 (eccodes-2.30.0-Source.tar.gz) = 07b67cef67cefb32ad4581813ed8814f9394d278 SHA512 (eccodes-2.31.0-Source.tar.gz) = f3fe70ad0a765ae6e9d23b1b0c6ac96ad81a8324b15b7ebbcc958ffa1a046079d4a9953d720a8c15ac421897059a74c96ea678254f59c88538e3dd4970da131c SHA512 (eccodes-2.33.0-Source.tar.gz) = 4afc2a9e59da54093eb318a1447904faac7371df980a57ce21e04ef98d1d7e02f10ef363a497d29f086b1f17a86ba4e46bf14898cd227eae8bbe0297c62b4183 SHA512 (eccodes_test_data_20231216.tar.gz) = 86767a308841849c7ece006e9f6c68123dc07d8640b038e25529b91ab495d3f10ad5356e9100ef238de6756c67917be13a676f4ab0708fb381021c746e00183e +SHA512 (eccodes-2.36.0-Source.tar.gz) = c18df75593af6461dfa64d717ec5a6af9492bc5a851b87f13ca759343abfbf21ec6e3e5978654f95641e86429b9b105bceb9414f8d925275d2a1b305441905d0 +SHA512 (eccodes_test_data_20240217.tar.gz) = c495a71f18ea01aa480b0920fbfce8d370574d412c95eb04823d0d4544fed0e2dba8e98d63e2be0a3c33a127840e7262d391373fab9304a773e9764457ade5a7