From mboxrd@z Thu Jan  1 00:00:00 1970
Return-Path: <gentoo-commits+bounces-530309-garchives=archives.gentoo.org@lists.gentoo.org>
Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80])
	by finch.gentoo.org (Postfix) with ESMTP id A21F61381F3
	for <garchives@archives.gentoo.org>; Mon,  3 Dec 2012 05:47:43 +0000 (UTC)
Received: from pigeon.gentoo.org (localhost [127.0.0.1])
	by pigeon.gentoo.org (Postfix) with SMTP id 56B3421C01C;
	Mon,  3 Dec 2012 05:47:36 +0000 (UTC)
Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183])
	(using TLSv1 with cipher AECDH-AES256-SHA (256/256 bits))
	(No client certificate requested)
	by pigeon.gentoo.org (Postfix) with ESMTPS id BEF5521C01C
	for <gentoo-commits@lists.gentoo.org>; Mon,  3 Dec 2012 05:47:35 +0000 (UTC)
Received: from hornbill.gentoo.org (hornbill.gentoo.org [94.100.119.163])
	(using TLSv1 with cipher AECDH-AES256-SHA (256/256 bits))
	(No client certificate requested)
	by smtp.gentoo.org (Postfix) with ESMTPS id A83A133D8F2
	for <gentoo-commits@lists.gentoo.org>; Mon,  3 Dec 2012 05:47:34 +0000 (UTC)
Received: from localhost.localdomain (localhost [127.0.0.1])
	by hornbill.gentoo.org (Postfix) with ESMTP id 185D6E5436
	for <gentoo-commits@lists.gentoo.org>; Mon,  3 Dec 2012 05:47:33 +0000 (UTC)
From: "Lars Wendler" <polynomial-c@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Content-Transfer-Encoding: 8bit
Content-type: text/plain; charset=UTF-8
Reply-To: gentoo-dev@lists.gentoo.org, "Lars Wendler" <polynomial-c@gentoo.org>
Message-ID: <1354513630.94670426d7177a47cfa6343fdddaae91c7c0a75f.polynomial-c@gentoo>
Subject: [gentoo-commits] proj/mozilla:master commit in: www-client/firefox/, eclass/
X-VCS-Repository: proj/mozilla
X-VCS-Files: eclass/mozconfig-3.eclass eclass/mozcoreconf-2.eclass www-client/firefox/Manifest
X-VCS-Directories: www-client/firefox/ eclass/
X-VCS-Committer: polynomial-c
X-VCS-Committer-Name: Lars Wendler
X-VCS-Revision: 94670426d7177a47cfa6343fdddaae91c7c0a75f
X-VCS-Branch: master
Date: Mon,  3 Dec 2012 05:47:33 +0000 (UTC)
Precedence: bulk
List-Post: <mailto:gentoo-commits@lists.gentoo.org>
List-Help: <mailto:gentoo-commits+help@lists.gentoo.org>
List-Unsubscribe: <mailto:gentoo-commits+unsubscribe@lists.gentoo.org>
List-Subscribe: <mailto:gentoo-commits+subscribe@lists.gentoo.org>
List-Id: Gentoo Linux mail <gentoo-commits.gentoo.org>
X-BeenThere: gentoo-commits@lists.gentoo.org
X-Archives-Salt: f9982153-7046-4a0a-8151-3b87dd5c46ec
X-Archives-Hash: 3d2bace80dd332dda19833eda7edf4cf

commit:     94670426d7177a47cfa6343fdddaae91c7c0a75f
Author:     Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
AuthorDate: Mon Dec  3 05:47:10 2012 +0000
Commit:     Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
CommitDate: Mon Dec  3 05:47:10 2012 +0000
URL:        http://git.overlays.gentoo.org/gitweb/?p=proj/mozilla.git;a=commit;h=94670426

Fixed version check.

---
 eclass/mozconfig-3.eclass   |    6 +++---
 eclass/mozcoreconf-2.eclass |   41 ++++++++++++++++++++++++++++++-----------
 www-client/firefox/Manifest |    2 +-
 3 files changed, 34 insertions(+), 15 deletions(-)

diff --git a/eclass/mozconfig-3.eclass b/eclass/mozconfig-3.eclass
index 33c5fb0..8b2ae95 100644
--- a/eclass/mozconfig-3.eclass
+++ b/eclass/mozconfig-3.eclass
@@ -41,7 +41,7 @@ mozconfig_config() {
 		fi
 	fi
 
-	if [[ ${PN} == firefox || thunderbird ]] && [[ ${PV} < 17.0 ]] || [[ ${P} < seamonkey-2.14 ]]; then
+	if ! $(mozversion_is_new_enough) ; then
 		mozconfig_use_enable alsa ogg
 		mozconfig_use_enable alsa wave
 		mozconfig_use_enable libnotify
@@ -69,7 +69,7 @@ mozconfig_config() {
 	mozconfig_use_enable system-sqlite
 	mozconfig_use_enable wifi necko-wifi
 
-	if [[ ${PN} == firefox || thunderbird ]] && [[ ${PV} >= 17.0 ]] || [[ ${P} >= seamonkey-2.14 ]]; then
+	if $(mozversion_is_new_enough) ; then
 		mozconfig_annotate 'required' --enable-ogg
 		mozconfig_annotate 'required' --enable-wave
 		mozconfig_annotate 'required' --with-system-libvpx
@@ -90,7 +90,7 @@ mozconfig_config() {
 	fi
 
 	# Disable webrtc for arches that it doesn't support, bug 444780
-	if [[ ${PN} == firefox || thunderbird ]] && [[ ${PV} >= 17.0 ]] || [[ ${P} >= seamonkey-2.14 ]]; then
+	if $(mozversion_is_new_enough) ; then
 		if use ppc || use ppc64 || arm; then
 			mozconfig_annotate '' --disable-webrtc
 		fi

diff --git a/eclass/mozcoreconf-2.eclass b/eclass/mozcoreconf-2.eclass
index e34cb17..be3f162 100644
--- a/eclass/mozcoreconf-2.eclass
+++ b/eclass/mozcoreconf-2.eclass
@@ -5,7 +5,7 @@
 # mozcoreconf.eclass : core options for mozilla
 # inherit mozconfig-2 if you need USE flags
 
-inherit multilib flag-o-matic python
+inherit multilib flag-o-matic python versionator
 
 IUSE="${IUSE} custom-cflags custom-optimization"
 
@@ -61,6 +61,23 @@ mozconfig_use_extension() {
 	mozconfig_annotate "${minus:-+}$1" --enable-extensions=${minus}${2}
 }
 
+mozversion_is_new_enough() {
+	case ${PN} in
+		firefox|thunderbird)
+			if [[ $(get_version_component_range 1) -ge 17 ]] ; then
+				return 0
+			fi
+		;;
+		seamonkey)
+			if [[ $(get_version_component_range 1) -eq 2 ]] && [[ $(get_version_component_range 2) -ge 14 ]] ; then
+				return 0
+			fi
+		;;
+	esac
+
+	return 1
+}
+
 moz_pkgsetup() {
 	# Ensure we use C locale when building
 	export LANG="C"
@@ -193,28 +210,29 @@ mozconfig_init() {
 		--with-system-jpeg \
 		--with-system-zlib \
 		--enable-pango \
-		if [[ ${PN} == firefox || thunderbird ]] && [[ ${PV} < 17.0 ]] || [[ ${P} < seamonkey-2.14 ]]; then
-			--enable-svg \
-		fi
 		--enable-system-cairo
+		if ! $(mozversion_is_new_enough) ; then
+			mozconfig annotate system-libs --enable-svg
+		fi
 
 	mozconfig_annotate disable_update_strip \
 		--disable-installer \
 		--disable-pedantic \
 		--disable-updater \
 		--disable-strip \
-		if [[ ${PN} == firefox || thunderbird ]] && [[ ${PV} < 17.0 ]] || [[ ${P} < seamonkey-2.14 ]]; then
-			--disable-strip-libs \
-		fi
 		--disable-install-strip
+		if ! $(mozversion_is_new_enough) ; then
+			mozconfig_annotate disable_update_strip --disable-strip-libs
+		fi
 
 	if [[ ${PN} != seamonkey ]]; then
 		mozconfig_annotate basic_profile \
-			if [[ ${PN} == firefox || thunderbird ]] && [[ ${PV} < 17.0 ]] || [[ ${P} < seamonkey-2.14 ]]; then
-				--enable-single-profile \
-				--disable-profilesharing \
-			fi
 			--disable-profilelocking
+			if ! $(mozversion_is_new_enough) ; then
+				mozconfig_annotate basic_profile \
+					--enable-single-profile \
+					--disable-profilesharing
+			fi
 	fi
 
 	# Here is a strange one...
@@ -261,3 +279,4 @@ mozconfig_final() {
 	sed -i '/^ac_add_options --enable-extensions/d' .mozconfig
 	echo "ac_add_options --enable-extensions=${exts// /,}" >> .mozconfig
 }
+

diff --git a/www-client/firefox/Manifest b/www-client/firefox/Manifest
index cc879f7..65bc90a 100644
--- a/www-client/firefox/Manifest
+++ b/www-client/firefox/Manifest
@@ -92,4 +92,4 @@ DIST firefox-17.0.1-zh-CN.xpi 304251 SHA256 7ffc7afd6aeb4b954f9aafa94ac5a764e8fa
 DIST firefox-17.0.1-zh-TW.xpi 305438 SHA256 cefcd27a01a573885d4fc9c85f13f9fc2ef17f35ec238a38eb32db0d79a0e3e1 SHA512 3f67a97b8c9d8d8abba221b29edd3fa314b328d2ff7134546ea4bd3076c95183a5d12779e285873a95e58ef065708da3a0b06920bd31aa9496d23e9844d81c76 WHIRLPOOL 60f376ad414a4d1c1794756371226752a0d863a0de8b925d9f4ec3b6f6c94e79b07fa99e3b90bd774192efa513fef09ad20d17d78ae38558b4a244fa7286e6f7
 DIST firefox-17.0.1-zu.xpi 296594 SHA256 6f1bd98029668b48424147f112404ac70f69abecd3888a7d010ff425943c2855 SHA512 c7a54d3d0a8a4d5e9ec1605c0b407d727a3c53925a67834e01bd2b04d6149fa2e97d2f1605df16fe219afec1483a3da1e3ee318ff3ff1a9d695281a49305ce16 WHIRLPOOL 3f32c10908a8050413cec2ff769e0c4ad27c814bd400913fbe358555031d19a8bca4cc825a51e91202a074bfb07625d6dee0adc3355d89e11ae98c2a57d154c1
 DIST firefox-17.0.1.source.tar.bz2 90785127 SHA256 bec6b29e5d29fa0550e95e48ec1c6842dc56981e342580ea04876d0f8d2a6e56 SHA512 058ebc40c950a12a9d4db2a61909bf778ea18d850e4828f2a3d592301ad96202e9eb3d435eccce64bfe91e5dfc9b9e30ff10b4aef9603e25e1e90f2f8c776d6c WHIRLPOOL d7445fee39a185e0dc4aee69a26780ec7958fa03614442adb50a110464cacee2b1e551cd20804c533158065b278712d727ce7cc0f0c3af05467c3b3f06c9ad5a
-EBUILD firefox-17.0.1.ebuild 11716 SHA256 da3047c6e0014e91ec66d6349c8d332107a56458ec2ad6709cf3840eac5dabdd SHA512 d35946bd1af47abd67fc11759eb0162090f8ac87057f694089ccea190eba4c2439df53948f1b75781fb9d9ca453b935483215db38a36fcf3bd99c37f9417d99a WHIRLPOOL f40dc395d4b52f40661b78cce9a63610146ea1e2d81c1822ec7d10ea5ce56319c3fc1fdef96747de1c0349f851692664e2b4e9813e92811d87802fec9fc3187b
+EBUILD firefox-17.0.1.ebuild 11606 SHA256 2fd99fcd50687799142eeb34d94117519fe81de595d03b128a3c0a8d7391be79 SHA512 502549aeb56057fba71c9767acaf6cc99a2c9bdb85b5ffcb5f13f27e9585ac9ed990b6cebebeaa95ad6e52af4f910a12440358c74ee5065e5fa48e91ddc2091e WHIRLPOOL d7c01616c3c0f15a7c588a43094a16c66d0e97e854f0fe98d30be311776abce938980f59b8ea38628610c2d107ef2e4d1f57960d14aba11af7614415b7c3d7dd