Hello,

Find attached a patch to install the *.mo files.

I've tested grub-mkrescue.in but not grub-install.in (yet)

Using for + if + cp and not cp with wildcards to really check that the
files exists and so on (like other parts of the file).

Comments?

Thanks,

-- 
Carles Pina i Estany
        http://pinux.info
2009-11-29  Carles Pina i Estany <car...@pina.cat>

        * util/grub-install.in: Install the gettext .mo files.
        * util/grub-mkrescue.in (process_input_dir): Copy the gettext .mo
        files
=== modified file 'util/grub-install.in'
--- util/grub-install.in	2009-11-12 12:23:11 +0000
+++ util/grub-install.in	2009-11-29 11:21:46 +0000
@@ -247,6 +247,14 @@ if [ "${target_cpu}-${platform}" = "i386
     done
 fi
 
+# Copy gettext files
+mkdir -p ${grubdir}/locale/
+for file in ${grubdir}/locale/*.mo ${pkglibdir}/locale/*.mo; do
+    if test -f "$file"; then
+        cp -f "$file" ${grubdir}/locale/
+    fi
+done
+
 # Write device to a variable so we don't have to traverse /dev every time.
 grub_device=`$grub_probe --target=device ${grubdir}`
 

=== modified file 'util/grub-mkrescue.in'
--- util/grub-mkrescue.in	2009-11-21 16:40:55 +0000
+++ util/grub-mkrescue.in	2009-11-29 11:17:46 +0000
@@ -100,6 +100,13 @@ process_input_dir ()
             cp -f "$file" ${iso9660_dir}/boot/grub/${target_cpu}-${platform}/
         fi
     done
+
+    mkdir -p ${iso9660_dir}/boot/grub/locale
+    for file in ${input_dir}/po/*.mo; do
+        if test -f "$file"; then
+	    cp -f "$file" ${iso9660_dir}/boot/grub/locale/
+	fi
+    done
 }
 
 if [ "${override_dir}" = "" ] ; then

_______________________________________________
Grub-devel mailing list
Grub-devel@gnu.org
http://lists.gnu.org/mailman/listinfo/grub-devel

Reply via email to