diff options
author | Remi Collet <fedora@famillecollet.com> | 2015-04-25 12:36:19 +0200 |
---|---|---|
committer | Remi Collet <fedora@famillecollet.com> | 2015-04-25 12:36:19 +0200 |
commit | 82927a5d596fe21681e9ac31a5fa55b6b7caec75 (patch) | |
tree | 1edb10fb9a3cac803189bf4d6ebcef33b10efbee | |
parent | 471dc76d17ef6dc1ce5e0a0dd8c4b062c8293a89 (diff) |
mongo-c-driver: test build
-rw-r--r-- | mongo-c-driver-upstream.patch | 43 | ||||
-rw-r--r-- | mongo-c-driver.spec | 11 |
2 files changed, 51 insertions, 3 deletions
diff --git a/mongo-c-driver-upstream.patch b/mongo-c-driver-upstream.patch new file mode 100644 index 0000000..0ea86b7 --- /dev/null +++ b/mongo-c-driver-upstream.patch @@ -0,0 +1,43 @@ +From 9cd2576effe2185a9cbfdad4a26c336a19dc7e8b Mon Sep 17 00:00:00 2001 +From: "A. Jesse Jiryu Davis" <jesse@mongodb.com> +Date: Fri, 24 Apr 2015 15:08:54 -0400 +Subject: [PATCH] CDRIVER-624 fix gcc and clang version checks + +--- + build/autotools/CheckCompiler.m4 | 17 +++++++++++++++-- + 1 file changed, 15 insertions(+), 2 deletions(-) + +diff --git a/build/autotools/CheckCompiler.m4 b/build/autotools/CheckCompiler.m4 +index b7fd118..0dac394 100644 +--- a/build/autotools/CheckCompiler.m4 ++++ b/build/autotools/CheckCompiler.m4 +@@ -15,14 +15,27 @@ AC_PROG_CXX + c_compiler="unknown" + AC_LANG_PUSH([C]) + AC_COMPILE_IFELSE([AC_LANG_PROGRAM([ +-#if !(defined(__GNUC__) && !defined(__clang__) && !defined(__INTEL_COMPILER) && __GNUC__ >= 4 && __GNUC_MINOR__ >= 1) ++#if !(defined(__GNUC__) && !defined(__clang__) && !defined(__INTEL_COMPILER)) + #error Not a supported GCC compiler + #endif ++#if defined(__GNUC__) ++#define GCC_VERSION (__GNUC__ * 10000 \ ++ + __GNUC_MINOR__ * 100 \ ++ + __GNUC_PATCHLEVEL__) ++#if GCC_VERSION < 40100 ++#error Not a supported GCC compiler ++#endif ++#endif + ])], [c_compiler="gcc"], []) + AC_COMPILE_IFELSE([AC_LANG_PROGRAM([ +-#if !(defined(__clang__) && (__clang_major__ > 3 || (__clang_major__ == 3 && __clang_minor__ >= 3))) ++#if defined(__clang__) ++#define CLANG_VERSION (__clang_major * 10000 \ ++ + __clang_minor__ * 100 \ ++ + __clang_patchlevel__) ++#if CLANG_VERSION < 30300 + #error Not a supported Clang compiler + #endif ++#endif + ])], [c_compiler="clang"], []) + AC_COMPILE_IFELSE([AC_LANG_PROGRAM([ + #if !(defined(__SUNPRO_C)) diff --git a/mongo-c-driver.spec b/mongo-c-driver.spec index 2d650b5..d49c89a 100644 --- a/mongo-c-driver.spec +++ b/mongo-c-driver.spec @@ -15,12 +15,15 @@ Name: mongo-c-driver Summary: Client library written in C for MongoDB Version: 1.1.4 -Release: 2%{?dist} +Release: 3%{?dist} License: ASL 2.0 Group: System Environment/Libraries URL: https://github.com/%{gh_owner}/%{gh_project} Source0: https://github.com/%{gh_owner}/%{gh_project}/releases/download/%{version}%{?prever:-%{prever}}/%{gh_project}-%{version}%{?prever:-%{prever}}.tar.gz +# open https://jira.mongodb.org/browse/CDRIVER-624 +Patch0: %{name}-upstream.patch + BuildRequires: pkgconfig(openssl) BuildRequires: pkgconfig(libbson-1.0) %if 0%{?fedora} > 21 || 0%{?rhel} > 6 @@ -72,8 +75,7 @@ a MongoDB Server. %setup -q %if 0%{?fedora} > 21 -# Workaround https://jira.mongodb.org/browse/CDRIVER-624 -sed -e 's/&& __GNUC_MINOR__ >= 1//' -i ./build/autotools/CheckCompiler.m4 +%patch0 -p1 -b .upstream autoreconf -fi %endif @@ -149,6 +151,9 @@ exit $ret %changelog +* Sat Apr 25 2015 Remi Collet <remi@fedoraproject.org> - 1.1.4-3 +- test build for upstream patch + * Thu Apr 23 2015 Remi Collet <remi@fedoraproject.org> - 1.1.4-2 - cleanup build dependencies and options |