Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 207701 | Differences between
and this patch

Collapse All | Expand All

(-)dev-db.old/sqlite/sqlite-3.5.4-r99.ebuild (+100 lines)
Line 0 Link Here
1
diff -ru ../sqlite-3.5.4.old/Makefile.in ./Makefile.in
2
--- ../sqlite-3.5.4.old/Makefile.in	2007-12-13 19:17:41.000000000 +0100
Line 0 Link Here
1
# Copyright 1999-2008 Gentoo Foundation
2
# Distributed under the terms of the GNU General Public License v2
3
# $Header: /var/cvsroot/gentoo-x86/dev-db/sqlite/sqlite-3.5.4.ebuild,v 1.4 2008/01/14 11:24:00 vapier Exp $
4
5
EAPI="1"
6
7
inherit versionator alternatives eutils flag-o-matic libtool
8
9
DESCRIPTION="an SQL Database Engine in a C Library"
10
HOMEPAGE="http://www.sqlite.org/"
11
DOC_PV=$(replace_all_version_separators _)
12
SRC_URI="http://www.sqlite.org/${P}.tar.gz
13
	doc? ( http://www.sqlite.org/${PN}_docs_${DOC_PV}.zip )"
14
15
LICENSE="as-is"
16
SLOT="3"
17
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~sparc-fbsd x86 ~x86-fbsd"
18
IUSE="debug doc soundex tcl +threadsafe fts3"
19
RESTRICT="!tcl? ( test )"
20
21
DEPEND="tcl? ( dev-lang/tcl )"
22
RDEPEND="${DEPEND}"
23
24
SOURCE="/usr/bin/lemon"
25
ALTERNATIVES="${SOURCE}-3 ${SOURCE}-0"
26
27
pkg_setup() {
28
	# test
29
	if has test ${FEATURES}; then
30
		if ! has userpriv ${FEATURES}; then
31
			ewarn "The userpriv feature must be enabled to run tests."
32
			eerror "Testsuite will not be run."
33
		fi
34
		if ! use tcl; then
35
			ewarn "You must enable the tcl use flag if you want to run the testsuite."
36
			eerror "Testsuite will not be run."
37
		fi
38
	fi
39
}
40
41
src_unpack() {
42
	unpack ${A}
43
	cd "${S}"
44
45
	epatch "${FILESDIR}"/sandbox-fix2.patch
46
47
	use fts3 && epatch "${FILESDIR}"/fts3.patch
48
49
	elibtoolize
50
	epunt_cxx
51
}
52
53
src_compile() {
54
	# not available via configure and requested in bug #143794
55
	use soundex && append-flags -DSQLITE_SOUNDEX=1
56
57
        # Dietrich's extension:
58
        use fts3 && append-flags -DSQLITE_ENABLE_FTS3=1
59
60
	econf \
61
		$(use_enable debug) \
62
		$(use_enable threadsafe) \
63
		$(use_enable threadsafe cross-thread-connections) \
64
		$(use_enable tcl) \
65
		|| die
66
	emake all || die "emake all failed"
67
}
68
69
src_test() {
70
	if use tcl ; then
71
		if has userpriv ${FEATURES} ; then
72
			if use debug ; then
73
				emake fulltest || die "some test failed"
74
			else
75
				emake test || die "some test failed"
76
			fi
77
		fi
78
	fi
79
}
80
81
src_install() {
82
	emake \
83
		DESTDIR="${D}" \
84
		TCLLIBDIR="/usr/$(get_libdir)" \
85
		install \
86
		|| die "emake install failed"
87
88
	newbin lemon lemon-${SLOT} || die
89
90
	dodoc README VERSION || die
91
	doman sqlite3.1 || die
92
93
	dohtml doc/*.html art/*.gif || die
94
95
	if use doc; then
96
		dohtml -r "${WORKDIR}"/${PN}_docs_${DOC_PV}/* || die
97
	fi
98
}

Return to bug 207701