]> git.pld-linux.org Git - packages/libreoffice.git/blobdiff - openoffice-pld-package-lang.patch
- up
[packages/libreoffice.git] / openoffice-pld-package-lang.patch
index 7d682b5f86732c1443961a5b1ae959d07f56e34f..092df56e1ed2cc51ac4de8689bbba80677ade2a9 100644 (file)
@@ -1,26 +1,35 @@
 diff -urN ooo-build-1.1.54.org/bin/package-lang ooo-build-1.1.54/bin/package-lang
---- ooo-build-1.1.54.org/bin/package-lang      2004-04-30 02:50:20.270649456 +0200
-+++ ooo-build-1.1.54/bin/package-lang  2004-05-01 00:44:40.321099528 +0200
-@@ -117,6 +117,8 @@
+--- ooo-build-1.1.54.org/bin/package-lang      2004-04-30 02:50:20.000000000 +0200
++++ ooo-build-1.1.54/bin/package-lang  2004-05-03 15:29:28.605269720 +0200
+@@ -27,6 +27,7 @@
+ }
+ my $UnzipCommand = "/usr/bin/unzip";
++my $BuildDir = $setup_vars{'BUILDDIR'};
+ my $DestDir = $setup_vars{'OOINSTDIR'};
+ my $Xlate = $setup_vars{'TOOLSDIR'}. "/bin/openoffice-xlate-lang";
+ my @Langs = split (' ', `$Xlate -p all`);
+@@ -117,6 +118,9 @@
  
  sub BuildLang {
        my $lang = shift;
 +      my $lang_iso = `$Xlate -i $lang`;
-+      my $BaseDir = $setup_vars{'TOOLSDIR'};
++      chomp ($lang_iso);
++      $lang_iso =~ s/\r//;
        my $SetupDir = $setup_vars{'OOBUILDDIR'} . "/instsetoo/$Target/$lang/normal";
        my $SolverDir = $setup_vars{'OOBUILDDIR'} . "/solver/$Id/$Target";
        my $SetupConf = "$SetupDir/setup.ins";
-@@ -135,6 +137,9 @@
+@@ -135,6 +139,9 @@
        die "$UnzipCommand not found, please set the full path to the unzip command\n" if
            ( ! -x "$UnzipCommand" );
  
-+      $langl_file = $BaseDir . '/lang_' . $lang_iso . '_list.txt';
++      $langl_file = $BuildDir . '/lang_' . $lang_iso . '_list.txt';
 +      open(LANGL, ">>$langl_file");
 +              
        while (my ($key, $value) = each (%{$setup->{File}})) {
                if ($value->{PackedName}) {
                        # Find language-specific candidates
-@@ -152,6 +157,8 @@
+@@ -152,6 +159,8 @@
                                if( -f $destFile ) {
                                    unlink $destFile or die "Can't delete $destFile";
                                }
@@ -29,17 +38,24 @@ diff -urN ooo-build-1.1.54.org/bin/package-lang ooo-build-1.1.54/bin/package-lan
                                
                                # Try to link file first
                                if(link($fileToCopy,$destFile)) {
-@@ -165,6 +172,9 @@
+@@ -165,6 +174,16 @@
                            else {
                                my $fileToUnzip = $SolverDir . '/pck/' . $value->{Name};
                                if( -r $fileToUnzip ) {
 +
-+                                  # also put archive files into LANGL (TODO)
++                                  open(UNZIP, "$UnzipCommand -qq -l $fileToUnzip |");
++                                  while (<UNZIP>) {
++                                      #    907346  08-19-03 20:29   th_fr_FR.dat
++                                      if ($_ =~ m/\s+\d+\s+\d+-\d+-\d+\s+\d+:\d+\s+(\S+)/m) {
++                                          print LANGL "$outpath/$1\n";
++                                      }
++                                  }
++                                  close(UNZIP);
 +                                  
                                    $action = "Unzip";
                                    system("$UnzipCommand -qq -o $fileToUnzip -d $outpath");
                                }
-@@ -176,6 +186,7 @@
+@@ -176,12 +195,15 @@
                        }
                    }
            }
@@ -47,13 +63,11 @@ diff -urN ooo-build-1.1.54.org/bin/package-lang ooo-build-1.1.54/bin/package-lan
  
        print "done";
  
-diff -urN ooo-build-1.1.54.org/Makefile.am ooo-build-1.1.54/Makefile.am
---- ooo-build-1.1.54.org/Makefile.am   2004-04-30 02:50:22.268345760 +0200
-+++ ooo-build-1.1.54/Makefile.am       2004-05-01 00:47:50.397203568 +0200
-@@ -15,3 +15,6 @@
-       intltool-extract.in
+       return 0;
+ }
  
- ACLOCAL_AMFLAGS = -I m4
++system("rm -f $BuildDir/lang_*_list.txt");
 +
-+clean-generic:
-+      rm -f lang_*_list.txt
+ for $a (@Langs) {
+       $a eq '01' && next; # English built-in
This page took 0.042925 seconds and 4 git commands to generate.