aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorhashashini <lavez@gmx.de>2014-09-14 15:06:01 +0200
committerDavide Pesavento <pesa@gentoo.org>2014-09-16 00:59:05 +0200
commit58d027ad283eb3aec4c6b283a20949418785788e (patch)
treee47bec0bfc9f13bc5547f038b1025cec67e50d77 /x11-libs
parent[sets/lxqt-live] Add lxqt-qtplugin. (diff)
downloadqt-58d027ad283eb3aec4c6b283a20949418785788e.tar.gz
qt-58d027ad283eb3aec4c6b283a20949418785788e.tar.bz2
qt-58d027ad283eb3aec4c6b283a20949418785788e.zip
[qtermwidget,qterminal] Add qt5 support to live ebuilds.
Diffstat (limited to 'x11-libs')
-rw-r--r--x11-libs/qtermwidget/metadata.xml10
-rw-r--r--x11-libs/qtermwidget/qtermwidget-9999.ebuild77
2 files changed, 87 insertions, 0 deletions
diff --git a/x11-libs/qtermwidget/metadata.xml b/x11-libs/qtermwidget/metadata.xml
new file mode 100644
index 00000000..a6b07f6b
--- /dev/null
+++ b/x11-libs/qtermwidget/metadata.xml
@@ -0,0 +1,10 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <herd>qt</herd>
+ <longdescription lang="en">
+ QTermWidget is an opensource project based on KDE4 Konsole application.
+ The main goal of this project is to provide unicode-enabled, embeddable
+ Qt widget for using as a built-in console or terminal emulation widget.
+ </longdescription>
+</pkgmetadata>
diff --git a/x11-libs/qtermwidget/qtermwidget-9999.ebuild b/x11-libs/qtermwidget/qtermwidget-9999.ebuild
new file mode 100644
index 00000000..4f7517ff
--- /dev/null
+++ b/x11-libs/qtermwidget/qtermwidget-9999.ebuild
@@ -0,0 +1,77 @@
+# Copyright 1999-2014 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/x11-libs/qtermwidget/qtermwidget-9999.ebuild,v 1.2 2014/09/13 16:36:24 kensington Exp $
+
+EAPI=5
+
+PYTHON_COMPAT=( python{2_7,3_3} )
+
+inherit cmake-utils git-r3 python-r1
+
+DESCRIPTION="Qt terminal emulator widget"
+HOMEPAGE="https://github.com/qterminal/qtermwidget"
+EGIT_REPO_URI="https://github.com/qterminal/qtermwidget.git"
+
+LICENSE="GPL-2+"
+SLOT="0"
+KEYWORDS=""
+IUSE="debug python qt4 qt5"
+
+REQUIRED_USE="^^ ( qt4 qt5 )"
+
+DEPEND="
+ qt4? (
+ dev-qt/qtcore:4
+ dev-qt/qtgui:4
+ )
+ qt5? (
+ dev-qt/qtcore:5
+ dev-qt/qtgui:5
+ )"
+RDEPEND="${DEPEND}"
+
+src_prepare() {
+ cmake-utils_src_prepare
+ sed \
+ -e 's/int scheme/const QString \&name/' \
+ -i pyqt4/qtermwidget.sip || die
+}
+
+src_configure() {
+ local mycmakeargs=(
+ $(cmake-utils_use_use qt5)
+ $(cmake-utils_use_build qt4 DESIGNER_PLUGIN)
+ )
+ cmake-utils_src_configure
+
+ # cmake-utils.eclass exports BUILD_DIR only after configure phase, so sed it here
+ sed \
+ -e "/extra_lib_dirs/s@\.\.@${BUILD_DIR}@" \
+ -e '/extra_libs/s/qtermwidget/qtermwidget4/' \
+ -i pyqt4/config.py || die "sed config.py failed"
+
+ if use python; then
+ configuration() {
+ "${PYTHON}" config.py || die "${PYTHON} config.py failed"
+ }
+ BUILD_DIR="${S}/pyqt4" python_copy_sources
+ BUILD_DIR="${S}/pyqt4" python_parallel_foreach_impl run_in_build_dir configuration
+ fi
+}
+
+src_compile() {
+ cmake-utils_src_compile
+
+ if use python; then
+ BUILD_DIR="${S}/pyqt4" python_parallel_foreach_impl run_in_build_dir emake
+ fi
+}
+
+src_install() {
+ cmake-utils_src_install
+
+ if use python; then
+ BUILD_DIR="${S}/pyqt4" python_parallel_foreach_impl run_in_build_dir emake DESTDIR="${D}" install
+ BUILD_DIR="${S}/pyqt4" python_parallel_foreach_impl python_optimize
+ fi
+}