diff --git a/.gitignore b/.gitignore index adb9d23..e66b05a 100644 --- a/.gitignore +++ b/.gitignore @@ -1,7 +1,4 @@ -/eccodes-2.26.0-Source.tar.gz -/eccodes_test_data_20220526.tar.gz -/eccodes-2.27.0-Source.tar.gz -/eccodes-2.27.1-Source.tar.gz -/eccodes-2.28.0-Source.tar.gz -/eccodes-2.29.0-Source.tar.gz -/eccodes-2.30.0-Source.tar.gz +/eccodes_test_data_20250202.tar.gz +/eccodes-2.40.0-Source.tar.gz +/eccodes-2.42.0-Source.tar.gz +/eccodes-2.44.0-Source.tar.gz diff --git a/eccodes-soversion.patch b/eccodes-soversion.patch index 6646502..fd4b224 100644 --- a/eccodes-soversion.patch +++ b/eccodes-soversion.patch @@ -1,6 +1,6 @@ ---- 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 ) +--- eccodes-2.44.0-Source.unchanged/fortran/CMakeLists.txt 2025-10-06 11:49:11.000000000 +0200 ++++ eccodes-2.44.0-Source/fortran/CMakeLists.txt 2025-11-07 11:33:03.765320420 +0100 +@@ -46,7 +46,8 @@ if( HAVE_FORTRAN ) GENERATED grib_f90.f90 eccodes_f90.f90 PUBLIC_INCLUDES $ $ @@ -10,13 +10,13 @@ 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.44.0-Source.unchanged/src/eccodes/CMakeLists.txt 2025-10-06 11:49:11.000000000 +0200 ++++ eccodes-2.44.0-Source/src/eccodes/CMakeLists.txt 2025-11-07 11:33:03.784437554 +0100 +@@ -447,6 +447,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} ++ SOVERSION ${ECCODES_SOVERSION} + INSTALL_HEADERS_LIST grib_api.h diff --git a/eccodes.rpmlintrc b/eccodes.rpmlintrc deleted file mode 100644 index b6c8fb4..0000000 --- a/eccodes.rpmlintrc +++ /dev/null @@ -1,13 +0,0 @@ - -# 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 7e62b3a..bed4797 100644 --- a/eccodes.spec +++ b/eccodes.spec @@ -1,12 +1,20 @@ +%if 0%{?el8} +%undefine __cmake_in_source_build +%endif + Name: eccodes -Version: 2.30.0 -Release: 1%{?dist} +Version: 2.44.0 +Release: 2%{?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 20250202 # 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 @@ -23,7 +31,8 @@ Summary: WMO data format decoding and encoding %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 @@ -38,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 @@ -51,15 +60,14 @@ Patch1: eccodes-soversion.patch # https://jira.ecmwf.int/browse/SUP-2073 # (and again, unfortunately this issue is not public) -BuildRequires: cmake3 +BuildRequires: cmake3 >= 3.18 BuildRequires: gcc-c++ BuildRequires: gcc-gfortran BuildRequires: /usr/bin/git BuildRequires: jasper-devel -BuildRequires: libjpeg-devel +BuildRequires: openjpeg2-devel >= 2.5.2 BuildRequires: libpng-devel BuildRequires: netcdf-devel -BuildRequires: openjpeg2-devel BuildRequires: libaec-devel # For tests @@ -70,8 +78,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. @@ -100,8 +108,6 @@ Obsoletes: grib_api < %{final_grib_api_version} # as explained in bugzilla #1562066 ExcludeArch: i686 -# as explained in bugzilla #1562084 -ExcludeArch: armv7hl %description ecCodes is a package developed by ECMWF which provides an application @@ -163,6 +169,74 @@ both the official WMO tables and a number of often used local definitions by ECMWF and other meteorological centers. ##################################################### +# include a LUA scriptlet as suggested on: +# https://docs.fedoraproject.org/en-US/packaging-guidelines/Directory_Replacement/ +# to assist in replacing a directory by a symlink + +%pretrans -n eccodes-data -p + +-- This should solve a problem where directories were replaced +-- by symbolic links when upgrading eccodes from 2.41.0 to 2.42.0 + +problematic_dirs = { + "/usr/share/eccodes/definitions/bufr/tables/0/local/8/78/1", + "/usr/share/eccodes/definitions/bufr/tables/0/local/8/78/110", + "/usr/share/eccodes/definitions/bufr/tables/0/local/8/78/174", + "/usr/share/eccodes/definitions/bufr/tables/0/local/8/78/2", + "/usr/share/eccodes/definitions/bufr/tables/0/local/8/78/20", + "/usr/share/eccodes/definitions/bufr/tables/0/local/8/78/21", + "/usr/share/eccodes/definitions/bufr/tables/0/local/8/78/221", + "/usr/share/eccodes/definitions/bufr/tables/0/local/8/78/222", + "/usr/share/eccodes/definitions/bufr/tables/0/local/8/78/223", + "/usr/share/eccodes/definitions/bufr/tables/0/local/8/78/225", + "/usr/share/eccodes/definitions/bufr/tables/0/local/8/78/226", + "/usr/share/eccodes/definitions/bufr/tables/0/local/8/78/227", + "/usr/share/eccodes/definitions/bufr/tables/0/local/8/78/228", + "/usr/share/eccodes/definitions/bufr/tables/0/local/8/78/229", + "/usr/share/eccodes/definitions/bufr/tables/0/local/8/78/230", + "/usr/share/eccodes/definitions/bufr/tables/0/local/8/78/231", + "/usr/share/eccodes/definitions/bufr/tables/0/local/8/78/232", + "/usr/share/eccodes/definitions/bufr/tables/0/local/8/78/233", + "/usr/share/eccodes/definitions/bufr/tables/0/local/8/78/234", + "/usr/share/eccodes/definitions/bufr/tables/0/local/8/78/235", + "/usr/share/eccodes/definitions/bufr/tables/0/local/8/78/236", + "/usr/share/eccodes/definitions/bufr/tables/0/local/8/78/237", + "/usr/share/eccodes/definitions/bufr/tables/0/local/8/78/31", + "/usr/share/eccodes/definitions/bufr/tables/0/local/8/78/41", + "/usr/share/eccodes/definitions/bufr/tables/0/local/8/78/42", + "/usr/share/eccodes/definitions/bufr/tables/0/local/8/78/64", + "/usr/share/eccodes/definitions/bufr/tables/0/wmo/10", + "/usr/share/eccodes/definitions/bufr/tables/0/wmo/11", + "/usr/share/eccodes/definitions/bufr/tables/0/wmo/12", + "/usr/share/eccodes/definitions/bufr/tables/0/wmo/7", + "/usr/share/eccodes/definitions/bufr/tables/0/wmo/8", + "/usr/share/eccodes/definitions/bufr/tables/0/wmo/9"} + +for index, path in ipairs(problematic_dirs) do + print("handling path:" .. index .. ":" .. path) + st = posix.stat(path) + if st and st.type == "directory" then + status = os.rename(path, path .. ".rpmmoved") + if status then + print("renamed:" .. path .. " to " .. path .. ".rpmmoved") + end + if not status then + suffix = 0 + while not status do + suffix = suffix + 1 + status = os.rename(path .. ".rpmmoved", path .. ".rpmmoved." .. suffix) + if status then + print("renamed:" .. path .. ".rpmmoved to " .. path .. ".rpmmoved." .. suffix) + end + end + os.rename(path, path .. ".rpmmoved") + print("renamed:" .. path .. " to " .. path .. ".rpmmoved") + end + end +end + +--##################################################### + %package doc Summary: Documentation and example code BuildArch: noarch @@ -186,6 +260,8 @@ tar xf %SOURCE1 popd %build +# TODO: Please submit an issue to upstream (rhbz#2380563) +export CMAKE_POLICY_VERSION_MINIMUM=3.5 #-- The following features are disabled by default and not switched on: # @@ -305,6 +381,8 @@ sed -i 's|^libs=.*$|libs=-L${libdir} -leccodes_f90 -leccodes|g' %{buildroot}/%{_ %ldconfig_scriptlets + +##################################################### %check cd %{_vpath_builddir} @@ -325,7 +403,7 @@ ctest3 -V %{?_smp_mflags} %files %license LICENSE -%doc README.md ChangeLog AUTHORS NEWS NOTICE +%doc ChangeLog AUTHORS NEWS NOTICE %{_bindir}/* %{_libdir}/*.so.* %{_mandir}/man1/*.1* @@ -345,11 +423,125 @@ ctest3 -V %{?_smp_mflags} %{_datadir}/%{name}/definitions/ %{_datadir}/%{name}/samples/ %{_datadir}/%{name}/ifs_samples/ +%ghost %{_datadir}/%{name}/definitions/bufr/tables/0/local/8/78/1.rpmmoved +%ghost %{_datadir}/%{name}/definitions/bufr/tables/0/local/8/78/110.rpmmoved +%ghost %{_datadir}/%{name}/definitions/bufr/tables/0/local/8/78/174.rpmmoved +%ghost %{_datadir}/%{name}/definitions/bufr/tables/0/local/8/78/2.rpmmoved +%ghost %{_datadir}/%{name}/definitions/bufr/tables/0/local/8/78/20.rpmmoved +%ghost %{_datadir}/%{name}/definitions/bufr/tables/0/local/8/78/21.rpmmoved +%ghost %{_datadir}/%{name}/definitions/bufr/tables/0/local/8/78/221.rpmmoved +%ghost %{_datadir}/%{name}/definitions/bufr/tables/0/local/8/78/222.rpmmoved +%ghost %{_datadir}/%{name}/definitions/bufr/tables/0/local/8/78/223.rpmmoved +%ghost %{_datadir}/%{name}/definitions/bufr/tables/0/local/8/78/225.rpmmoved +%ghost %{_datadir}/%{name}/definitions/bufr/tables/0/local/8/78/226.rpmmoved +%ghost %{_datadir}/%{name}/definitions/bufr/tables/0/local/8/78/227.rpmmoved +%ghost %{_datadir}/%{name}/definitions/bufr/tables/0/local/8/78/228.rpmmoved +%ghost %{_datadir}/%{name}/definitions/bufr/tables/0/local/8/78/229.rpmmoved +%ghost %{_datadir}/%{name}/definitions/bufr/tables/0/local/8/78/230.rpmmoved +%ghost %{_datadir}/%{name}/definitions/bufr/tables/0/local/8/78/231.rpmmoved +%ghost %{_datadir}/%{name}/definitions/bufr/tables/0/local/8/78/232.rpmmoved +%ghost %{_datadir}/%{name}/definitions/bufr/tables/0/local/8/78/233.rpmmoved +%ghost %{_datadir}/%{name}/definitions/bufr/tables/0/local/8/78/234.rpmmoved +%ghost %{_datadir}/%{name}/definitions/bufr/tables/0/local/8/78/235.rpmmoved +%ghost %{_datadir}/%{name}/definitions/bufr/tables/0/local/8/78/236.rpmmoved +%ghost %{_datadir}/%{name}/definitions/bufr/tables/0/local/8/78/237.rpmmoved +%ghost %{_datadir}/%{name}/definitions/bufr/tables/0/local/8/78/31.rpmmoved +%ghost %{_datadir}/%{name}/definitions/bufr/tables/0/local/8/78/41.rpmmoved +%ghost %{_datadir}/%{name}/definitions/bufr/tables/0/local/8/78/42.rpmmoved +%ghost %{_datadir}/%{name}/definitions/bufr/tables/0/local/8/78/64.rpmmoved +%ghost %{_datadir}/%{name}/definitions/bufr/tables/0/wmo/10.rpmmoved +%ghost %{_datadir}/%{name}/definitions/bufr/tables/0/wmo/11.rpmmoved +%ghost %{_datadir}/%{name}/definitions/bufr/tables/0/wmo/12.rpmmoved +%ghost %{_datadir}/%{name}/definitions/bufr/tables/0/wmo/7.rpmmoved +%ghost %{_datadir}/%{name}/definitions/bufr/tables/0/wmo/8.rpmmoved +%ghost %{_datadir}/%{name}/definitions/bufr/tables/0/wmo/9.rpmmoved %files doc %doc %{_datadir}/doc/%{name}/ %changelog + +* Mon Nov 10 2025 Cristian Le - 2.44.0-2 +- Allow to build with CMake 4.0 (rhbz#2380563) + +* Fri Nov 07 2025 Jos de Kloe - 2.44.0-1 +- Update to 2.44.0 + +* Fri Aug 22 2025 Orion Poplawski - 2.42.0-6 +- Rebuild for netcdf 4.9.3 soname bump + +* Mon Aug 11 2025 Jos de Kloe - 2.42.0-5 +- Forgot to update the changelog date for the previous commit, so fixed this + with this update. +- Also fix a typo in the ghost definitions. + +* Mon Aug 11 2025 Jos de Kloe - 2.42.0-4 +- Add a LUA script in a pretrans section to assist in replacing a directory + by a symlink (this removes the need for the python script added in + the previous commit) + +* Wed Jul 30 2025 Jos de Kloe - 2.42.0-3 +- Add calling a little python script in the install stage to revert + the (upstream) replacing of directories by a symlinks + which causes upgrade problems with rpm for the data package. + +* Wed Jul 23 2025 Fedora Release Engineering - 2.42.0-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_43_Mass_Rebuild + +* Sat Jul 19 2025 Jos de Kloe - 2.42.0-1 +- Update to 2.42.0 (2.41.0 was skipped due to an upstream build bug) + +* Sat Mar 22 2025 Jos de Kloe - 2.40.0-1 +- Update to 2.40.0 + +* Sun Feb 02 2025 Jos de Kloe - 2.39.0-1 +- Update to 2.39.0 + +* Thu Jan 16 2025 Fedora Release Engineering - 2.38.3-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_42_Mass_Rebuild + +* Sun Oct 20 2024 Jos de Kloe - 2.38.3-1 +- Update to 2.38.3 + +* Sun Sep 29 2024 Jos de Kloe - 2.38.0-1 +- Update to 2.38.0 + +* Wed Jul 24 2024 Jos de Kloe - 2.36.0-1 +- Update to 2.36.0 + +* Wed Jul 17 2024 Fedora Release Engineering - 2.35.0-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild + +* Sat May 04 2024 Jos de Kloe - 2.35.0-1 +- Update to 2.35.0 + +* Mon Mar 04 2024 Jos de Kloe - 2.34.1-2 +- Require openjpeg2-devel >= 2.5.2 (needed to build for f40) + +* Tue Feb 27 2024 Jos de Kloe - 2.34.1-1 +- Update to 2.34.1 + +* Wed Jan 24 2024 Fedora Release Engineering - 2.33.0-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild + +* Fri Jan 19 2024 Fedora Release Engineering - 2.33.0-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild + +* 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 + +* Wed Jul 19 2023 Fedora Release Engineering - 2.30.0-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild + * Sun Apr 16 2023 Jos de Kloe - 2.30.0-1 - Upgrade to upstream version 2.30.0 diff --git a/sources b/sources index b8436d4..4dc5dc6 100644 --- a/sources +++ b/sources @@ -1,7 +1,4 @@ -SHA512 (eccodes-2.26.0-Source.tar.gz) = cd4fd2048ad98a4a5c82a0a233b2e64eb67a195d42637607423669351b6cd295b111a382f6d9ecb05ffe25f79599bf3963550ca27d84e7f9ef55e499e183a35f -SHA512 (eccodes_test_data_20220526.tar.gz) = 0457878caad6a3395daf60e27cfb72121526065b0cf4da144c7499b8d38bebae0952ddbd20ef0eb53fad77ada60160039340da01001f19fbb7fb1ccbb3d0547a -SHA512 (eccodes-2.27.0-Source.tar.gz) = b33d9a4b4abeaa2fae632fe6a4e19071769282c80b7f91f1aaa57f9908386b7c6bd842de69c4bb1b7da2bc3298b5248c808f5c94909033ef5c4a764ae85db5fa -SHA512 (eccodes-2.27.1-Source.tar.gz) = 51ba1f53913a6ae7d28f5ffc393a2ac76547be0f88e4b1700601d36863a46135e3164bc36db48d41287aa3e535664d534d0c3ca347eeb6390d6a6ac4df4fd55c -SHA512 (eccodes-2.28.0-Source.tar.gz) = d4fe307c807862f60a1f6629ca009c3eb633a6fb94d5049923bfc3fdd00b091ce233675abd5c33adfc8b61a23473491b4c71f51864584f490674ba93cc20370f -SHA512 (eccodes-2.29.0-Source.tar.gz) = 83d7848eb85026081dda9d83e4d63655c81f004a6fb9eabf40b964c4584b984269b960e9ca9bad616bbc3b9ae7c08a758bf85c01b863ed9b371ae0f80eba5993 -SHA512 (eccodes-2.30.0-Source.tar.gz) = 07b67cef67cefb32ad4581813ed8814f9394d27846c8bc41b78b1504d296f84547d1fb72ce4813f214fe09b9391449995dd53cf9ae7d27721e2b34353ee58b00 +SHA512 (eccodes_test_data_20250202.tar.gz) = 8b4c7159dd7ed0e1e69068ec7dcabe94064f0d2abf9eac4fca2a9c730d500999e8edf1e7eeebba6fb12ae99b223c1b0843e31414538333c52f2508cb2d410151 +SHA512 (eccodes-2.40.0-Source.tar.gz) = 39b09da398a864888f1b7da867adae63da9e512a865807c1dd0f4b76e242c46d6ec75f7db3a554c01c4fb60dd9677cd8b77bc03dac89931cbdf461c607b100c8 +SHA512 (eccodes-2.42.0-Source.tar.gz) = 205246b250762ab6e7ac3050726ac5ce67ab689c8c393b153e7c084fb71edc40d64ee04e2fb32b3ad2a1426e65581126c0c8288e9088c27a7468f6b534f29b58 +SHA512 (eccodes-2.44.0-Source.tar.gz) = 63f81db07103ab3c6c0497ca3d0bae5b8a0841ed83a2b88831ddce756489a84aa394af7673c1438e2ea7a55107970cf87b8222da31321ef70ecc55cc99a3ddf5