summaryrefslogtreecommitdiff
path: root/dev-db
diff options
context:
space:
mode:
authorArfrever Frehtes Taifersar Arahesis <arfrever@gentoo.org>2009-08-12 17:03:43 +0000
committerArfrever Frehtes Taifersar Arahesis <arfrever@gentoo.org>2009-08-12 17:03:43 +0000
commit622bd348ef3deb4307b00f75675260d75cb25137 (patch)
treebdd6f45a7aacd7a375d2e5b57223a9cb7f18a60c /dev-db
parentfixed build fail with kde 4 installed (diff)
downloadgentoo-2-622bd348ef3deb4307b00f75675260d75cb25137.tar.gz
gentoo-2-622bd348ef3deb4307b00f75675260d75cb25137.tar.bz2
gentoo-2-622bd348ef3deb4307b00f75675260d75cb25137.zip
Don't rebuild SQLite in src_install().
(Portage version: 14014-svn/cvs/Linux x86_64)
Diffstat (limited to 'dev-db')
-rw-r--r--dev-db/sqlite/ChangeLog6
-rw-r--r--dev-db/sqlite/files/sqlite-3.6.17-fix_installation.patch116
-rw-r--r--dev-db/sqlite/sqlite-3.6.17.ebuild7
3 files changed, 125 insertions, 4 deletions
diff --git a/dev-db/sqlite/ChangeLog b/dev-db/sqlite/ChangeLog
index 564aac98140c..1896a7baea42 100644
--- a/dev-db/sqlite/ChangeLog
+++ b/dev-db/sqlite/ChangeLog
@@ -1,6 +1,10 @@
# 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.265 2009/08/10 18:26:10 arfrever Exp $
+# $Header: /var/cvsroot/gentoo-x86/dev-db/sqlite/ChangeLog,v 1.266 2009/08/12 17:03:43 arfrever Exp $
+
+ 12 Aug 2009; Arfrever Frehtes Taifersar Arahesis <arfrever@gentoo.org>
+ sqlite-3.6.17.ebuild, +files/sqlite-3.6.17-fix_installation.patch:
+ Don't rebuild SQLite in src_install().
*sqlite-3.6.17 (10 Aug 2009)
diff --git a/dev-db/sqlite/files/sqlite-3.6.17-fix_installation.patch b/dev-db/sqlite/files/sqlite-3.6.17-fix_installation.patch
new file mode 100644
index 000000000000..2b6c2ab405af
--- /dev/null
+++ b/dev-db/sqlite/files/sqlite-3.6.17-fix_installation.patch
@@ -0,0 +1,116 @@
+https://www.sqlite.org/cvstrac/tktview?tn=4016
+
+--- Makefile.in
++++ Makefile.in
+@@ -683,8 +683,7 @@
+ $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/status.c
+
+ sqlite3.h: $(TOP)/src/sqlite.h.in
+- sed -e s/--VERS--/$(RELEASE)/ $(TOP)/src/sqlite.h.in | \
+- sed -e s/--VERSION-NUMBER--/$(VERSION_NUMBER)/ >sqlite3.h
++ cat $(TOP)/src/sqlite.h.in | tclsh $(TOP)/tool/mksqlite3h.tcl `cat ${TOP}/VERSION` > sqlite3.h
+
+ table.lo: $(TOP)/src/table.c $(HDR)
+ $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/table.c
+--- main.mk
++++ main.mk
+@@ -389,9 +389,7 @@
+ awk -f $(TOP)/addopcodes.awk parse.h.temp >parse.h
+
+ sqlite3.h: $(TOP)/src/sqlite.h.in
+- sed -e s/--VERS--/`cat ${TOP}/VERSION`/ \
+- -e s/--VERSION-NUMBER--/`cat ${TOP}/VERSION | sed 's/[^0-9]/ /g' | $(NAWK) '{printf "%d%03d%03d",$$1,$$2,$$3}'`/ \
+- $(TOP)/src/sqlite.h.in >sqlite3.h
++ cat $(TOP)/src/sqlite.h.in | tclsh $(TOP)/tool/mksqlite3h.tcl `cat ${TOP}/VERSION` > sqlite3.h
+
+ keywordhash.h: $(TOP)/tool/mkkeywordhash.c
+ $(BCC) -o mkkeywordhash $(OPTS) $(TOP)/tool/mkkeywordhash.c
+--- tool/mksqlite3c.tcl
++++ tool/mksqlite3c.tcl
+@@ -305,36 +305,3 @@
+
+ close $out
+
+-# This block overwrites the copy of sqlite3.h in the current directory.
+-#
+-# It copies tsrc/sqlite3.h to ./sqlite3.h, adding SQLITE_API in front of the
+-# API functions and global variables as it goes.
+-#
+-set fd_in [open tsrc/sqlite3.h r]
+-set fd_out [open sqlite3.h w]
+-while {![eof $fd_in]} {
+- set varpattern {^[a-zA-Z][a-zA-Z_0-9 *]+sqlite3_[_a-zA-Z0-9]+(\[|;| =)}
+- set declpattern {^ *[a-zA-Z][a-zA-Z_0-9 ]+ \**sqlite3_[_a-zA-Z0-9]+\(}
+-
+- set line [gets $fd_in]
+- if {[regexp {define SQLITE_EXTERN extern} $line]} {
+- puts $fd_out $line
+- puts $fd_out [gets $fd_in]
+- puts $fd_out ""
+- puts $fd_out "#ifndef SQLITE_API"
+- puts $fd_out "# define SQLITE_API"
+- puts $fd_out "#endif"
+- set line ""
+- }
+-
+- if {([regexp $varpattern $line] && ![regexp {^ *typedef} $line])
+- || ([regexp $declpattern $line])
+- } {
+- set line "SQLITE_API $line"
+- }
+- puts $fd_out $line
+-}
+-close $fd_out
+-close $fd_in
+-
+-
+--- tool/mksqlite3h.tcl
++++ tool/mksqlite3h.tcl
+@@ -0,0 +1,47 @@
++#!/usr/bin/tclsh
++#
++# This script performs processing on src/sqlite.h.in. It:
++#
++# 1) Adds SQLITE_EXTERN in front of the declaration of global variables,
++# 2) Adds SQLITE_API in front of the declaration of API functions,
++# 3) Replaces the string --VERS-- with the current library version,
++# formatted as a string (e.g. "3.6.17"), and
++# 4) Replaces the string --VERSION-NUMBER-- with current library version,
++# formatted as an integer (e.g. "3006017").
++#
++# This script reads from stdin, and outputs to stdout. The current library
++# version number should be passed as the only argument. Example invocation:
++#
++# cat sqlite.h.in | mksqlite3h.tcl 3.6.17 > sqlite3.h
++#
++
++set zVersion [lindex $argv 0]
++set nVersion [eval format "%d%03d%03d" [split $zVersion .]]
++
++while {![eof stdin]} {
++ set varpattern {^[a-zA-Z][a-zA-Z_0-9 *]+sqlite3_[_a-zA-Z0-9]+(\[|;| =)}
++ set declpattern {^ *[a-zA-Z][a-zA-Z_0-9 ]+ \**sqlite3_[_a-zA-Z0-9]+\(}
++
++ set line [gets stdin]
++
++ regsub -- --VERS-- $line $zVersion line
++ regsub -- --VERSION-NUMBER-- $line $nVersion line
++
++ if {[regexp {define SQLITE_EXTERN extern} $line]} {
++ puts $line
++ puts [gets stdin]
++ puts ""
++ puts "#ifndef SQLITE_API"
++ puts "# define SQLITE_API"
++ puts "#endif"
++ set line ""
++ }
++
++ if {([regexp $varpattern $line] && ![regexp {^ *typedef} $line])
++ || ([regexp $declpattern $line])
++ } {
++ set line "SQLITE_API $line"
++ }
++ puts $line
++}
++
diff --git a/dev-db/sqlite/sqlite-3.6.17.ebuild b/dev-db/sqlite/sqlite-3.6.17.ebuild
index 778a5054e6d6..b2d9deed3037 100644
--- a/dev-db/sqlite/sqlite-3.6.17.ebuild
+++ b/dev-db/sqlite/sqlite-3.6.17.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.17.ebuild,v 1.1 2009/08/10 18:26:10 arfrever Exp $
+# $Header: /var/cvsroot/gentoo-x86/dev-db/sqlite/sqlite-3.6.17.ebuild,v 1.2 2009/08/12 17:03:43 arfrever Exp $
EAPI="2"
@@ -25,9 +25,10 @@ DEPEND="${RDEPEND}
src_prepare() {
# note: this sandbox fix is no longer needed with sandbox-1.3+
- epatch "${FILESDIR}"/sandbox-fix2.patch
+ epatch "${FILESDIR}/sandbox-fix2.patch"
- epatch "${FILESDIR}"/${PN}-3.6.16-tkt3922.test.patch
+ epatch "${FILESDIR}/${PN}-3.6.16-tkt3922.test.patch"
+ epatch "${FILESDIR}/${P}-fix_installation.patch"
epunt_cxx
}