tazpkg rev 534

tazpkg: Compile glib schemas if /usr/bin/glib-compile-schemas exists on system.
author Christopher Rogers <slaxemulator@gmail.com>
date Sun Nov 06 05:40:20 2011 +0000 (2011-11-06)
parents 32dd2d1b3545
children e4e3fa540004
files tazpkg
line diff
     1.1 --- a/tazpkg	Fri Nov 04 22:54:35 2011 +0000
     1.2 +++ b/tazpkg	Sun Nov 06 05:40:20 2011 +0000
     1.3 @@ -629,6 +629,10 @@
     1.4  	if [ "$(fgrep /usr/share/mime $ROOT$INSTALLED/$PACKAGE/files.list)" ]; then
     1.5  		updatemimedb=yes
     1.6  	fi
     1.7 +	# Compile glib schemas if needed.
     1.8 +	if [ "$(fgrep /usr/share/glib-2.0/schemas $ROOT$INSTALLED/$PACKAGE/files.list)" ]; then
     1.9 +		compile_schemas=yes
    1.10 +	fi
    1.11  	cd $TOP_DIR
    1.12  	separator
    1.13  	eval_gettext "\$PACKAGE (\$VERSION\$EXTRAVERSION) is installed."; echo
    1.14 @@ -1384,6 +1388,13 @@
    1.15  	fi
    1.16  }
    1.17  
    1.18 +compile_glib_schemas()
    1.19 +{
    1.20 +	if [ -f $1/usr/bin/glib-compile-schemas ] && [ -n "$compile_schemas" ]; then
    1.21 +		$1/usr/bin/glib-compile-schemas $1/usr/share/glib-2.0/schemas
    1.22 +	fi
    1.23 +}
    1.24 +
    1.25  translate_category()
    1.26  {
    1.27  	case $1 in