From b0846152c522c859bee2fbce55721d7b79264848 Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Fri, 27 Nov 2009 18:17:22 +0200 Subject: Add XML compression example --- .../cxx/tree/compression/compression-7.1.sln | 21 + .../cxx/tree/compression/compression-7.1.vcproj | 176 +++++++++ .../cxx/tree/compression/compression-8.0.sln | 25 ++ .../cxx/tree/compression/compression-8.0.vcproj | 435 +++++++++++++++++++++ .../cxx/tree/compression/compression-9.0.sln | 25 ++ .../cxx/tree/compression/compression-9.0.vcproj | 432 ++++++++++++++++++++ .../tree/compression/compression-xerces2-7.1.sln | 21 + .../compression/compression-xerces2-7.1.vcproj | 176 +++++++++ .../tree/compression/compression-xerces2-8.0.sln | 25 ++ .../compression/compression-xerces2-8.0.vcproj | 435 +++++++++++++++++++++ .../tree/compression/compression-xerces2-9.0.sln | 25 ++ .../compression/compression-xerces2-9.0.vcproj | 432 ++++++++++++++++++++ dist/examples/cxx/tree/compression/makefile | 37 ++ dist/examples/cxx/tree/makefile | 4 + 14 files changed, 2269 insertions(+) create mode 100644 dist/examples/cxx/tree/compression/compression-7.1.sln create mode 100644 dist/examples/cxx/tree/compression/compression-7.1.vcproj create mode 100644 dist/examples/cxx/tree/compression/compression-8.0.sln create mode 100644 dist/examples/cxx/tree/compression/compression-8.0.vcproj create mode 100644 dist/examples/cxx/tree/compression/compression-9.0.sln create mode 100644 dist/examples/cxx/tree/compression/compression-9.0.vcproj create mode 100644 dist/examples/cxx/tree/compression/compression-xerces2-7.1.sln create mode 100644 dist/examples/cxx/tree/compression/compression-xerces2-7.1.vcproj create mode 100644 dist/examples/cxx/tree/compression/compression-xerces2-8.0.sln create mode 100644 dist/examples/cxx/tree/compression/compression-xerces2-8.0.vcproj create mode 100644 dist/examples/cxx/tree/compression/compression-xerces2-9.0.sln create mode 100644 dist/examples/cxx/tree/compression/compression-xerces2-9.0.vcproj create mode 100644 dist/examples/cxx/tree/compression/makefile (limited to 'dist/examples/cxx/tree') diff --git a/dist/examples/cxx/tree/compression/compression-7.1.sln b/dist/examples/cxx/tree/compression/compression-7.1.sln new file mode 100644 index 0000000..fbb90b5 --- /dev/null +++ b/dist/examples/cxx/tree/compression/compression-7.1.sln @@ -0,0 +1,21 @@ +Microsoft Visual Studio Solution File, Format Version 8.00 +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "compression", "compression-7.1.vcproj", "{AA385EB4-7352-4865-9C5C-9F0DE7BA0060}" + ProjectSection(ProjectDependencies) = postProject + EndProjectSection +EndProject +Global + GlobalSection(SolutionConfiguration) = preSolution + Debug = Debug + Release = Release + EndGlobalSection + GlobalSection(ProjectConfiguration) = postSolution + {AA385EB4-7352-4865-9C5C-9F0DE7BA0060}.Debug.ActiveCfg = Debug|Win32 + {AA385EB4-7352-4865-9C5C-9F0DE7BA0060}.Debug.Build.0 = Debug|Win32 + {AA385EB4-7352-4865-9C5C-9F0DE7BA0060}.Release.ActiveCfg = Release|Win32 + {AA385EB4-7352-4865-9C5C-9F0DE7BA0060}.Release.Build.0 = Release|Win32 + EndGlobalSection + GlobalSection(ExtensibilityGlobals) = postSolution + EndGlobalSection + GlobalSection(ExtensibilityAddIns) = postSolution + EndGlobalSection +EndGlobal diff --git a/dist/examples/cxx/tree/compression/compression-7.1.vcproj b/dist/examples/cxx/tree/compression/compression-7.1.vcproj new file mode 100644 index 0000000..fddab79 --- /dev/null +++ b/dist/examples/cxx/tree/compression/compression-7.1.vcproj @@ -0,0 +1,176 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/dist/examples/cxx/tree/compression/compression-8.0.sln b/dist/examples/cxx/tree/compression/compression-8.0.sln new file mode 100644 index 0000000..5b0f577 --- /dev/null +++ b/dist/examples/cxx/tree/compression/compression-8.0.sln @@ -0,0 +1,25 @@ +Microsoft Visual Studio Solution File, Format Version 9.00 +# Visual Studio 2005 +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "compression", "compression-8.0.vcproj", "{AA385EB4-7352-4865-9C5C-9F0DE7BA0060}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|Win32 = Debug|Win32 + Debug|x64 = Debug|x64 + Release|Win32 = Release|Win32 + Release|x64 = Release|x64 + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {AA385EB4-7352-4865-9C5C-9F0DE7BA0060}.Debug|Win32.ActiveCfg = Debug|Win32 + {AA385EB4-7352-4865-9C5C-9F0DE7BA0060}.Debug|Win32.Build.0 = Debug|Win32 + {AA385EB4-7352-4865-9C5C-9F0DE7BA0060}.Debug|x64.ActiveCfg = Debug|x64 + {AA385EB4-7352-4865-9C5C-9F0DE7BA0060}.Debug|x64.Build.0 = Debug|x64 + {AA385EB4-7352-4865-9C5C-9F0DE7BA0060}.Release|Win32.ActiveCfg = Release|Win32 + {AA385EB4-7352-4865-9C5C-9F0DE7BA0060}.Release|Win32.Build.0 = Release|Win32 + {AA385EB4-7352-4865-9C5C-9F0DE7BA0060}.Release|x64.ActiveCfg = Release|x64 + {AA385EB4-7352-4865-9C5C-9F0DE7BA0060}.Release|x64.Build.0 = Release|x64 + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection +EndGlobal diff --git a/dist/examples/cxx/tree/compression/compression-8.0.vcproj b/dist/examples/cxx/tree/compression/compression-8.0.vcproj new file mode 100644 index 0000000..85b45d8 --- /dev/null +++ b/dist/examples/cxx/tree/compression/compression-8.0.vcproj @@ -0,0 +1,435 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/dist/examples/cxx/tree/compression/compression-9.0.sln b/dist/examples/cxx/tree/compression/compression-9.0.sln new file mode 100644 index 0000000..73d32a6 --- /dev/null +++ b/dist/examples/cxx/tree/compression/compression-9.0.sln @@ -0,0 +1,25 @@ +Microsoft Visual Studio Solution File, Format Version 10.00 +# Visual Studio 2008 +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "compression", "compression-9.0.vcproj", "{AA385EB4-7352-4865-9C5C-9F0DE7BA0060}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|Win32 = Debug|Win32 + Debug|x64 = Debug|x64 + Release|Win32 = Release|Win32 + Release|x64 = Release|x64 + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {AA385EB4-7352-4865-9C5C-9F0DE7BA0060}.Debug|Win32.ActiveCfg = Debug|Win32 + {AA385EB4-7352-4865-9C5C-9F0DE7BA0060}.Debug|Win32.Build.0 = Debug|Win32 + {AA385EB4-7352-4865-9C5C-9F0DE7BA0060}.Debug|x64.ActiveCfg = Debug|x64 + {AA385EB4-7352-4865-9C5C-9F0DE7BA0060}.Debug|x64.Build.0 = Debug|x64 + {AA385EB4-7352-4865-9C5C-9F0DE7BA0060}.Release|Win32.ActiveCfg = Release|Win32 + {AA385EB4-7352-4865-9C5C-9F0DE7BA0060}.Release|Win32.Build.0 = Release|Win32 + {AA385EB4-7352-4865-9C5C-9F0DE7BA0060}.Release|x64.ActiveCfg = Release|x64 + {AA385EB4-7352-4865-9C5C-9F0DE7BA0060}.Release|x64.Build.0 = Release|x64 + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection +EndGlobal diff --git a/dist/examples/cxx/tree/compression/compression-9.0.vcproj b/dist/examples/cxx/tree/compression/compression-9.0.vcproj new file mode 100644 index 0000000..92ea1da --- /dev/null +++ b/dist/examples/cxx/tree/compression/compression-9.0.vcproj @@ -0,0 +1,432 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/dist/examples/cxx/tree/compression/compression-xerces2-7.1.sln b/dist/examples/cxx/tree/compression/compression-xerces2-7.1.sln new file mode 100644 index 0000000..b37e3eb --- /dev/null +++ b/dist/examples/cxx/tree/compression/compression-xerces2-7.1.sln @@ -0,0 +1,21 @@ +Microsoft Visual Studio Solution File, Format Version 8.00 +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "compression", "compression-xerces2-7.1.vcproj", "{AA385EB4-7352-4865-9C5C-9F0DE7BA0060}" + ProjectSection(ProjectDependencies) = postProject + EndProjectSection +EndProject +Global + GlobalSection(SolutionConfiguration) = preSolution + Debug = Debug + Release = Release + EndGlobalSection + GlobalSection(ProjectConfiguration) = postSolution + {AA385EB4-7352-4865-9C5C-9F0DE7BA0060}.Debug.ActiveCfg = Debug|Win32 + {AA385EB4-7352-4865-9C5C-9F0DE7BA0060}.Debug.Build.0 = Debug|Win32 + {AA385EB4-7352-4865-9C5C-9F0DE7BA0060}.Release.ActiveCfg = Release|Win32 + {AA385EB4-7352-4865-9C5C-9F0DE7BA0060}.Release.Build.0 = Release|Win32 + EndGlobalSection + GlobalSection(ExtensibilityGlobals) = postSolution + EndGlobalSection + GlobalSection(ExtensibilityAddIns) = postSolution + EndGlobalSection +EndGlobal diff --git a/dist/examples/cxx/tree/compression/compression-xerces2-7.1.vcproj b/dist/examples/cxx/tree/compression/compression-xerces2-7.1.vcproj new file mode 100644 index 0000000..e361b62 --- /dev/null +++ b/dist/examples/cxx/tree/compression/compression-xerces2-7.1.vcproj @@ -0,0 +1,176 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/dist/examples/cxx/tree/compression/compression-xerces2-8.0.sln b/dist/examples/cxx/tree/compression/compression-xerces2-8.0.sln new file mode 100644 index 0000000..a6ef4ed --- /dev/null +++ b/dist/examples/cxx/tree/compression/compression-xerces2-8.0.sln @@ -0,0 +1,25 @@ +Microsoft Visual Studio Solution File, Format Version 9.00 +# Visual Studio 2005 +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "compression", "compression-xerces2-8.0.vcproj", "{AA385EB4-7352-4865-9C5C-9F0DE7BA0060}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|Win32 = Debug|Win32 + Debug|x64 = Debug|x64 + Release|Win32 = Release|Win32 + Release|x64 = Release|x64 + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {AA385EB4-7352-4865-9C5C-9F0DE7BA0060}.Debug|Win32.ActiveCfg = Debug|Win32 + {AA385EB4-7352-4865-9C5C-9F0DE7BA0060}.Debug|Win32.Build.0 = Debug|Win32 + {AA385EB4-7352-4865-9C5C-9F0DE7BA0060}.Debug|x64.ActiveCfg = Debug|x64 + {AA385EB4-7352-4865-9C5C-9F0DE7BA0060}.Debug|x64.Build.0 = Debug|x64 + {AA385EB4-7352-4865-9C5C-9F0DE7BA0060}.Release|Win32.ActiveCfg = Release|Win32 + {AA385EB4-7352-4865-9C5C-9F0DE7BA0060}.Release|Win32.Build.0 = Release|Win32 + {AA385EB4-7352-4865-9C5C-9F0DE7BA0060}.Release|x64.ActiveCfg = Release|x64 + {AA385EB4-7352-4865-9C5C-9F0DE7BA0060}.Release|x64.Build.0 = Release|x64 + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection +EndGlobal diff --git a/dist/examples/cxx/tree/compression/compression-xerces2-8.0.vcproj b/dist/examples/cxx/tree/compression/compression-xerces2-8.0.vcproj new file mode 100644 index 0000000..fb651f6 --- /dev/null +++ b/dist/examples/cxx/tree/compression/compression-xerces2-8.0.vcproj @@ -0,0 +1,435 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/dist/examples/cxx/tree/compression/compression-xerces2-9.0.sln b/dist/examples/cxx/tree/compression/compression-xerces2-9.0.sln new file mode 100644 index 0000000..69eb3e3 --- /dev/null +++ b/dist/examples/cxx/tree/compression/compression-xerces2-9.0.sln @@ -0,0 +1,25 @@ +Microsoft Visual Studio Solution File, Format Version 10.00 +# Visual Studio 2008 +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "compression", "compression-xerces2-9.0.vcproj", "{AA385EB4-7352-4865-9C5C-9F0DE7BA0060}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|Win32 = Debug|Win32 + Debug|x64 = Debug|x64 + Release|Win32 = Release|Win32 + Release|x64 = Release|x64 + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {AA385EB4-7352-4865-9C5C-9F0DE7BA0060}.Debug|Win32.ActiveCfg = Debug|Win32 + {AA385EB4-7352-4865-9C5C-9F0DE7BA0060}.Debug|Win32.Build.0 = Debug|Win32 + {AA385EB4-7352-4865-9C5C-9F0DE7BA0060}.Debug|x64.ActiveCfg = Debug|x64 + {AA385EB4-7352-4865-9C5C-9F0DE7BA0060}.Debug|x64.Build.0 = Debug|x64 + {AA385EB4-7352-4865-9C5C-9F0DE7BA0060}.Release|Win32.ActiveCfg = Release|Win32 + {AA385EB4-7352-4865-9C5C-9F0DE7BA0060}.Release|Win32.Build.0 = Release|Win32 + {AA385EB4-7352-4865-9C5C-9F0DE7BA0060}.Release|x64.ActiveCfg = Release|x64 + {AA385EB4-7352-4865-9C5C-9F0DE7BA0060}.Release|x64.Build.0 = Release|x64 + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection +EndGlobal diff --git a/dist/examples/cxx/tree/compression/compression-xerces2-9.0.vcproj b/dist/examples/cxx/tree/compression/compression-xerces2-9.0.vcproj new file mode 100644 index 0000000..7c95a2a --- /dev/null +++ b/dist/examples/cxx/tree/compression/compression-xerces2-9.0.vcproj @@ -0,0 +1,432 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/dist/examples/cxx/tree/compression/makefile b/dist/examples/cxx/tree/compression/makefile new file mode 100644 index 0000000..f55c6ad --- /dev/null +++ b/dist/examples/cxx/tree/compression/makefile @@ -0,0 +1,37 @@ +root := ../../.. + +include $(root)/build/cxx/rules.make +include $(root)/build/xsd/tree-rules.make + + +override XSDFLAGS += --generate-ostream --generate-serialization + +override LIBS += -lz + +# Build. +# +driver: driver.o library.o compressed-format-target.o compressed-input-source.o + +library.o: library.cxx library.hxx +driver.o: driver.cxx library.hxx compressed-format-target.hxx \ +compressed-input-source.hxx +compressed-format-target.o: compressed-format-target.cxx +compressed-input-source.o: compressed-input-source.cxx + +library.cxx library.hxx: library.xsd + + +# Test +# +.PHONY: test +test: driver library.xml.gz + ./driver library.xml.gz + + +# Clean. +# +.PHONY: clean +clean: + rm -f library.o library.?xx driver.o compressed-format-target.o \ +compressed-input-source.o driver out.xml.gz + diff --git a/dist/examples/cxx/tree/makefile b/dist/examples/cxx/tree/makefile index 3c34244..8c23fef 100644 --- a/dist/examples/cxx/tree/makefile +++ b/dist/examples/cxx/tree/makefile @@ -1,6 +1,10 @@ dirs := binary caching embedded custom hello library messaging mixed \ multiroot performance polymorphism streaming wildcard +ifeq ($(WITH_ZLIB),1) +dirs += compression +endif + ifeq ($(WITH_DBXML),1) dirs += dbxml endif -- cgit v1.1