commit ece3e9c424ca27ad414b507868aa08b804cfb752 Author: Marcin Krol <h...@tld-linux.org> Date: Tue Jul 18 22:01:57 2023 +0200
- switch to Python 3 mongo-c-driver.spec | 4 +++- python3.patch | 17 +++++++++++++++++ 2 files changed, 20 insertions(+), 1 deletion(-) --- diff --git a/mongo-c-driver.spec b/mongo-c-driver.spec index 1c4dbf1..f053fc9 100644 --- a/mongo-c-driver.spec +++ b/mongo-c-driver.spec @@ -21,13 +21,14 @@ Group: Libraries #Source0Download: https://github.com/mongodb/mongo-c-driver/releases/ Source0: https://github.com/mongodb/mongo-c-driver/releases/download/%{version}/%{name}-%{version}.tar.gz # Source0-md5: 8e88d6d3b5360d81ce61e98fce27df94 +Patch0: python3.patch URL: https://github.com/mongodb/mongo-c-driver BuildRequires: cmake >= 3.15 %{?with_sasl:BuildRequires: cyrus-sasl-devel} BuildRequires: libicu-devel %{?with_ssl:BuildRequires: openssl-devel} BuildRequires: pkgconfig -BuildRequires: python +BuildRequires: python3 >= 1:3.2 BuildRequires: snappy-devel %{?with_doc:BuildRequires: sphinx-pdg} BuildRequires: zlib-devel >= 1.2.12 @@ -131,6 +132,7 @@ Dokumentacja API biblioteki libbson. %prep %setup -q +%patch0 -p1 %build %cmake -B cmake-build \ diff --git a/python3.patch b/python3.patch new file mode 100644 index 0000000..ccdb026 --- /dev/null +++ b/python3.patch @@ -0,0 +1,17 @@ +diff -ur mongo-c-driver-1.24.1.orig/CMakeLists.txt mongo-c-driver-1.24.1/CMakeLists.txt +--- mongo-c-driver-1.24.1.orig/CMakeLists.txt 2023-06-21 14:31:37.000000000 +0200 ++++ mongo-c-driver-1.24.1/CMakeLists.txt 2023-07-18 21:59:49.333339128 +0200 +@@ -240,10 +240,10 @@ + file (STRINGS ${PROJECT_SOURCE_DIR}/VERSION_CURRENT BUILD_VERSION) + message (STATUS "file VERSION_CURRENT contained BUILD_VERSION ${BUILD_VERSION}") + else () +- find_package (PythonInterp) +- if (PYTHONINTERP_FOUND) ++ find_package (Python3 3.2 REQUIRED) ++ if (Python3_FOUND) + execute_process ( +- COMMAND ${PYTHON_EXECUTABLE} build/calc_release_version.py ++ COMMAND ${Python3_EXECUTABLE} build/calc_release_version.py + WORKING_DIRECTORY ${PROJECT_SOURCE_DIR} + OUTPUT_VARIABLE CALC_RELEASE_VERSION + RESULT_VARIABLE CALC_RELEASE_VERSION_RESULT ================================================================ ---- gitweb: http://git.pld-linux.org/gitweb.cgi/packages/mongo-c-driver.git/commitdiff/ece3e9c424ca27ad414b507868aa08b804cfb752 _______________________________________________ pld-cvs-commit mailing list pld-cvs-commit@lists.pld-linux.org http://lists.pld-linux.org/mailman/listinfo/pld-cvs-commit