[gnokii/el6] - Add missing SQL file for initializing the SQLite tables - Fix configure script for proper linking
Robert Scheck
robert at fedoraproject.org
Sat Oct 11 23:15:32 UTC 2014
commit f1e52d88f27a098225e39f48f7320b04b177644c
Author: Robert Scheck <robert at fedoraproject.org>
Date: Sun Oct 12 01:15:20 2014 +0200
- Add missing SQL file for initializing the SQLite tables
- Fix configure script for proper linking against -lsqlite3
gnokii-0.6.31-sqlite3.patch | 26 ++++++++++++++++++++++++++
gnokii-sms.tables.sqlite.sql | 23 +++++++++++++++++++++++
gnokii.spec | 12 ++++++++++--
3 files changed, 59 insertions(+), 2 deletions(-)
---
diff --git a/gnokii-0.6.31-sqlite3.patch b/gnokii-0.6.31-sqlite3.patch
new file mode 100644
index 0000000..0d41b23
--- /dev/null
+++ b/gnokii-0.6.31-sqlite3.patch
@@ -0,0 +1,26 @@
+Patch by Robert Scheck <robert at fedoraproject.org> for gnokii <= 0.6.31 which adds
+the missing linking to -lsqlite3 by correcting the configure script. Without this
+patch the libsmsd_sqlite.so fails with "undefined symbol: sqlite3_open" simply.
+
+--- gnokii-0.6.31/configure.in 2011-12-02 15:53:04.000000000 +0100
++++ gnokii-0.6.31/configure.in.sqlite3 2014-10-12 00:39:03.000000000 +0200
+@@ -747,7 +747,7 @@
+ have_sqlite=no
+ PKG_CHECK_MODULES(SQLITE3, sqlite3, have_sqlite=yes, have_sqlite=no)
+ if test x$enable_sqlite != xno && test x$PKGCONF != xno ; then
+- SQLITE_LIBS=SQLITE3_LIBS
++ SQLITE_LIBS=$SQLITE3_LIBS
+ dnl SQLITE_CFLAGS=SQLITE3_CFLAGS
+ AC_SUBST(SQLITE_LIBS)
+ AC_SUBST(SQLITE_CFLAGS)
+--- gnokii-0.6.31/configure 2011-12-02 15:54:03.000000000 +0100
++++ gnokii-0.6.31/configure.sqlite3 2014-10-12 00:38:38.000000000 +0200
+@@ -17951,7 +17951,7 @@
+ have_sqlite=yes
+ fi
+ if test x$enable_sqlite != xno && test x$PKGCONF != xno ; then
+- SQLITE_LIBS=SQLITE3_LIBS
++ SQLITE_LIBS=$SQLITE3_LIBS
+
+
+ fi
diff --git a/gnokii-sms.tables.sqlite.sql b/gnokii-sms.tables.sqlite.sql
new file mode 100644
index 0000000..85a2b0f
--- /dev/null
+++ b/gnokii-sms.tables.sqlite.sql
@@ -0,0 +1,23 @@
+-- $ sqlite3 -init ./sms.tables.sqlite.sql smsd.db
+create table inbox (
+ "id" integer primary key,
+ "number" text not null,
+ "smsdate" text not null,
+ "insertdate" text not null,
+ "text" text,
+ "phone" integer,
+ "processed" integer default 0
+);
+create table outbox (
+ "id" integer primary key,
+ "number" text not null,
+ "processed_date" text not null,
+ "insertdate" text not null,
+ "text" text,
+ "phone" integer,
+ "processed" integer default 0,
+ "error" integer default -1 not null,
+ "dreport" integer default 0 not null,
+ "not_before" text default '00:00:00' not null,
+ "not_after" text default '23:59:59' not null
+);
diff --git a/gnokii.spec b/gnokii.spec
index a624fc0..272719c 100644
--- a/gnokii.spec
+++ b/gnokii.spec
@@ -2,7 +2,7 @@
Name: gnokii
Version: 0.6.30
-Release: 1%{?dist}
+Release: 2%{?dist}
Summary: Linux/Unix tool suite for various mobile phones
Group: Applications/Communications
@@ -14,11 +14,13 @@ Source3: %{name}-smsd.sysconfig
Source4: %{name}-smsd.logrotate
Source5: %{name}-smsd2mail.sh
Source6: %{name}-smsd-README.smsd2mail
+Source7: %{name}-sms.tables.sqlite.sql
# Patch to make gnokii use "htmlview" instead of "mozilla" as default browser
Patch0: %{name}-htmlview.patch
# Patch to remove port locking and apply the system-wide /usr/sbin directory
# to the path instead of the default /usr/local
Patch1: %{name}-config.patch
+Patch2: %{name}-0.6.31-sqlite3.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildRequires: flex
@@ -107,8 +109,10 @@ Requires: pkgconfig
%setup -q
#%patch0 -p0
%patch1 -p0
+%patch2 -p1
install -pm 644 %{SOURCE5} smsd2mail.sh
install -pm 644 %{SOURCE6} README.smsd2mail
+install -pm 644 %{SOURCE7} smsd/sms.tables.sqlite.sql
%build
%configure --enable-security --disable-static
@@ -232,7 +236,7 @@ fi
%files smsd-sqlite
%defattr(-,root,root,-)
-# %doc smsd/sms.tables.sqlite.sql
+%doc smsd/sms.tables.sqlite.sql
%{_libdir}/smsd/libsmsd_sqlite.so
%files devel
@@ -243,6 +247,10 @@ fi
%{_libdir}/pkgconfig/xgnokii.pc
%changelog
+* Sun Oct 12 2014 Robert Scheck <robert at fedoraproject.org> 0.6.30-2
+- Add missing SQL file for initializing the SQLite tables
+- Fix configure script for proper linking against -lsqlite3
+
* Sun Oct 09 2011 Robert Scheck <robert at fedoraproject.org> 0.6.30-1
- Update to 0.6.30 and added SQLite subpackage (#466880, #735717)
More information about the scm-commits
mailing list