summaryrefslogtreecommitdiff
path: root/eclass
diff options
context:
space:
mode:
authorDavide Pesavento <pesa@gentoo.org>2014-11-17 01:31:41 +0000
committerDavide Pesavento <pesa@gentoo.org>2014-11-17 01:31:41 +0000
commit53c9e2859f26213ab7c4eaa47e0bdd044f453f57 (patch)
treed5ac87b13a16141104476f0997dcabdff7bff3e8 /eclass
parentVersion bump (diff)
downloadgentoo-2-53c9e2859f26213ab7c4eaa47e0bdd044f453f57.tar.gz
gentoo-2-53c9e2859f26213ab7c4eaa47e0bdd044f453f57.tar.bz2
gentoo-2-53c9e2859f26213ab7c4eaa47e0bdd044f453f57.zip
Dead code removal and other simplifications.
Diffstat (limited to 'eclass')
-rw-r--r--eclass/qt4-build.eclass66
1 files changed, 31 insertions, 35 deletions
diff --git a/eclass/qt4-build.eclass b/eclass/qt4-build.eclass
index 37a657c747e3..c6ad5aed7818 100644
--- a/eclass/qt4-build.eclass
+++ b/eclass/qt4-build.eclass
@@ -1,6 +1,6 @@
# Copyright 1999-2014 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/eclass/qt4-build.eclass,v 1.156 2014/09/22 00:03:25 pesa Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/qt4-build.eclass,v 1.157 2014/11/17 01:31:41 pesa Exp $
# @ECLASS: qt4-build.eclass
# @MAINTAINER:
@@ -14,27 +14,24 @@ case ${EAPI} in
*) die "qt4-build.eclass: unsupported EAPI=${EAPI:-0}" ;;
esac
-inherit eutils flag-o-matic multilib toolchain-funcs versionator
-
-if [[ ${PV} == *9999* ]]; then
- QT4_BUILD_TYPE="live"
- inherit git-r3
-else
- QT4_BUILD_TYPE="release"
-fi
+inherit eutils flag-o-matic multilib toolchain-funcs
HOMEPAGE="https://www.qt.io/ https://qt-project.org/"
LICENSE="|| ( LGPL-2.1 GPL-3 )"
+SLOT="4"
-case ${QT4_BUILD_TYPE} in
- live)
+case ${PV} in
+ 4.?.9999)
+ QT4_BUILD_TYPE="live"
EGIT_REPO_URI=(
"git://gitorious.org/qt/qt.git"
"https://git.gitorious.org/qt/qt.git"
)
EGIT_BRANCH=${PV%.9999}
+ inherit git-r3
;;
- release)
+ *)
+ QT4_BUILD_TYPE="release"
MY_P=qt-everywhere-opensource-src-${PV/_/-}
SRC_URI="http://download.qt-project.org/archive/qt/${PV%.*}/${PV}/${MY_P}.tar.gz"
S=${WORKDIR}/${MY_P}
@@ -42,10 +39,7 @@ case ${QT4_BUILD_TYPE} in
esac
IUSE="aqua debug pch"
-if ! version_is_at_least 4.8.5; then
- [[ ${CATEGORY}/${PN} != dev-qt/qtwebkit ]] && IUSE+=" c++0x"
-fi
-[[ ${CATEGORY}/${PN} != dev-qt/qtxmlpatterns ]] && IUSE+=" +exceptions"
+[[ ${PN} != qtxmlpatterns ]] && IUSE+=" +exceptions"
DEPEND="virtual/pkgconfig"
if [[ ${QT4_BUILD_TYPE} == live ]]; then
@@ -78,17 +72,32 @@ qt4-build_pkg_setup() {
fi
}
+# @ECLASS-VARIABLE: PATCHES
+# @DEFAULT_UNSET
+# @DESCRIPTION:
+# Array variable containing all the patches to be applied. This variable
+# is expected to be defined in the global scope of ebuilds. Make sure to
+# specify the full path. This variable is used in src_prepare phase.
+#
+# Example:
+# @CODE
+# PATCHES=(
+# "${FILESDIR}/mypatch.patch"
+# "${FILESDIR}/patches_folder/"
+# )
+# @CODE
+
# @ECLASS-VARIABLE: QT4_EXTRACT_DIRECTORIES
# @DEFAULT_UNSET
# @DESCRIPTION:
-# Space-separated list including the directories that will be extracted from
-# Qt tarball.
+# Space-separated list of directories that will be extracted
+# from Qt tarball.
# @ECLASS-VARIABLE: QT4_TARGET_DIRECTORIES
# @DEFAULT_UNSET
# @DESCRIPTION:
-# Arguments for build_target_directories. Takes the directories in which the
-# code should be compiled. This is a space-separated list.
+# Space-separated list of directories that will be configured,
+# compiled, and installed. All paths must be relative to ${S}.
# @FUNCTION: qt4-build_src_unpack
# @DESCRIPTION:
@@ -96,13 +105,13 @@ qt4-build_pkg_setup() {
qt4-build_src_unpack() {
setqtenv
- if ! version_is_at_least 4.4 $(gcc-version); then
+ if [[ $(gcc-major-version) -lt 4 ]] || [[ $(gcc-major-version) -eq 4 && $(gcc-minor-version) -lt 4 ]]; then
ewarn
ewarn "Using a GCC version lower than 4.4 is not supported."
ewarn
fi
- if [[ ${CATEGORY}/${PN} == dev-qt/qtwebkit ]]; then
+ if [[ ${PN} == qtwebkit ]]; then
eshopts_push -s extglob
if is-flagq '-g?(gdb)?([1-9])'; then
ewarn
@@ -135,19 +144,6 @@ qt4-build_src_unpack() {
esac
}
-# @ECLASS-VARIABLE: PATCHES
-# @DEFAULT_UNSET
-# @DESCRIPTION:
-# PATCHES array variable containing all various patches to be applied.
-# This variable is expected to be defined in global scope of ebuild.
-# Make sure to specify the full path. This variable is utilised in
-# src_prepare() phase.
-#
-# @CODE
-# PATCHES=( "${FILESDIR}/mypatch.patch"
-# "${FILESDIR}/patches_folder/" )
-# @CODE
-
# @FUNCTION: qt4-build_src_prepare
# @DESCRIPTION:
# Prepare the sources before the configure phase. Strip CFLAGS if necessary, and fix