]> git.pld-linux.org Git - packages/libreoffice.git/blob - openoffice-scpzip-langs.patch
- up
[packages/libreoffice.git] / openoffice-scpzip-langs.patch
1 --- oo_1.1_src/scptools/source/linker/scpzip.cxx.jj     2001-12-05 08:12:02.000000000 -0500
2 +++ oo_1.1_src/scptools/source/linker/scpzip.cxx        2003-02-05 09:31:36.000000000 -0500
3 @@ -363,6 +363,7 @@ void ZipFile( SiFile* pFile, USHORT nLan
4         if( pFile->IsArchive() || pFile->IsPacked() )
5         {
6                 ByteString aPackedname;
7 +               BOOL makeLink;
8                 if( bOldSetupZIPStyle && pFile->IsSetupZip() )
9                         aPackedname = "f_0000";
10                 else
11 @@ -385,7 +386,33 @@ void ZipFile( SiFile* pFile, USHORT nLan
12                 if( !pFile->IsSetupZip() && aDestination.Exists() )
13                         aDestination.Kill();
14  
15 -               if( pFile->IsArchive() )
16 +               makeLink = TRUE;
17 +               if( nLang == 1 )
18 +                       makeLink = FALSE;
19 +               else
20 +               {
21 +                       const char *p, *q;
22 +
23 +                       p = pFile->GetID().GetBuffer();
24 +                       q = strchr (p, '\0');
25 +                       if (q > p + 5 && strcmp (q - 5, "_Lang") == 0)
26 +                               makeLink = FALSE;
27 +                       else
28 +                       {
29 +                               p = pFile->GetName().GetBuffer();
30 +                               q = strchr (p, '\0');
31 +                               if (q > p + 4 && strcmp (q - 4, ".res") == 0)
32 +                                       makeLink = FALSE;
33 +                       }
34 +               }
35 +               if ( makeLink )
36 +               {
37 +                       ByteString linkName = "../../01/normal/";
38 +
39 +                       linkName += aPackedname;
40 +                       symlink (linkName.GetBuffer(), aDestination.GetFull().GetBuffer());
41 +               }
42 +               else if( pFile->IsArchive() )
43                 {
44                         SiDirEntry aEntry(aSource);
45                         FileCopier aCpy( aEntry, aDestination );
This page took 0.05035 seconds and 3 git commands to generate.