[nodejs-sqlite3] Fix gcc 4.9 compilation issues
Tom Hughes
tomh at fedoraproject.org
Mon Mar 4 17:48:49 UTC 2013
commit 1e65a18f2d9686c6c52defe38171abf9f6964e50
Author: Tom Hughes <tom at compton.nu>
Date: Mon Mar 4 17:48:35 2013 +0000
Fix gcc 4.9 compilation issues
nodejs-sqlite3-callbacks.patch | 43 ++++++++++++++++++++++++++++++++++++++++
nodejs-sqlite3.spec | 8 ++++++-
2 files changed, 50 insertions(+), 1 deletions(-)
---
diff --git a/nodejs-sqlite3-callbacks.patch b/nodejs-sqlite3-callbacks.patch
new file mode 100644
index 0000000..b455323
--- /dev/null
+++ b/nodejs-sqlite3-callbacks.patch
@@ -0,0 +1,43 @@
+commit 775eb6e08ffe970801df9adb93528299ab329ddc
+Author: Tom Hughes <tom at compton.nu>
+Date: Mon Mar 4 17:44:28 2013 +0000
+
+ Move some protected methods to public
+
+ Starting with version 4.8 gcc complains about attempts to pass these
+ protected methods to NODE_SET_PROTOTYPE_METHOD as the callback.
+
+diff --git a/src/statement.h b/src/statement.h
+index 14c06aa..0b6e60c 100644
+--- a/src/statement.h
++++ b/src/statement.h
+@@ -195,11 +195,6 @@ public:
+ if (!finalized) Finalize();
+ }
+
+-protected:
+- static void Work_BeginPrepare(Database::Baton* baton);
+- static void Work_Prepare(uv_work_t* req);
+- static void Work_AfterPrepare(uv_work_t* req);
+-
+ WORK_DEFINITION(Bind);
+ WORK_DEFINITION(Get);
+ WORK_DEFINITION(Run);
+@@ -207,10 +202,16 @@ protected:
+ WORK_DEFINITION(Each);
+ WORK_DEFINITION(Reset);
+
++ static Handle<Value> Finalize(const Arguments& args);
++
++protected:
++ static void Work_BeginPrepare(Database::Baton* baton);
++ static void Work_Prepare(uv_work_t* req);
++ static void Work_AfterPrepare(uv_work_t* req);
++
+ static void AsyncEach(uv_async_t* handle, int status);
+ static void CloseCallback(uv_handle_t* handle);
+
+- static Handle<Value> Finalize(const Arguments& args);
+ static void Finalize(Baton* baton);
+ void Finalize();
+
diff --git a/nodejs-sqlite3.spec b/nodejs-sqlite3.spec
index b402b93..13aeb84 100644
--- a/nodejs-sqlite3.spec
+++ b/nodejs-sqlite3.spec
@@ -2,7 +2,7 @@
Name: nodejs-sqlite3
Version: 2.1.5
-Release: 2%{?dist}
+Release: 3%{?dist}
Summary: Asynchronous, non-blocking SQLite3 bindings for Node.js
License: BSD
@@ -16,6 +16,8 @@ Patch1: nodejs-sqlite3-paths.patch
Patch2: nodejs-sqlite3-async.patch
# Will offer upstream when node 0.10 is released
Patch3: nodejs-sqlite3-uv.patch
+# Will discuss with upstream
+Patch4: nodejs-sqlite3-callbacks.patch
BuildRequires: nodejs-devel
BuildRequires: node-gyp
@@ -36,6 +38,7 @@ BuildRequires: npm(step)
%patch1 -p0
%patch2 -p1 -b .async
%patch3 -p1 -b .uv
+%patch4 -p1 -b .callbacks
rm -rf deps node_modules
@@ -67,6 +70,9 @@ install -p -D -m0755 build/Release/node_sqlite3.node %{buildroot}%{nodejs_sitear
%changelog
+* Mon Mar 4 2013 Tom Hughes <tom at compton.nu> - 2.1.5-3
+- Fix gcc 4.8 compilation issues
+
* Sat Mar 2 2013 Tom Hughes <tom at compton.nu> - 2.1.5-2
- Fix permissions on node_sqite3.node
- Improve description
More information about the scm-commits
mailing list