diff options
author | Oren Hurvitz | 2012-04-23 18:30:25 +0300 |
---|---|---|
committer | Justin Clark-Casey (justincc) | 2012-04-27 19:46:31 +0100 |
commit | 37d770f814321b461fc3380345d7ffcd1e00acc9 (patch) | |
tree | 1bd358d9e4b4b360c0cd8596ddc3b643b029d670 | |
parent | Add Stefan_Boom / stoehr to contributors (diff) | |
download | opensim-SC_OLD-37d770f814321b461fc3380345d7ffcd1e00acc9.zip opensim-SC_OLD-37d770f814321b461fc3380345d7ffcd1e00acc9.tar.gz opensim-SC_OLD-37d770f814321b461fc3380345d7ffcd1e00acc9.tar.bz2 opensim-SC_OLD-37d770f814321b461fc3380345d7ffcd1e00acc9.tar.xz |
Use DotNetZip to compress OARs and IARs.
DotNetZip provides much better compression than standard .NET.
-rw-r--r-- | OpenSim/Region/CoreModules/Avatar/Inventory/Archiver/InventoryArchiveWriteRequest.cs | 5 | ||||
-rw-r--r-- | OpenSim/Region/CoreModules/World/Archiver/ArchiveWriteRequestPreparation.cs | 5 | ||||
-rw-r--r-- | ThirdPartyLicenses/DotNetZip-bzip2.txt | 29 | ||||
-rw-r--r-- | ThirdPartyLicenses/DotNetZip-zlib.txt | 70 | ||||
-rw-r--r-- | ThirdPartyLicenses/DotNetZip.txt | 33 | ||||
-rw-r--r-- | bin/Ionic.Zip.dll | bin | 0 -> 462336 bytes | |||
-rw-r--r-- | prebuild.xml | 1 |
7 files changed, 141 insertions, 2 deletions
diff --git a/OpenSim/Region/CoreModules/Avatar/Inventory/Archiver/InventoryArchiveWriteRequest.cs b/OpenSim/Region/CoreModules/Avatar/Inventory/Archiver/InventoryArchiveWriteRequest.cs index 0ee7606..6587ead 100644 --- a/OpenSim/Region/CoreModules/Avatar/Inventory/Archiver/InventoryArchiveWriteRequest.cs +++ b/OpenSim/Region/CoreModules/Avatar/Inventory/Archiver/InventoryArchiveWriteRequest.cs | |||
@@ -39,6 +39,9 @@ using OpenSim.Framework.Serialization.External; | |||
39 | using OpenSim.Region.CoreModules.World.Archiver; | 39 | using OpenSim.Region.CoreModules.World.Archiver; |
40 | using OpenSim.Region.Framework.Scenes; | 40 | using OpenSim.Region.Framework.Scenes; |
41 | using OpenSim.Services.Interfaces; | 41 | using OpenSim.Services.Interfaces; |
42 | using Ionic.Zlib; | ||
43 | using GZipStream = Ionic.Zlib.GZipStream; | ||
44 | using CompressionMode = Ionic.Zlib.CompressionMode; | ||
42 | 45 | ||
43 | namespace OpenSim.Region.CoreModules.Avatar.Inventory.Archiver | 46 | namespace OpenSim.Region.CoreModules.Avatar.Inventory.Archiver |
44 | { | 47 | { |
@@ -99,7 +102,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Inventory.Archiver | |||
99 | scene, | 102 | scene, |
100 | userInfo, | 103 | userInfo, |
101 | invPath, | 104 | invPath, |
102 | new GZipStream(new FileStream(savePath, FileMode.Create), CompressionMode.Compress)) | 105 | new GZipStream(new FileStream(savePath, FileMode.Create), CompressionMode.Compress, CompressionLevel.BestCompression)) |
103 | { | 106 | { |
104 | } | 107 | } |
105 | 108 | ||
diff --git a/OpenSim/Region/CoreModules/World/Archiver/ArchiveWriteRequestPreparation.cs b/OpenSim/Region/CoreModules/World/Archiver/ArchiveWriteRequestPreparation.cs index ab3cc41..eabe46e 100644 --- a/OpenSim/Region/CoreModules/World/Archiver/ArchiveWriteRequestPreparation.cs +++ b/OpenSim/Region/CoreModules/World/Archiver/ArchiveWriteRequestPreparation.cs | |||
@@ -40,6 +40,9 @@ using OpenSim.Framework.Serialization; | |||
40 | using OpenSim.Region.CoreModules.World.Terrain; | 40 | using OpenSim.Region.CoreModules.World.Terrain; |
41 | using OpenSim.Region.Framework.Interfaces; | 41 | using OpenSim.Region.Framework.Interfaces; |
42 | using OpenSim.Region.Framework.Scenes; | 42 | using OpenSim.Region.Framework.Scenes; |
43 | using Ionic.Zlib; | ||
44 | using GZipStream = Ionic.Zlib.GZipStream; | ||
45 | using CompressionMode = Ionic.Zlib.CompressionMode; | ||
43 | 46 | ||
44 | namespace OpenSim.Region.CoreModules.World.Archiver | 47 | namespace OpenSim.Region.CoreModules.World.Archiver |
45 | { | 48 | { |
@@ -82,7 +85,7 @@ namespace OpenSim.Region.CoreModules.World.Archiver | |||
82 | { | 85 | { |
83 | try | 86 | try |
84 | { | 87 | { |
85 | m_saveStream = new GZipStream(new FileStream(savePath, FileMode.Create), CompressionMode.Compress); | 88 | m_saveStream = new GZipStream(new FileStream(savePath, FileMode.Create), CompressionMode.Compress, CompressionLevel.BestCompression); |
86 | } | 89 | } |
87 | catch (EntryPointNotFoundException e) | 90 | catch (EntryPointNotFoundException e) |
88 | { | 91 | { |
diff --git a/ThirdPartyLicenses/DotNetZip-bzip2.txt b/ThirdPartyLicenses/DotNetZip-bzip2.txt new file mode 100644 index 0000000..f8b4346 --- /dev/null +++ b/ThirdPartyLicenses/DotNetZip-bzip2.txt | |||
@@ -0,0 +1,29 @@ | |||
1 | |||
2 | The managed BZIP2 code included in Ionic.BZip2.dll and Ionic.Zip.dll is | ||
3 | modified code, based on the bzip2 code in the Apache commons compress | ||
4 | library. | ||
5 | |||
6 | The original BZip2 was created by Julian Seward, and is licensed under | ||
7 | the BSD license. | ||
8 | |||
9 | The following license applies to the Apache code: | ||
10 | ----------------------------------------------------------------------- | ||
11 | |||
12 | /* | ||
13 | * Licensed to the Apache Software Foundation (ASF) under one | ||
14 | * or more contributor license agreements. See the NOTICE file | ||
15 | * distributed with this work for additional information | ||
16 | * regarding copyright ownership. The ASF licenses this file | ||
17 | * to you under the Apache License, Version 2.0 (the | ||
18 | * "License"); you may not use this file except in compliance | ||
19 | * with the License. You may obtain a copy of the License at | ||
20 | * | ||
21 | * http://www.apache.org/licenses/LICENSE-2.0 | ||
22 | * | ||
23 | * Unless required by applicable law or agreed to in writing, | ||
24 | * software distributed under the License is distributed on an | ||
25 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY | ||
26 | * KIND, either express or implied. See the License for the | ||
27 | * specific language governing permissions and limitations | ||
28 | * under the License. | ||
29 | */ | ||
diff --git a/ThirdPartyLicenses/DotNetZip-zlib.txt b/ThirdPartyLicenses/DotNetZip-zlib.txt new file mode 100644 index 0000000..801e941 --- /dev/null +++ b/ThirdPartyLicenses/DotNetZip-zlib.txt | |||
@@ -0,0 +1,70 @@ | |||
1 | |||
2 | The following licenses govern use of the accompanying software, the | ||
3 | DotNetZip library ("the software"). If you use the software, you accept | ||
4 | these licenses. If you do not accept the license, do not use the software. | ||
5 | |||
6 | The managed ZLIB code included in Ionic.Zlib.dll and Ionic.Zip.dll is | ||
7 | modified code, based on jzlib. | ||
8 | |||
9 | |||
10 | |||
11 | The following notice applies to jzlib: | ||
12 | ----------------------------------------------------------------------- | ||
13 | |||
14 | Copyright (c) 2000,2001,2002,2003 ymnk, JCraft,Inc. All rights reserved. | ||
15 | |||
16 | Redistribution and use in source and binary forms, with or without | ||
17 | modification, are permitted provided that the following conditions are met: | ||
18 | |||
19 | 1. Redistributions of source code must retain the above copyright notice, | ||
20 | this list of conditions and the following disclaimer. | ||
21 | |||
22 | 2. Redistributions in binary form must reproduce the above copyright | ||
23 | notice, this list of conditions and the following disclaimer in | ||
24 | the documentation and/or other materials provided with the distribution. | ||
25 | |||
26 | 3. The names of the authors may not be used to endorse or promote products | ||
27 | derived from this software without specific prior written permission. | ||
28 | |||
29 | THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES, | ||
30 | INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND | ||
31 | FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL JCRAFT, | ||
32 | INC. OR ANY CONTRIBUTORS TO THIS SOFTWARE BE LIABLE FOR ANY DIRECT, INDIRECT, | ||
33 | INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT | ||
34 | LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, | ||
35 | OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF | ||
36 | LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING | ||
37 | NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, | ||
38 | EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | ||
39 | |||
40 | ----------------------------------------------------------------------- | ||
41 | |||
42 | jzlib is based on zlib-1.1.3. | ||
43 | |||
44 | The following notice applies to zlib: | ||
45 | |||
46 | ----------------------------------------------------------------------- | ||
47 | |||
48 | Copyright (C) 1995-2004 Jean-loup Gailly and Mark Adler | ||
49 | |||
50 | The ZLIB software is provided 'as-is', without any express or implied | ||
51 | warranty. In no event will the authors be held liable for any damages | ||
52 | arising from the use of this software. | ||
53 | |||
54 | Permission is granted to anyone to use this software for any purpose, | ||
55 | including commercial applications, and to alter it and redistribute it | ||
56 | freely, subject to the following restrictions: | ||
57 | |||
58 | 1. The origin of this software must not be misrepresented; you must not | ||
59 | claim that you wrote the original software. If you use this software | ||
60 | in a product, an acknowledgment in the product documentation would be | ||
61 | appreciated but is not required. | ||
62 | 2. Altered source versions must be plainly marked as such, and must not be | ||
63 | misrepresented as being the original software. | ||
64 | 3. This notice may not be removed or altered from any source distribution. | ||
65 | |||
66 | Jean-loup Gailly jloup@gzip.org | ||
67 | Mark Adler madler@alumni.caltech.edu | ||
68 | |||
69 | |||
70 | ----------------------------------------------------------------------- | ||
diff --git a/ThirdPartyLicenses/DotNetZip.txt b/ThirdPartyLicenses/DotNetZip.txt new file mode 100644 index 0000000..c3103fd --- /dev/null +++ b/ThirdPartyLicenses/DotNetZip.txt | |||
@@ -0,0 +1,33 @@ | |||
1 | Microsoft Public License (Ms-PL) | ||
2 | |||
3 | This license governs use of the accompanying software, the DotNetZip library ("the software"). If you use the software, you accept this license. If you do not accept the license, do not use the software. | ||
4 | |||
5 | 1. Definitions | ||
6 | |||
7 | The terms "reproduce," "reproduction," "derivative works," and "distribution" have the same meaning here as under U.S. copyright law. | ||
8 | |||
9 | A "contribution" is the original software, or any additions or changes to the software. | ||
10 | |||
11 | A "contributor" is any person that distributes its contribution under this license. | ||
12 | |||
13 | "Licensed patents" are a contributor's patent claims that read directly on its contribution. | ||
14 | |||
15 | 2. Grant of Rights | ||
16 | |||
17 | (A) Copyright Grant- Subject to the terms of this license, including the license conditions and limitations in section 3, each contributor grants you a non-exclusive, worldwide, royalty-free copyright license to reproduce its contribution, prepare derivative works of its contribution, and distribute its contribution or any derivative works that you create. | ||
18 | |||
19 | (B) Patent Grant- Subject to the terms of this license, including the license conditions and limitations in section 3, each contributor grants you a non-exclusive, worldwide, royalty-free license under its licensed patents to make, have made, use, sell, offer for sale, import, and/or otherwise dispose of its contribution in the software or derivative works of the contribution in the software. | ||
20 | |||
21 | 3. Conditions and Limitations | ||
22 | |||
23 | (A) No Trademark License- This license does not grant you rights to use any contributors' name, logo, or trademarks. | ||
24 | |||
25 | (B) If you bring a patent claim against any contributor over patents that you claim are infringed by the software, your patent license from such contributor to the software ends automatically. | ||
26 | |||
27 | (C) If you distribute any portion of the software, you must retain all copyright, patent, trademark, and attribution notices that are present in the software. | ||
28 | |||
29 | (D) If you distribute any portion of the software in source code form, you may do so only under this license by including a complete copy of this license with your distribution. If you distribute any portion of the software in compiled or object code form, you may only do so under a license that complies with this license. | ||
30 | |||
31 | (E) The software is licensed "as-is." You bear the risk of using it. The contributors give no express warranties, guarantees or conditions. You may have additional consumer rights under your local laws which this license cannot change. To the extent permitted under your local laws, the contributors exclude the implied warranties of merchantability, fitness for a particular purpose and non-infringement. | ||
32 | |||
33 | |||
diff --git a/bin/Ionic.Zip.dll b/bin/Ionic.Zip.dll new file mode 100644 index 0000000..95fa928 --- /dev/null +++ b/bin/Ionic.Zip.dll | |||
Binary files differ | |||
diff --git a/prebuild.xml b/prebuild.xml index 6a90d64..0c90ac0 100644 --- a/prebuild.xml +++ b/prebuild.xml | |||
@@ -1472,6 +1472,7 @@ | |||
1472 | <Reference name="OpenSim.Services.Connectors"/> | 1472 | <Reference name="OpenSim.Services.Connectors"/> |
1473 | <Reference name="OpenSim.Services.Base"/> | 1473 | <Reference name="OpenSim.Services.Base"/> |
1474 | <Reference name="OpenSim.Services.Interfaces"/> | 1474 | <Reference name="OpenSim.Services.Interfaces"/> |
1475 | <Reference name="Ionic.Zip"/> | ||
1475 | 1476 | ||
1476 | <Reference name="GlynnTucker.Cache" path="../../../bin/"/> | 1477 | <Reference name="GlynnTucker.Cache" path="../../../bin/"/> |
1477 | 1478 | ||