summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPetteri Räty <betelgeuse@gentoo.org>2009-11-22 09:09:38 +0000
committerPetteri Räty <betelgeuse@gentoo.org>2009-11-22 09:09:38 +0000
commit4e588cd4e7d9cca5c48c44748bbf9acde301dc5a (patch)
treed7da6ff7f124a3875330236114bee19444c865b6 /dev-db/sqlite
parentOptimize cross compile step if host version already matches. (diff)
downloadgentoo-2-4e588cd4e7d9cca5c48c44748bbf9acde301dc5a.tar.gz
gentoo-2-4e588cd4e7d9cca5c48c44748bbf9acde301dc5a.tar.bz2
gentoo-2-4e588cd4e7d9cca5c48c44748bbf9acde301dc5a.zip
Fix bug #293405 so that fts3 support compiles when tcl is not installed. The patch is applied only when tcl is not installed because otherwise the build breaks. Because mozilla needs the support doing it like this so that we get the fix in tree faster. Patch originally from anarchy.
(Portage version: 2.2_rc49/cvs/Linux i686)
Diffstat (limited to 'dev-db/sqlite')
-rw-r--r--dev-db/sqlite/ChangeLog9
-rw-r--r--dev-db/sqlite/files/sqlite-3.6.20-fts3.patch65
-rw-r--r--dev-db/sqlite/sqlite-3.6.20-r1.ebuild7
3 files changed, 79 insertions, 2 deletions
diff --git a/dev-db/sqlite/ChangeLog b/dev-db/sqlite/ChangeLog
index 3ea7a86554cb..67aa6e611379 100644
--- a/dev-db/sqlite/ChangeLog
+++ b/dev-db/sqlite/ChangeLog
@@ -1,6 +1,13 @@
# ChangeLog for dev-db/sqlite
# Copyright 1999-2009 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/dev-db/sqlite/ChangeLog,v 1.294 2009/11/17 19:48:34 ranger Exp $
+# $Header: /var/cvsroot/gentoo-x86/dev-db/sqlite/ChangeLog,v 1.295 2009/11/22 09:09:37 betelgeuse Exp $
+
+ 22 Nov 2009; Petteri Räty <betelgeuse@gentoo.org>
+ sqlite-3.6.20-r1.ebuild, +files/sqlite-3.6.20-fts3.patch:
+ Fix bug #293405 so that fts3 support compiles when tcl is not installed.
+ The patch is applied only when tcl is not installed because otherwise the
+ build breaks. Because mozilla needs the support doing it like this so that
+ we get the fix in tree faster. Patch originally from anarchy.
17 Nov 2009; Brent Baude <ranger@gentoo.org> sqlite-3.6.19.ebuild:
Marking sqlite-3.6.19 ppc64 for bug 291913
diff --git a/dev-db/sqlite/files/sqlite-3.6.20-fts3.patch b/dev-db/sqlite/files/sqlite-3.6.20-fts3.patch
new file mode 100644
index 000000000000..3c7cb811b56c
--- /dev/null
+++ b/dev-db/sqlite/files/sqlite-3.6.20-fts3.patch
@@ -0,0 +1,65 @@
+diff -urN sqlite-3.6.20-orig/Makefile.in sqlite-3.6.20/Makefile.in
+--- sqlite-3.6.20-orig/Makefile.in 2009-11-13 20:10:50.617845091 -0600
++++ sqlite-3.6.20/Makefile.in 2009-11-13 20:10:54.994843274 -0600
+@@ -150,6 +150,11 @@
+ LIBTOOL = ./libtool
+ ALLOWRELEASE = @ALLOWRELEASE@
+
++# FTS3
++#
++TCC += -DSQLITE_CORE
++TCC += -DSQLITE_ENABLE_FTS3=1
++
+ # libtool compile/link/install
+ LTCOMPILE = $(LIBTOOL) --mode=compile --tag=CC $(TCC) $(LTCOMPILE_EXTRAS)
+ LTLINK = $(LIBTOOL) --mode=link $(TCC) $(LTCOMPILE_EXTRAS) @LDFLAGS@ $(LTLINK_EXTRAS)
+@@ -187,7 +192,11 @@
+ USE_AMALGAMATION = @USE_AMALGAMATION@
+ LIBOBJ = $(OBJS$(USE_AMALGAMATION))
+
+-
++# Object files for FTS
++#
++LIBOBJ += \
++ fts3.lo fts3_expr.lo fts3_hash.lo fts3_porter.lo fts3_tokenizer.lo fts3_tokenizer1.lo
++
+ # All of the source code files.
+ #
+ SRC = \
+@@ -832,3 +841,24 @@
+ sqlite3.dll: $(REAL_LIBOBJ) sqlite3.def
+ $(TCC) -shared -o $@ sqlite3.def \
+ -Wl,"--strip-all" $(REAL_LIBOBJ)
++
++#
++# FTS3
++#
++fts3.lo: $(TOP)/ext/fts3/fts3.c $(HDR)
++ $(LTCOMPILE) -c $(TOP)/ext/fts3/fts3.c
++
++fts3_expr.lo: $(TOP)/ext/fts3/fts3_expr.c $(HDR)
++ $(LTCOMPILE) -c $(TOP)/ext/fts3/fts3_expr.c
++
++fts3_hash.lo: $(TOP)/ext/fts3/fts3_hash.c $(HDR)
++ $(LTCOMPILE) -c $(TOP)/ext/fts3/fts3_hash.c
++
++fts3_porter.lo: $(TOP)/ext/fts3/fts3_porter.c $(HDR)
++ $(LTCOMPILE) -c $(TOP)/ext/fts3/fts3_porter.c
++
++fts3_tokenizer.lo: $(TOP)/ext/fts3/fts3_tokenizer.c $(HDR)
++ $(LTCOMPILE) -c $(TOP)/ext/fts3/fts3_tokenizer.c
++
++fts3_tokenizer1.lo: $(TOP)/ext/fts3/fts3_tokenizer1.c $(HDR)
++ $(LTCOMPILE) -c $(TOP)/ext/fts3/fts3_tokenizer1.c
+diff -urN sqlite-3.6.20-orig/src/main.c sqlite-3.6.20/src/main.c
+--- sqlite-3.6.20-orig/src/main.c 2009-11-13 20:10:50.674843345 -0600
++++ sqlite-3.6.20/src/main.c 2009-11-13 20:11:30.403822462 -0600
+@@ -17,7 +17,7 @@
+ #include "sqliteInt.h"
+
+ #ifdef SQLITE_ENABLE_FTS3
+-# include "fts3.h"
++# include "../ext/fts3/fts3.h"
+ #endif
+ #ifdef SQLITE_ENABLE_RTREE
+ # include "rtree.h"
diff --git a/dev-db/sqlite/sqlite-3.6.20-r1.ebuild b/dev-db/sqlite/sqlite-3.6.20-r1.ebuild
index b8784e5143a1..dbfcd811c9ac 100644
--- a/dev-db/sqlite/sqlite-3.6.20-r1.ebuild
+++ b/dev-db/sqlite/sqlite-3.6.20-r1.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2009 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/dev-db/sqlite/sqlite-3.6.20-r1.ebuild,v 1.1 2009/11/15 09:13:48 betelgeuse Exp $
+# $Header: /var/cvsroot/gentoo-x86/dev-db/sqlite/sqlite-3.6.20-r1.ebuild,v 1.2 2009/11/22 09:09:37 betelgeuse Exp $
EAPI="2"
@@ -43,6 +43,11 @@ src_prepare() {
rm -f test/like.test
fi
+ # http://bugs.gentoo.org/show_bug.cgi?id=293405
+ # Needed to compile without tcl installed but fails to compile when it
+ # it installed
+ use fts3 && ! has_version dev-lang/tcl && epatch "${FILESDIR}/sqlite-3.6.20-fts3.patch"
+
epunt_cxx
}