blob: c1983479e33aade404dbf2560ba1cc649a443bf2 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
|
# Copyright 1999-2010 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/x11-libs/libqxt/libqxt-0.6.0-r2.ebuild,v 1.1 2010/08/20 09:26:59 hwoarang Exp $
EAPI="3"
inherit multilib qt4-r2
DESCRIPTION="The Qt eXTension library provides cross-platform utility classes for the Qt toolkit"
HOMEPAGE="http://libqxt.org/"
SRC_URI="http://bitbucket.org/${PN}/${PN}/get/v${PV}.tar.bz2 -> ${P}.tar.bz2"
LICENSE="|| ( CPL-1.0 LGPL-2.1 )"
SLOT="0"
KEYWORDS="~amd64 ~x86"
IUSE="berkdb crypt debug doc sql web xscreensaver zeroconf"
COMMON_DEPEND="
x11-libs/libXrandr
x11-libs/qt-core:4
x11-libs/qt-gui:4
berkdb? ( >=sys-libs/db-4.6 )
crypt? (
>=dev-libs/openssl-0.9.8
x11-libs/qt-core:4[ssl]
)
sql? ( x11-libs/qt-sql:4 )
web? ( >=dev-libs/fcgi-2.4 )
zeroconf? ( net-dns/avahi[mdnsresponder-compat] )
"
DEPEND="${COMMON_DEPEND}
doc? ( x11-libs/qt-assistant )
"
RDEPEND="${COMMON_DEPEND}
xscreensaver? ( x11-libs/libXScrnSaver )
"
S=${WORKDIR}/${PN}
DOCS="AUTHORS CHANGES README"
PATCHES=(
"${FILESDIR}/${PN}-use-system-qdoc3.patch"
)
src_prepare() {
qt4-r2_src_prepare
# eqmake4 disables qmake cache, so we have to use config.pri
# to store configuration variables instead of .qmake.cache
sed -i -e '/^QMAKE_CACHE=/s:\.qmake\.cache:config.pri:' configure || die
sed -i -e '1i include(config.pri)' ${PN}.pro || die
sed -i -e '1i include(../config.pri)' src/qxtbase.pri || die
# remove insecure runpath
sed -i -e '/-Wl,-rpath/d' src/qxtlibs.pri || die
}
src_configure() {
# custom configure script
local myconf="./configure
-prefix '${EPREFIX}/usr'
-libdir '${EPREFIX}/usr/$(get_libdir)'
-docdir '${EPREFIX}/usr/share/doc/${PF}'
-qmake-bin '${EPREFIX}/usr/bin/qmake'
$(use debug && echo -debug || echo -release)
$(use berkdb || echo -no-db -nomake berkeley)
$(use crypt || echo -no-openssl)
$(use doc || echo -nomake docs)
$(use sql || echo -nomake sql)
$(use web || echo -nomake web)
$(use zeroconf || echo -no-zeroconf -nomake zeroconf)
-verbose"
echo ${myconf}
eval ${myconf} || die "./configure failed"
eqmake4 -recursive
}
src_compile() {
qt4-r2_src_compile
if use doc; then
einfo "Building documentation"
emake docs || die
fi
}
pkg_postinst() {
if use doc; then
elog
elog "In case you want to browse ${PN} documentation using"
elog "Qt Assistant, perform the following steps:"
elog " 1. Open the Assistant"
elog " 2. Edit->Preferences->Documentation->Add"
elog " 3. Add this path: ${EPREFIX}/usr/share/doc/${PF}/qxt.qch"
elog
fi
}
|