first commit (2005-12-25)
This commit is contained in:
32
scr/TZlib/gzipdemo/ReadMe.txt
Normal file
32
scr/TZlib/gzipdemo/ReadMe.txt
Normal file
@ -0,0 +1,32 @@
|
||||
========================================================================
|
||||
CONSOLE APPLICATION : gzipdemo Project Overview
|
||||
========================================================================
|
||||
|
||||
AppWizard has created this gzipdemo application for you.
|
||||
This file contains a summary of what you will find in each of the files that
|
||||
make up your gzipdemo application.
|
||||
|
||||
|
||||
gzipdemo.vcproj
|
||||
This is the main project file for VC++ projects generated using an Application Wizard.
|
||||
It contains information about the version of Visual C++ that generated the file, and
|
||||
information about the platforms, configurations, and project features selected with the
|
||||
Application Wizard.
|
||||
|
||||
gzipdemo.cpp
|
||||
This is the main application source file.
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
Other standard files:
|
||||
|
||||
StdAfx.h, StdAfx.cpp
|
||||
These files are used to build a precompiled header (PCH) file
|
||||
named gzipdemo.pch and a precompiled types file named StdAfx.obj.
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
Other notes:
|
||||
|
||||
AppWizard uses "TODO:" comments to indicate parts of the source code you
|
||||
should add to or customize.
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
36
scr/TZlib/gzipdemo/gzipdemo.cpp
Normal file
36
scr/TZlib/gzipdemo/gzipdemo.cpp
Normal file
@ -0,0 +1,36 @@
|
||||
// gzipdemo.cpp : Defines the entry point for the console application.
|
||||
//
|
||||
|
||||
#include "stdafx.h"
|
||||
#include "../GZipHelper.h"
|
||||
int _tmain(int argc, _TCHAR* argv[])
|
||||
{
|
||||
/*
|
||||
FILE *ain=fopen("d:\\BigExample.txt","rb");
|
||||
fseek( ain,0,SEEK_END);
|
||||
long size=ftell(ain);
|
||||
fseek(ain,0,SEEK_SET);
|
||||
|
||||
char* buffer=(char*)malloc(size);
|
||||
size_t count0=fread(buffer,1,size,ain);
|
||||
CA2GZIP gzip(buffer,size);
|
||||
|
||||
FILE *aout=fopen("d:\\BigExample.gz","wb");
|
||||
size_t count1=fwrite(gzip.pgzip,1,gzip.Length,aout);
|
||||
*/
|
||||
|
||||
FILE *in=fopen("d:\\BigExample.gz","rb");
|
||||
FILE *out=fopen("c:\\BigExample.txt","wb");
|
||||
fseek( in,0,SEEK_END);
|
||||
long size=ftell(in);
|
||||
fseek(in,0,SEEK_SET);
|
||||
LPGZIP buffer=(LPGZIP)malloc(size);
|
||||
size_t count0=fread(buffer,1,size,in);
|
||||
|
||||
CGZIP2A a(buffer,count0);
|
||||
size_t count=strlen(a.psz);
|
||||
size_t count1=fwrite(a.psz,1,a.Length,out);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
BIN
scr/TZlib/gzipdemo/gzipdemo.ncb
Normal file
BIN
scr/TZlib/gzipdemo/gzipdemo.ncb
Normal file
Binary file not shown.
21
scr/TZlib/gzipdemo/gzipdemo.sln
Normal file
21
scr/TZlib/gzipdemo/gzipdemo.sln
Normal file
@ -0,0 +1,21 @@
|
||||
Microsoft Visual Studio Solution File, Format Version 7.00
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "gzipdemo", "gzipdemo.vcproj", "{B013F279-7272-47D6-B8C9-B583C2BDE1B4}"
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfiguration) = preSolution
|
||||
ConfigName.0 = Debug
|
||||
ConfigName.1 = Release
|
||||
EndGlobalSection
|
||||
GlobalSection(ProjectDependencies) = postSolution
|
||||
EndGlobalSection
|
||||
GlobalSection(ProjectConfiguration) = postSolution
|
||||
{B013F279-7272-47D6-B8C9-B583C2BDE1B4}.Debug.ActiveCfg = Debug|Win32
|
||||
{B013F279-7272-47D6-B8C9-B583C2BDE1B4}.Debug.Build.0 = Debug|Win32
|
||||
{B013F279-7272-47D6-B8C9-B583C2BDE1B4}.Release.ActiveCfg = Release|Win32
|
||||
{B013F279-7272-47D6-B8C9-B583C2BDE1B4}.Release.Build.0 = Release|Win32
|
||||
EndGlobalSection
|
||||
GlobalSection(ExtensibilityGlobals) = postSolution
|
||||
EndGlobalSection
|
||||
GlobalSection(ExtensibilityAddIns) = postSolution
|
||||
EndGlobalSection
|
||||
EndGlobal
|
||||
BIN
scr/TZlib/gzipdemo/gzipdemo.suo
Normal file
BIN
scr/TZlib/gzipdemo/gzipdemo.suo
Normal file
Binary file not shown.
226
scr/TZlib/gzipdemo/gzipdemo.vcproj
Normal file
226
scr/TZlib/gzipdemo/gzipdemo.vcproj
Normal file
@ -0,0 +1,226 @@
|
||||
<?xml version="1.0" encoding = "gb2312"?>
|
||||
<VisualStudioProject
|
||||
ProjectType="Visual C++"
|
||||
Version="7.00"
|
||||
Name="gzipdemo"
|
||||
ProjectGUID="{B013F279-7272-47D6-B8C9-B583C2BDE1B4}"
|
||||
Keyword="Win32Proj">
|
||||
<Platforms>
|
||||
<Platform
|
||||
Name="Win32"/>
|
||||
</Platforms>
|
||||
<Configurations>
|
||||
<Configuration
|
||||
Name="Debug|Win32"
|
||||
OutputDirectory="Debug"
|
||||
IntermediateDirectory="Debug"
|
||||
ConfigurationType="1"
|
||||
CharacterSet="2">
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="0"
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_CONSOLE"
|
||||
MinimalRebuild="TRUE"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="5"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="3"
|
||||
Detect64BitPortabilityProblems="TRUE"
|
||||
DebugInformationFormat="4"/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
OutputFile="$(OutDir)/gzipdemo.exe"
|
||||
LinkIncremental="2"
|
||||
GenerateDebugInformation="TRUE"
|
||||
ProgramDatabaseFile="$(OutDir)/gzipdemo.pdb"
|
||||
SubSystem="1"
|
||||
TargetMachine="1"/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"/>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"/>
|
||||
<Tool
|
||||
Name="VCWebDeploymentTool"/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release|Win32"
|
||||
OutputDirectory="Release"
|
||||
IntermediateDirectory="Release"
|
||||
ConfigurationType="1"
|
||||
CharacterSet="2">
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="2"
|
||||
InlineFunctionExpansion="1"
|
||||
OmitFramePointers="TRUE"
|
||||
PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE"
|
||||
StringPooling="TRUE"
|
||||
RuntimeLibrary="4"
|
||||
EnableFunctionLevelLinking="TRUE"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="3"
|
||||
Detect64BitPortabilityProblems="TRUE"
|
||||
DebugInformationFormat="3"/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
OutputFile="$(OutDir)/gzipdemo.exe"
|
||||
LinkIncremental="1"
|
||||
GenerateDebugInformation="TRUE"
|
||||
SubSystem="1"
|
||||
OptimizeReferences="2"
|
||||
EnableCOMDATFolding="2"
|
||||
TargetMachine="1"/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"/>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"/>
|
||||
<Tool
|
||||
Name="VCWebDeploymentTool"/>
|
||||
</Configuration>
|
||||
</Configurations>
|
||||
<Files>
|
||||
<Filter
|
||||
Name="Source Files"
|
||||
Filter="cpp;c;cxx;def;odl;idl;hpj;bat;asm">
|
||||
<File
|
||||
RelativePath="gzipdemo.cpp">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="stdafx.cpp">
|
||||
<FileConfiguration
|
||||
Name="Debug|Win32">
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
UsePrecompiledHeader="1"/>
|
||||
</FileConfiguration>
|
||||
<FileConfiguration
|
||||
Name="Release|Win32">
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
UsePrecompiledHeader="1"/>
|
||||
</FileConfiguration>
|
||||
</File>
|
||||
<Filter
|
||||
Name="zip"
|
||||
Filter="">
|
||||
<File
|
||||
RelativePath="..\Zip\adler32.c">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\Zip\compress.c">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\Zip\crc32.c">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\Zip\deflate.c">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\Zip\gzio.c">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\Zip\infblock.c">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\Zip\infcodes.c">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\Zip\inffast.c">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\Zip\inflate.c">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\Zip\inftrees.c">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\Zip\infutil.c">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\Zip\maketree.c">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\Zip\trees.c">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\Zip\uncompr.c">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\Zip\zutil.c">
|
||||
</File>
|
||||
</Filter>
|
||||
</Filter>
|
||||
<Filter
|
||||
Name="Header Files"
|
||||
Filter="h;hpp;hxx;hm;inl;inc">
|
||||
<File
|
||||
RelativePath="..\GZipHelper.h">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\Zip\deflate.h">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\Zip\infblock.h">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\Zip\infcodes.h">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\Zip\inffast.h">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\Zip\inffixed.h">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\Zip\inftrees.h">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\Zip\infutil.h">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="stdafx.h">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\Zip\trees.h">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\Zip\zconf.h">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\Zip\zlib.h">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\Zip\zutil.h">
|
||||
</File>
|
||||
</Filter>
|
||||
<Filter
|
||||
Name="Resource Files"
|
||||
Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe">
|
||||
</Filter>
|
||||
<File
|
||||
RelativePath="ReadMe.txt">
|
||||
</File>
|
||||
</Files>
|
||||
<Globals>
|
||||
</Globals>
|
||||
</VisualStudioProject>
|
||||
8
scr/TZlib/gzipdemo/stdafx.cpp
Normal file
8
scr/TZlib/gzipdemo/stdafx.cpp
Normal file
@ -0,0 +1,8 @@
|
||||
// stdafx.cpp : source file that includes just the standard includes
|
||||
// gzipdemo.pch will be the pre-compiled header
|
||||
// stdafx.obj will contain the pre-compiled type information
|
||||
|
||||
#include "stdafx.h"
|
||||
|
||||
// TODO: reference any additional headers you need in STDAFX.H
|
||||
// and not in this file
|
||||
12
scr/TZlib/gzipdemo/stdafx.h
Normal file
12
scr/TZlib/gzipdemo/stdafx.h
Normal file
@ -0,0 +1,12 @@
|
||||
// stdafx.h : include file for standard system include files,
|
||||
// or project specific include files that are used frequently, but
|
||||
// are changed infrequently
|
||||
//
|
||||
|
||||
#pragma once
|
||||
|
||||
#define WIN32_LEAN_AND_MEAN // Exclude rarely-used stuff from Windows headers
|
||||
#include <stdio.h>
|
||||
#include <tchar.h>
|
||||
|
||||
// TODO: reference additional headers your program requires here
|
||||
Reference in New Issue
Block a user