blob: 3f3d93fa066d7e3d10f7f5737cd777dd56c0b9e4 (
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-2012 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/dev-python/pyside-tools/pyside-tools-0.2.14.ebuild,v 1.3 2012/07/02 08:44:22 jdhore Exp $
EAPI=4
CMAKE_IN_SOURCE_BUILD="1"
PYTHON_DEPEND="2:2.6 3:3.2"
SUPPORT_PYTHON_ABIS="1"
RESTRICT_PYTHON_ABIS="2.4 2.5 3.1 *-jython 2.7-pypy-*"
PYTHON_TESTS_RESTRICTED_ABIS="3.*"
VIRTUALX_COMMAND="cmake-utils_src_test"
inherit eutils cmake-utils python virtualx
DESCRIPTION="PySide development tools (lupdate, rcc, uic)"
HOMEPAGE="http://www.pyside.org/"
SRC_URI="http://www.pyside.org/files/${P}.tar.bz2"
LICENSE="BSD GPL-2"
SLOT="0"
KEYWORDS="~amd64 x86"
IUSE="test"
RDEPEND="
>=dev-python/pyside-1.1.0-r1[X]
>=dev-python/shiboken-1.1.0-r1
>=x11-libs/qt-core-4.7.0:4
>=x11-libs/qt-gui-4.7.0:4
"
DEPEND="${RDEPEND}
test? ( virtual/pkgconfig )
"
src_prepare() {
epatch "${FILESDIR}"/0.2.13-fix-pysideuic-test-and-install.patch
python_copy_sources
preparation() {
if [[ $(python_get_version -l --major) == 3 ]]; then
rm -fr pysideuic/port_v2
else
rm -fr pysideuic/port_v3
fi
sed -i -e "/pkg-config/ s:shiboken:&-python${PYTHON_ABI}:" \
tests/rcc/run_test.sh || die
}
python_execute_function -s preparation
}
src_configure() {
configuration() {
local mycmakeargs=(
-DPYTHON_BASENAME="-python${PYTHON_ABI}"
-DPYTHON_SUFFIX="-python${PYTHON_ABI}"
-DSITE_PACKAGE="$(python_get_sitedir)"
$(cmake-utils_use_build test TESTS)
)
CMAKE_USE_DIR="${BUILDDIR}" cmake-utils_src_configure
}
python_execute_function -s configuration
}
src_compile() {
compilation() {
CMAKE_USE_DIR="${BUILDDIR}" cmake-utils_src_make
}
python_execute_function -s compilation
}
src_test() {
testing() {
CMAKE_USE_DIR="${BUILDDIR}" virtualmake
}
python_execute_function -s testing
}
src_install() {
installation() {
CMAKE_USE_DIR="${BUILDDIR}" cmake-utils_src_install DESTDIR="${T}/images/${PYTHON_ABI}"
}
python_execute_function -s installation
python_merge_intermediate_installation_images "${T}/images"
dodoc AUTHORS ChangeLog
}
pkg_postinst() {
python_mod_optimize pysideuic
}
pkg_postrm() {
python_mod_cleanup pysideuic
}
|