[2/2] FMT - Use pre-downloaded bundle of FMT sources

This commit is contained in:
Michal Schorm 2024-01-10 17:32:35 +01:00
parent 4767b335b9
commit 73fa57764d
4 changed files with 25 additions and 0 deletions

1
.gitignore vendored
View File

@ -1,3 +1,4 @@
/*/
/*.rpm
/*.tar.gz
/*.zip

16
mariadb-fmt_bundle.patch Normal file
View File

@ -0,0 +1,16 @@
Currently, the CMAKE script is able to aither use the system library, or download a bundle.
We don't have FMT as a system library in RHEL, and we can't *download* a bundle during build time.
So we download the bundle ourselves, add it as additional package sources, and redirect the CMAKE
so it would search for it on the correct - local - location.
--- mariadb-10.11.6/cmake/libfmt.cmake 2023-11-08 16:51:39.000000000 +0100
+++ mariadb-10.11.6/cmake/libfmt.cmake_patched 2024-01-10 17:29:18.004421343 +0100
@@ -15,7 +15,7 @@ MACRO(BUNDLE_LIBFMT)
ExternalProject_Add(
libfmt
PREFIX "${dir}"
- URL "https://github.com/fmtlib/fmt/archive/refs/tags/8.0.1.zip"
+ URL "${CMAKE_BINARY_DIR}/bundles/8.0.1.zip"
URL_MD5 e77873199e897ca9f780479ad68e25b1
INSTALL_COMMAND ""
CONFIGURE_COMMAND ""

View File

@ -163,6 +163,7 @@ URL: http://mariadb.org
License: GPLv2 and LGPLv2
Source0: https://downloads.mariadb.org/interstitial/mariadb-%{version}/source/mariadb-%{version}.tar.gz
Source1: https://github.com/fmtlib/fmt/archive/refs/tags/8.0.1.zip
Source2: mysql_config_multilib.sh
Source3: my.cnf.in
Source6: README.mariadb-docs
@ -215,6 +216,8 @@ Patch9: %{pkgnamepatch}-ownsetup.patch
# Patch10: Fix cipher name in the SSL Cipher name test
Patch10: %{pkgnamepatch}-ssl-cipher-tests.patch
Patch11: %{pkgnamepatch}-fmt_bundle.patch
BuildRequires: make
BuildRequires: cmake gcc-c++
BuildRequires: multilib-rpm-config
@ -741,6 +744,7 @@ rm -r storage/rocksdb/
%patch4 -p1
%patch7 -p1
%patch9 -p1
%patch11 -p1
# The test in Patch 10 has been recently updated by upstream
# and the test was disabled in the testuite run
# main.ssl_cipher [ disabled ] MDEV-17184 - Failures with OpenSSL 1.1.1
@ -764,6 +768,9 @@ cat %{SOURCE52} | tee -a mysql-test/unstable-tests
cat %{SOURCE53} | tee -a mysql-test/unstable-tests
%endif
mkdir -p %{_vpath_builddir}/bundles
cp %{SOURCE1} %{_vpath_builddir}/bundles/
cp %{SOURCE2} %{SOURCE3} %{SOURCE10} %{SOURCE11} %{SOURCE12} \
%{SOURCE14} %{SOURCE15} %{SOURCE16} %{SOURCE18} %{SOURCE70} %{SOURCE73} scripts

View File

@ -1 +1,2 @@
SHA512 (mariadb-10.11.6.tar.gz) = 3d77f7be4a26d5a36af56150a5f8ed5e21adeed9bc8ea1bd694e47a25a571bd73468eada7c96e0dfe5a6c81bef625abf71a56d228cf43a738e555e3c0d824a6a
SHA512 (8.0.1.zip) = 53f781e33ffb3bc38d743b81c5755a7d71dce95dcf5cdf23d5b4cf880a8f29189ca1b790272ee8586cbcd552648bae040247e572b2a97cd8b3631c284873f57d