public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] gentoo-x86 commit in app-emulation/emul-linux-x86-gtklibs: emul-linux-x86-gtklibs-20110928.ebuild emul-linux-x86-gtklibs-20120127.ebuild ChangeLog
@ 2012-04-25  6:34 Fabio Erculiani (lxnay)
  0 siblings, 0 replies; 3+ messages in thread
From: Fabio Erculiani (lxnay) @ 2012-04-25  6:34 UTC (permalink / raw
  To: gentoo-commits

lxnay       12/04/25 06:34:19

  Modified:             emul-linux-x86-gtklibs-20110928.ebuild
                        emul-linux-x86-gtklibs-20120127.ebuild ChangeLog
  Log:
  write pango-querymodules32 outcome atomically
  
  (Portage version: 2.2.0_alpha84/cvs/Linux x86_64, RepoMan options: --force)

Revision  Changes    Path
1.6                  app-emulation/emul-linux-x86-gtklibs/emul-linux-x86-gtklibs-20110928.ebuild

file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/emul-linux-x86-gtklibs-20110928.ebuild?rev=1.6&view=markup
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/emul-linux-x86-gtklibs-20110928.ebuild?rev=1.6&content-type=text/plain
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/emul-linux-x86-gtklibs-20110928.ebuild?r1=1.5&r2=1.6

Index: emul-linux-x86-gtklibs-20110928.ebuild
===================================================================
RCS file: /var/cvsroot/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/emul-linux-x86-gtklibs-20110928.ebuild,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -r1.5 -r1.6
--- emul-linux-x86-gtklibs-20110928.ebuild	11 Dec 2011 13:31:43 -0000	1.5
+++ emul-linux-x86-gtklibs-20110928.ebuild	25 Apr 2012 06:34:19 -0000	1.6
@@ -1,6 +1,6 @@
-# Copyright 1999-2011 Gentoo Foundation
+# Copyright 1999-2012 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/emul-linux-x86-gtklibs-20110928.ebuild,v 1.5 2011/12/11 13:31:43 pacho Exp $
+# $Header: /var/cvsroot/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/emul-linux-x86-gtklibs-20110928.ebuild,v 1.6 2012/04/25 06:34:19 lxnay Exp $
 
 EAPI="4"
 
@@ -50,8 +50,23 @@
 pkg_postinst() {
 	PANGO_CONFDIR="/etc/pango/i686-pc-linux-gnu"
 	einfo "Generating pango modules listing..."
-	mkdir -p ${PANGO_CONFDIR}
-	pango-querymodules32 > ${PANGO_CONFDIR}/pango.modules || die
+
+	mkdir -p "${PANGO_CONFDIR}"
+	pango_conf="${PANGO_CONFDIR}/pango.modules"
+	tmp_pango_conf="${PANGO_CONFDIR}/._tmp_ebuild_pango.modules"
+
+	tmp_file=$(mktemp -t tmp.XXXXXXXXXXgdk_pixbuf_ebuild)
+	# be atomic!
+	pango-querymodules32 > "${tmp_file}"
+	if [ "${?}" = "0" ]; then
+		cp -p "${pango_conf}" "${tmp_pango_conf}" && \
+			cat "${tmp_file}" > "${tmp_pango_conf}" && \
+			mv "${tmp_pango_conf}" "${pango_conf}"
+	fi
+	if [ "${?}" != "0" ]; then
+		ewarn "Cannot update pango.modules, file generation failed"
+	fi
+	rm "${tmp_file}"
 
 	GTK2_CONFDIR="/etc/gtk-2.0/i686-pc-linux-gnu"
 	einfo "Generating gtk+ immodules/gdk-pixbuf loaders listing..."



1.4                  app-emulation/emul-linux-x86-gtklibs/emul-linux-x86-gtklibs-20120127.ebuild

file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/emul-linux-x86-gtklibs-20120127.ebuild?rev=1.4&view=markup
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/emul-linux-x86-gtklibs-20120127.ebuild?rev=1.4&content-type=text/plain
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/emul-linux-x86-gtklibs-20120127.ebuild?r1=1.3&r2=1.4

Index: emul-linux-x86-gtklibs-20120127.ebuild
===================================================================
RCS file: /var/cvsroot/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/emul-linux-x86-gtklibs-20120127.ebuild,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- emul-linux-x86-gtklibs-20120127.ebuild	30 Mar 2012 08:10:29 -0000	1.3
+++ emul-linux-x86-gtklibs-20120127.ebuild	25 Apr 2012 06:34:19 -0000	1.4
@@ -1,6 +1,6 @@
 # Copyright 1999-2012 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/emul-linux-x86-gtklibs-20120127.ebuild,v 1.3 2012/03/30 08:10:29 pacho Exp $
+# $Header: /var/cvsroot/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/emul-linux-x86-gtklibs-20120127.ebuild,v 1.4 2012/04/25 06:34:19 lxnay Exp $
 
 EAPI="4"
 
@@ -50,8 +50,23 @@
 pkg_postinst() {
 	PANGO_CONFDIR="/etc/pango/i686-pc-linux-gnu"
 	einfo "Generating pango modules listing..."
-	mkdir -p ${PANGO_CONFDIR}
-	pango-querymodules32 > ${PANGO_CONFDIR}/pango.modules || die
+
+	mkdir -p "${PANGO_CONFDIR}"
+	pango_conf="${PANGO_CONFDIR}/pango.modules"
+	tmp_pango_conf="${PANGO_CONFDIR}/._tmp_ebuild_pango.modules"
+
+	tmp_file=$(mktemp -t tmp.XXXXXXXXXXgdk_pixbuf_ebuild)
+	# be atomic!
+	pango-querymodules32 > "${tmp_file}"
+	if [ "${?}" = "0" ]; then
+		cp -p "${pango_conf}" "${tmp_pango_conf}" && \
+			cat "${tmp_file}" > "${tmp_pango_conf}" && \
+			mv "${tmp_pango_conf}" "${pango_conf}"
+	fi
+	if [ "${?}" != "0" ]; then
+		ewarn "Cannot update pango.modules, file generation failed"
+	fi
+	rm "${tmp_file}"
 
 	GTK2_CONFDIR="/etc/gtk-2.0/i686-pc-linux-gnu"
 	einfo "Generating gtk+ immodules/gdk-pixbuf loaders listing..."



1.97                 app-emulation/emul-linux-x86-gtklibs/ChangeLog

file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/ChangeLog?rev=1.97&view=markup
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/ChangeLog?rev=1.97&content-type=text/plain
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/ChangeLog?r1=1.96&r2=1.97

Index: ChangeLog
===================================================================
RCS file: /var/cvsroot/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/ChangeLog,v
retrieving revision 1.96
retrieving revision 1.97
diff -u -r1.96 -r1.97
--- ChangeLog	30 Mar 2012 08:10:29 -0000	1.96
+++ ChangeLog	25 Apr 2012 06:34:19 -0000	1.97
@@ -1,6 +1,11 @@
 # ChangeLog for app-emulation/emul-linux-x86-gtklibs
 # Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/ChangeLog,v 1.96 2012/03/30 08:10:29 pacho Exp $
+# $Header: /var/cvsroot/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/ChangeLog,v 1.97 2012/04/25 06:34:19 lxnay Exp $
+
+  25 Apr 2012; Fabio Erculiani <lxnay@gentoo.org>
+  emul-linux-x86-gtklibs-20110928.ebuild,
+  emul-linux-x86-gtklibs-20120127.ebuild:
+  write pango-querymodules32 outcome atomically
 
   30 Mar 2012; Pacho Ramos <pacho@gentoo.org>
   emul-linux-x86-gtklibs-20120127.ebuild:






^ permalink raw reply	[flat|nested] 3+ messages in thread

* [gentoo-commits] gentoo-x86 commit in app-emulation/emul-linux-x86-gtklibs: emul-linux-x86-gtklibs-20110928.ebuild emul-linux-x86-gtklibs-20120127.ebuild ChangeLog
@ 2012-04-25  9:35 Fabio Erculiani (lxnay)
  0 siblings, 0 replies; 3+ messages in thread
From: Fabio Erculiani (lxnay) @ 2012-04-25  9:35 UTC (permalink / raw
  To: gentoo-commits

lxnay       12/04/25 09:35:42

  Modified:             emul-linux-x86-gtklibs-20110928.ebuild
                        emul-linux-x86-gtklibs-20120127.ebuild ChangeLog
  Log:
  simplify (even more) pango-querymodules32 usage
  
  (Portage version: 2.2.0_alpha84/cvs/Linux x86_64, RepoMan options: --force)

Revision  Changes    Path
1.8                  app-emulation/emul-linux-x86-gtklibs/emul-linux-x86-gtklibs-20110928.ebuild

file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/emul-linux-x86-gtklibs-20110928.ebuild?rev=1.8&view=markup
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/emul-linux-x86-gtklibs-20110928.ebuild?rev=1.8&content-type=text/plain
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/emul-linux-x86-gtklibs-20110928.ebuild?r1=1.7&r2=1.8

Index: emul-linux-x86-gtklibs-20110928.ebuild
===================================================================
RCS file: /var/cvsroot/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/emul-linux-x86-gtklibs-20110928.ebuild,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -r1.7 -r1.8
--- emul-linux-x86-gtklibs-20110928.ebuild	25 Apr 2012 09:32:54 -0000	1.7
+++ emul-linux-x86-gtklibs-20110928.ebuild	25 Apr 2012 09:35:42 -0000	1.8
@@ -1,6 +1,6 @@
 # Copyright 1999-2012 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/emul-linux-x86-gtklibs-20110928.ebuild,v 1.7 2012/04/25 09:32:54 lxnay Exp $
+# $Header: /var/cvsroot/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/emul-linux-x86-gtklibs-20110928.ebuild,v 1.8 2012/04/25 09:35:42 lxnay Exp $
 
 EAPI="4"
 
@@ -58,9 +58,8 @@
 	# be atomic!
 	pango-querymodules32 > "${tmp_file}"
 	if [ "${?}" = "0" ]; then
-		cat "${tmp_file}" > "${pango_conf}"
-	fi
-	if [ "${?}" != "0" ]; then
+		cat "${tmp_file}" > "${pango_conf}" || die
+	else
 		ewarn "Cannot update pango.modules, file generation failed"
 	fi
 	rm "${tmp_file}"



1.6                  app-emulation/emul-linux-x86-gtklibs/emul-linux-x86-gtklibs-20120127.ebuild

file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/emul-linux-x86-gtklibs-20120127.ebuild?rev=1.6&view=markup
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/emul-linux-x86-gtklibs-20120127.ebuild?rev=1.6&content-type=text/plain
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/emul-linux-x86-gtklibs-20120127.ebuild?r1=1.5&r2=1.6

Index: emul-linux-x86-gtklibs-20120127.ebuild
===================================================================
RCS file: /var/cvsroot/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/emul-linux-x86-gtklibs-20120127.ebuild,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -r1.5 -r1.6
--- emul-linux-x86-gtklibs-20120127.ebuild	25 Apr 2012 09:32:54 -0000	1.5
+++ emul-linux-x86-gtklibs-20120127.ebuild	25 Apr 2012 09:35:42 -0000	1.6
@@ -1,6 +1,6 @@
 # Copyright 1999-2012 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/emul-linux-x86-gtklibs-20120127.ebuild,v 1.5 2012/04/25 09:32:54 lxnay Exp $
+# $Header: /var/cvsroot/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/emul-linux-x86-gtklibs-20120127.ebuild,v 1.6 2012/04/25 09:35:42 lxnay Exp $
 
 EAPI="4"
 
@@ -58,9 +58,8 @@
 	# be atomic!
 	pango-querymodules32 > "${tmp_file}"
 	if [ "${?}" = "0" ]; then
-		cat "${tmp_file}" > "${pango_conf}"
-	fi
-	if [ "${?}" != "0" ]; then
+		cat "${tmp_file}" > "${pango_conf}" || die
+	else
 		ewarn "Cannot update pango.modules, file generation failed"
 	fi
 	rm "${tmp_file}"



1.99                 app-emulation/emul-linux-x86-gtklibs/ChangeLog

file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/ChangeLog?rev=1.99&view=markup
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/ChangeLog?rev=1.99&content-type=text/plain
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/ChangeLog?r1=1.98&r2=1.99

Index: ChangeLog
===================================================================
RCS file: /var/cvsroot/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/ChangeLog,v
retrieving revision 1.98
retrieving revision 1.99
diff -u -r1.98 -r1.99
--- ChangeLog	25 Apr 2012 09:32:54 -0000	1.98
+++ ChangeLog	25 Apr 2012 09:35:42 -0000	1.99
@@ -1,6 +1,11 @@
 # ChangeLog for app-emulation/emul-linux-x86-gtklibs
 # Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/ChangeLog,v 1.98 2012/04/25 09:32:54 lxnay Exp $
+# $Header: /var/cvsroot/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/ChangeLog,v 1.99 2012/04/25 09:35:42 lxnay Exp $
+
+  25 Apr 2012; Fabio Erculiani <lxnay@gentoo.org>
+  emul-linux-x86-gtklibs-20110928.ebuild,
+  emul-linux-x86-gtklibs-20120127.ebuild:
+  simplify (even more) pango-querymodules32 usage
 
   25 Apr 2012; Fabio Erculiani <lxnay@gentoo.org>
   emul-linux-x86-gtklibs-20110928.ebuild,






^ permalink raw reply	[flat|nested] 3+ messages in thread

* [gentoo-commits] gentoo-x86 commit in app-emulation/emul-linux-x86-gtklibs: emul-linux-x86-gtklibs-20110928.ebuild emul-linux-x86-gtklibs-20120127.ebuild ChangeLog
@ 2012-04-25 10:02 Fabio Erculiani (lxnay)
  0 siblings, 0 replies; 3+ messages in thread
From: Fabio Erculiani (lxnay) @ 2012-04-25 10:02 UTC (permalink / raw
  To: gentoo-commits

lxnay       12/04/25 10:02:24

  Modified:             emul-linux-x86-gtklibs-20110928.ebuild
                        emul-linux-x86-gtklibs-20120127.ebuild ChangeLog
  Log:
  fix gtk/pango/gdk-pixbuf query tools usage, be atomic, be POSIX
  
  (Portage version: 2.2.0_alpha84/cvs/Linux x86_64, RepoMan options: --force)

Revision  Changes    Path
1.10                 app-emulation/emul-linux-x86-gtklibs/emul-linux-x86-gtklibs-20110928.ebuild

file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/emul-linux-x86-gtklibs-20110928.ebuild?rev=1.10&view=markup
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/emul-linux-x86-gtklibs-20110928.ebuild?rev=1.10&content-type=text/plain
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/emul-linux-x86-gtklibs-20110928.ebuild?r1=1.9&r2=1.10

Index: emul-linux-x86-gtklibs-20110928.ebuild
===================================================================
RCS file: /var/cvsroot/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/emul-linux-x86-gtklibs-20110928.ebuild,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -r1.9 -r1.10
--- emul-linux-x86-gtklibs-20110928.ebuild	25 Apr 2012 09:38:01 -0000	1.9
+++ emul-linux-x86-gtklibs-20110928.ebuild	25 Apr 2012 10:02:24 -0000	1.10
@@ -1,6 +1,6 @@
 # Copyright 1999-2012 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/emul-linux-x86-gtklibs-20110928.ebuild,v 1.9 2012/04/25 09:38:01 lxnay Exp $
+# $Header: /var/cvsroot/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/emul-linux-x86-gtklibs-20110928.ebuild,v 1.10 2012/04/25 10:02:24 lxnay Exp $
 
 EAPI="4"
 
@@ -19,8 +19,8 @@
 	# causes segfault if set
 	unset __GL_NO_DSO_FINALIZER
 
-	tmp_file=$(mktemp --suffix=gdk_pixbuf_ebuild)
-	# be atomic!
+	local tmp_file=$(mktemp -t tmp.XXXXXXXXXXgdk_pixbuf_query_loaders)
+
 	if gdk-pixbuf-query-loaders32 > "${tmp_file}"; then
 		cat "${tmp_file}" > "${ROOT}usr/lib32/gdk-pixbuf-2.0/2.10.0/loaders.cache"
 	else
@@ -29,6 +29,38 @@
 	rm "${tmp_file}"
 }
 
+my_pango_querymodules() {
+	PANGO_CONFDIR="/etc/pango/i686-pc-linux-gnu"
+	einfo "Generating pango modules listing..."
+
+	mkdir -p "${PANGO_CONFDIR}"
+	local pango_conf="${PANGO_CONFDIR}/pango.modules"
+	local tmp_file=$(mktemp -t tmp.XXXXXXXXXXpango_querymodules)
+
+	if pango-querymodules32 > "${tmp_file}"; then
+		cat "${tmp_file}" > "${pango_conf}"
+	else
+		ewarn "Cannot update pango.modules, file generation failed"
+	fi
+	rm "${tmp_file}"
+}
+
+my_gtk_query_immodules() {
+	GTK2_CONFDIR="/etc/gtk-2.0/i686-pc-linux-gnu"
+	einfo "Generating gtk+ immodules/gdk-pixbuf loaders listing..."
+
+	mkdir -p "${GTK2_CONFDIR}"
+	local gtk_conf="${ROOT}${GTK2_CONFDIR}/gtk.immodules"
+	local tmp_file=$(mktemp -t tmp.XXXXXXXXXXgtk_query_immodules)
+
+	if gtk-query-immodules-2.0-32 > "${tmp_file}"; then
+		cat "${tmp_file}" > "${gtk_conf}"
+	else
+		ewarn "Cannot update gtk.immodules, file generation failed"
+	fi
+	rm "${tmp_file}"
+}
+
 src_prepare() {
 	query_tools="${S}/usr/bin/gtk-query-immodules-2.0|${S}/usr/bin/gdk-pixbuf-query-loaders|${S}/usr/bin/pango-querymodules"
 	ALLOWED="(${S}/etc/env.d|${S}/etc/gtk-2.0|${S}/etc/pango/i686-pc-linux-gnu|${query_tools})"
@@ -48,30 +80,12 @@
 }
 
 pkg_postinst() {
-	PANGO_CONFDIR="/etc/pango/i686-pc-linux-gnu"
-	einfo "Generating pango modules listing..."
-
-	mkdir -p "${PANGO_CONFDIR}"
-	local pango_conf="${PANGO_CONFDIR}/pango.modules"
-	local tmp_file=$(mktemp -t tmp.XXXXXXXXXXgdk_pixbuf_ebuild)
-
-	# be atomic!
-	pango-querymodules32 > "${tmp_file}"
-	if [ "${?}" = "0" ]; then
-		cat "${tmp_file}" > "${pango_conf}" || die
-	else
-		ewarn "Cannot update pango.modules, file generation failed"
-	fi
-	rm "${tmp_file}"
-
-	GTK2_CONFDIR="/etc/gtk-2.0/i686-pc-linux-gnu"
-	einfo "Generating gtk+ immodules/gdk-pixbuf loaders listing..."
-	mkdir -p ${GTK2_CONFDIR}
-	gtk-query-immodules-2.0-32 > "${ROOT}${GTK2_CONFDIR}/gtk.immodules"
+	my_pango_querymodules
+	my_gtk_query_immodules
 	my_gdk_pixbuf_query_loaders
 
 	# gdk-pixbuf.loaders should be in their CHOST directories respectively.
-	if [[ -e ${ROOT}/etc/gtk-2.0/gdk-pixbuf.loaders ]] ; then
+	if [[ -e "${ROOT}/etc/gtk-2.0/gdk-pixbuf.loaders" ]] ; then
 		ewarn
 		ewarn "File /etc/gtk-2.0/gdk-pixbuf.loaders shouldn't be present on"
 		ewarn "multilib systems, please remove it by hand."



1.8                  app-emulation/emul-linux-x86-gtklibs/emul-linux-x86-gtklibs-20120127.ebuild

file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/emul-linux-x86-gtklibs-20120127.ebuild?rev=1.8&view=markup
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/emul-linux-x86-gtklibs-20120127.ebuild?rev=1.8&content-type=text/plain
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/emul-linux-x86-gtklibs-20120127.ebuild?r1=1.7&r2=1.8

Index: emul-linux-x86-gtklibs-20120127.ebuild
===================================================================
RCS file: /var/cvsroot/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/emul-linux-x86-gtklibs-20120127.ebuild,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -r1.7 -r1.8
--- emul-linux-x86-gtklibs-20120127.ebuild	25 Apr 2012 09:38:01 -0000	1.7
+++ emul-linux-x86-gtklibs-20120127.ebuild	25 Apr 2012 10:02:24 -0000	1.8
@@ -1,6 +1,6 @@
 # Copyright 1999-2012 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/emul-linux-x86-gtklibs-20120127.ebuild,v 1.7 2012/04/25 09:38:01 lxnay Exp $
+# $Header: /var/cvsroot/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/emul-linux-x86-gtklibs-20120127.ebuild,v 1.8 2012/04/25 10:02:24 lxnay Exp $
 
 EAPI="4"
 
@@ -19,8 +19,8 @@
 	# causes segfault if set
 	unset __GL_NO_DSO_FINALIZER
 
-	tmp_file=$(mktemp --suffix=gdk_pixbuf_ebuild)
-	# be atomic!
+	local tmp_file=$(mktemp --suffix=tmp.XXXXXXXXXXgdk_pixbuf_queryloaders)
+
 	if gdk-pixbuf-query-loaders32 > "${tmp_file}"; then
 		cat "${tmp_file}" > "${ROOT}usr/lib32/gdk-pixbuf-2.0/2.10.0/loaders.cache"
 	else
@@ -29,6 +29,38 @@
 	rm "${tmp_file}"
 }
 
+my_pango_querymodules() {
+	PANGO_CONFDIR="/etc/pango/i686-pc-linux-gnu"
+	einfo "Generating pango modules listing..."
+
+	mkdir -p "${PANGO_CONFDIR}"
+	local pango_conf="${PANGO_CONFDIR}/pango.modules"
+	local tmp_file=$(mktemp -t tmp.XXXXXXXXXXpango_querymodules)
+
+	if pango-querymodules32 > "${tmp_file}"; then
+		cat "${tmp_file}" > "${pango_conf}"
+	else
+		ewarn "Cannot update pango.modules, file generation failed"
+	fi
+	rm "${tmp_file}"
+}
+
+my_gtk_query_immodules() {
+	GTK2_CONFDIR="/etc/gtk-2.0/i686-pc-linux-gnu"
+	einfo "Generating gtk+ immodules/gdk-pixbuf loaders listing..."
+
+	mkdir -p "${GTK2_CONFDIR}"
+	local gtk_conf="${ROOT}${GTK2_CONFDIR}/gtk.immodules"
+	local tmp_file=$(mktemp -t tmp.XXXXXXXXXXgtk_query_immodules)
+
+	if gtk-query-immodules-2.0-32 > "${tmp_file}"; then
+		cat "${tmp_file}" > "${gtk_conf}"
+	else
+		ewarn "Cannot update gtk.immodules, file generation failed"
+	fi
+	rm "${tmp_file}"
+}
+
 src_prepare() {
 	query_tools="${S}/usr/bin/gtk-query-immodules-2.0|${S}/usr/bin/gdk-pixbuf-query-loaders|${S}/usr/bin/pango-querymodules"
 	ALLOWED="(${S}/etc/env.d|${S}/etc/gtk-2.0|${S}/etc/pango/i686-pc-linux-gnu|${query_tools})"
@@ -48,30 +80,12 @@
 }
 
 pkg_postinst() {
-	PANGO_CONFDIR="/etc/pango/i686-pc-linux-gnu"
-	einfo "Generating pango modules listing..."
-
-	mkdir -p "${PANGO_CONFDIR}"
-	local pango_conf="${PANGO_CONFDIR}/pango.modules"
-	local tmp_file=$(mktemp -t tmp.XXXXXXXXXXgdk_pixbuf_ebuild)
-
-	# be atomic!
-	pango-querymodules32 > "${tmp_file}"
-	if [ "${?}" = "0" ]; then
-		cat "${tmp_file}" > "${pango_conf}" || die
-	else
-		ewarn "Cannot update pango.modules, file generation failed"
-	fi
-	rm "${tmp_file}"
-
-	GTK2_CONFDIR="/etc/gtk-2.0/i686-pc-linux-gnu"
-	einfo "Generating gtk+ immodules/gdk-pixbuf loaders listing..."
-	mkdir -p ${GTK2_CONFDIR}
-	gtk-query-immodules-2.0-32 > "${ROOT}${GTK2_CONFDIR}/gtk.immodules"
+	my_pango_querymodules
+	my_gtk_query_immodules
 	my_gdk_pixbuf_query_loaders
 
 	# gdk-pixbuf.loaders should be in their CHOST directories respectively.
-	if [[ -e ${ROOT}/etc/gtk-2.0/gdk-pixbuf.loaders ]] ; then
+	if [[ -e "${ROOT}/etc/gtk-2.0/gdk-pixbuf.loaders" ]] ; then
 		ewarn
 		ewarn "File /etc/gtk-2.0/gdk-pixbuf.loaders shouldn't be present on"
 		ewarn "multilib systems, please remove it by hand."



1.101                app-emulation/emul-linux-x86-gtklibs/ChangeLog

file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/ChangeLog?rev=1.101&view=markup
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/ChangeLog?rev=1.101&content-type=text/plain
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/ChangeLog?r1=1.100&r2=1.101

Index: ChangeLog
===================================================================
RCS file: /var/cvsroot/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/ChangeLog,v
retrieving revision 1.100
retrieving revision 1.101
diff -u -r1.100 -r1.101
--- ChangeLog	25 Apr 2012 09:38:01 -0000	1.100
+++ ChangeLog	25 Apr 2012 10:02:24 -0000	1.101
@@ -1,6 +1,11 @@
 # ChangeLog for app-emulation/emul-linux-x86-gtklibs
 # Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/ChangeLog,v 1.100 2012/04/25 09:38:01 lxnay Exp $
+# $Header: /var/cvsroot/gentoo-x86/app-emulation/emul-linux-x86-gtklibs/ChangeLog,v 1.101 2012/04/25 10:02:24 lxnay Exp $
+
+  25 Apr 2012; Fabio Erculiani <lxnay@gentoo.org>
+  emul-linux-x86-gtklibs-20110928.ebuild,
+  emul-linux-x86-gtklibs-20120127.ebuild:
+  fix gtk/pango/gdk-pixbuf query tools usage, be atomic, be POSIX
 
   25 Apr 2012; Fabio Erculiani <lxnay@gentoo.org>
   emul-linux-x86-gtklibs-20110928.ebuild,






^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2012-04-25 10:02 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-04-25 10:02 [gentoo-commits] gentoo-x86 commit in app-emulation/emul-linux-x86-gtklibs: emul-linux-x86-gtklibs-20110928.ebuild emul-linux-x86-gtklibs-20120127.ebuild ChangeLog Fabio Erculiani (lxnay)
  -- strict thread matches above, loose matches on Subject: below --
2012-04-25  9:35 Fabio Erculiani (lxnay)
2012-04-25  6:34 Fabio Erculiani (lxnay)

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox