From 1e592301683a44d9be789f802854393b11793de97e421368b96ba718d3477306 Mon Sep 17 00:00:00 2001 From: Sascha Peilicke Date: Mon, 2 Sep 2013 08:34:49 +0000 Subject: [PATCH] Accepting request 196933 from home:elvigia:branches:devel:languages:python - remove runtime curl version check and __DATE__ __TIME__ usage (pycurl-no-runtime-curlvercheck.patch) OBS-URL: https://build.opensuse.org/request/show/196933 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-pycurl?expand=0&rev=17 --- pycurl-no-runtime-curlvercheck.patch | 27 +++++++++++++++++++++++++++ python-pycurl.changes | 6 ++++++ python-pycurl.spec | 3 ++- 3 files changed, 35 insertions(+), 1 deletion(-) create mode 100644 pycurl-no-runtime-curlvercheck.patch diff --git a/pycurl-no-runtime-curlvercheck.patch b/pycurl-no-runtime-curlvercheck.patch new file mode 100644 index 0000000..f291b48 --- /dev/null +++ b/pycurl-no-runtime-curlvercheck.patch @@ -0,0 +1,27 @@ +--- pycurl-7.19.0.orig/src/pycurl.c ++++ pycurl-7.19.0/src/pycurl.c +@@ -3450,7 +3450,7 @@ initpycurl(void) + + /* Add version strings to the module */ + insstr(d, "version", curl_version()); +- insstr(d, "COMPILE_DATE", __DATE__ " " __TIME__); ++ //insstr(d, "COMPILE_DATE", __DATE__ " " __TIME__); + insint(d, "COMPILE_PY_VERSION_HEX", PY_VERSION_HEX); + insint(d, "COMPILE_LIBCURL_VERSION_NUM", LIBCURL_VERSION_NUM); + +@@ -3883,6 +3883,7 @@ initpycurl(void) + insint_s(d, "LOCK_DATA_COOKIE", CURL_LOCK_DATA_COOKIE); + insint_s(d, "LOCK_DATA_DNS", CURL_LOCK_DATA_DNS); + ++#if 0 + /* Check the version, as this has caused nasty problems in + * some cases. */ + vi = curl_version_info(CURLVERSION_NOW); +@@ -3894,6 +3895,7 @@ initpycurl(void) + Py_FatalError("pycurl: libcurl link-time version is older than compile-time version"); + assert(0); + } ++#endif + + /* Initialize callback locks if ssl is enabled */ + #if defined(PYCURL_NEED_SSL_TSL) diff --git a/python-pycurl.changes b/python-pycurl.changes index de67af9..1ffc24f 100644 --- a/python-pycurl.changes +++ b/python-pycurl.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Fri Aug 30 18:07:30 UTC 2013 - crrodriguez@opensuse.org + +- remove runtime curl version check and __DATE__ __TIME__ usage + (pycurl-no-runtime-curlvercheck.patch) + ------------------------------------------------------------------- Fri Apr 5 13:16:51 UTC 2013 - idonmez@suse.com diff --git a/python-pycurl.spec b/python-pycurl.spec index 4f2fa18..9fd588a 100644 --- a/python-pycurl.spec +++ b/python-pycurl.spec @@ -25,6 +25,7 @@ License: LGPL-2.1+ and MIT Group: Development/Languages/Python Source: http://pycurl.sourceforge.net/download/pycurl-%{version}.tar.gz Patch0: pycurl-7.18.1-nostaticlibs.patch +Patch1: pycurl-no-runtime-curlvercheck.patch BuildRoot: %{_tmppath}/%{name}-%{version}-build BuildRequires: libcurl-devel >= 7.19.0 BuildRequires: openssl-devel @@ -52,7 +53,7 @@ This package contains documentation and examples. %prep %setup -q -n pycurl-%{version} %patch0 - +%patch1 -p1 %build CFLAGS="%{optflags}" python setup.py build