From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from pigeon.gentoo.org ([208.92.234.80] helo=lists.gentoo.org) by finch.gentoo.org with esmtp (Exim 4.60) (envelope-from ) id 1REoLh-0001Gk-Rl for garchives@archives.gentoo.org; Fri, 14 Oct 2011 20:27:22 +0000 Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id CA16B21C05D; Fri, 14 Oct 2011 20:27:13 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) by pigeon.gentoo.org (Postfix) with ESMTP id 99BB321C05D for ; Fri, 14 Oct 2011 20:27:13 +0000 (UTC) Received: from flycatcher.gentoo.org (flycatcher.gentoo.org [81.93.255.6]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id C20D01B401C for ; Fri, 14 Oct 2011 20:27:12 +0000 (UTC) Received: by flycatcher.gentoo.org (Postfix, from userid 2279) id 7D14F2004B; Fri, 14 Oct 2011 20:27:11 +0000 (UTC) From: "Michal Gorny (mgorny)" To: gentoo-commits@lists.gentoo.org Reply-To: gentoo-dev@lists.gentoo.org, mgorny@gentoo.org Subject: [gentoo-commits] gentoo-x86 commit in eclass: xorg-2.eclass X-VCS-Repository: gentoo-x86 X-VCS-Files: xorg-2.eclass X-VCS-Directories: eclass X-VCS-Committer: mgorny X-VCS-Committer-Name: Michal Gorny Content-Type: text/plain; charset=utf8 Message-Id: <20111014202711.7D14F2004B@flycatcher.gentoo.org> Date: Fri, 14 Oct 2011 20:27:11 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: quoted-printable X-Archives-Salt: X-Archives-Hash: efd7fa3168186db72e9399573d467f18 mgorny 11/10/14 20:27:11 Modified: xorg-2.eclass Log: Update fonts.scale & fonts.dir on font removal. =20 This way, user won't end up with invalid fonts in the listings (and thu= s segfaulting xfontsel). =20 Fixes: https://bugs.gentoo.org/show_bug.cgi?id=3D384649 Revision Changes Path 1.50 eclass/xorg-2.eclass file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/xorg-2.ecla= ss?rev=3D1.50&view=3Dmarkup plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/xorg-2.ecla= ss?rev=3D1.50&content-type=3Dtext/plain diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/xorg-2.ecla= ss?r1=3D1.49&r2=3D1.50 Index: xorg-2.eclass =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D RCS file: /var/cvsroot/gentoo-x86/eclass/xorg-2.eclass,v retrieving revision 1.49 retrieving revision 1.50 diff -u -r1.49 -r1.50 --- xorg-2.eclass 9 Oct 2011 07:45:53 -0000 1.49 +++ xorg-2.eclass 14 Oct 2011 20:27:11 -0000 1.50 @@ -1,6 +1,6 @@ # Copyright 1999-2011 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/eclass/xorg-2.eclass,v 1.49 2011/10/0= 9 07:45:53 mgorny Exp $ +# $Header: /var/cvsroot/gentoo-x86/eclass/xorg-2.eclass,v 1.50 2011/10/1= 4 20:27:11 mgorny Exp $ =20 # @ECLASS: xorg-2.eclass # @MAINTAINER: @@ -478,7 +478,11 @@ xorg-2_pkg_postinst() { debug-print-function ${FUNCNAME} "$@" =20 - [[ -n ${FONT} ]] && setup_fonts "$@" + if [[ -n ${FONT} ]]; then + create_fonts_scale + create_fonts_dir + font_pkg_postinst "$@" + fi } =20 # @FUNCTION: xorg-2_pkg_postrm @@ -488,18 +492,14 @@ xorg-2_pkg_postrm() { debug-print-function ${FUNCNAME} "$@" =20 - [[ -n ${FONT} ]] && font_pkg_postrm "$@" -} - -# @FUNCTION: setup_fonts -# @DESCRIPTION: -# Generates needed files for fonts and fixes font permissions -setup_fonts() { - debug-print-function ${FUNCNAME} "$@" - - create_fonts_scale - create_fonts_dir - font_pkg_postinst + if [[ -n ${FONT} ]]; then + # if we're doing an upgrade, postinst will do + if [[ ${EAPI} -lt 4 || -z ${REPLACED_BY_VERSION} ]]; then + create_fonts_scale + create_fonts_dir + font_pkg_postrm "$@" + fi + fi } =20 # @FUNCTION: remove_font_metadata