mirror of
https://github.com/pocoproject/poco.git
synced 2025-05-03 07:52:29 +02:00
Poco 1.9.0: Additional fixes for PDF and Encodings (#2169)
* Update gradle for the Encodings module Signed-off-by: Francis ANDRE <francis.andre.kampbell@orange.fr> * Add new PDF c++ files to VS projects * Update gradle build
This commit is contained in:
parent
488d8e05c2
commit
d993fb09b7
46
Encodings/build.gradle
Normal file
46
Encodings/build.gradle
Normal file
@ -0,0 +1,46 @@
|
|||||||
|
model {
|
||||||
|
components {
|
||||||
|
Encodings(NativeLibrarySpec) {
|
||||||
|
sources {
|
||||||
|
rc {
|
||||||
|
source {
|
||||||
|
srcDir '..'
|
||||||
|
include 'DLLVersion.rc'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
c {
|
||||||
|
source {
|
||||||
|
srcDir 'src'
|
||||||
|
include '**/*.c'
|
||||||
|
}
|
||||||
|
exportedHeaders {
|
||||||
|
srcDir 'include'
|
||||||
|
}
|
||||||
|
lib project: ':Foundation', library: 'Foundation'
|
||||||
|
}
|
||||||
|
cpp {
|
||||||
|
source {
|
||||||
|
srcDir 'src'
|
||||||
|
include '**/*.cpp'
|
||||||
|
}
|
||||||
|
exportedHeaders {
|
||||||
|
srcDir 'include'
|
||||||
|
}
|
||||||
|
lib project: ':Foundation', library: 'Foundation'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
binaries {
|
||||||
|
withType(SharedLibraryBinarySpec) {
|
||||||
|
if (toolChain in VisualCpp) {
|
||||||
|
cCompiler.define "Encodings_EXPORTS"
|
||||||
|
cppCompiler.define "Encodings_EXPORTS"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
withType(StaticLibraryBinarySpec) {
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
task poco { dependsOn "assemble" }
|
||||||
|
|
30
Encodings/samples/build.gradle
Normal file
30
Encodings/samples/build.gradle
Normal file
@ -0,0 +1,30 @@
|
|||||||
|
model {
|
||||||
|
components {
|
||||||
|
TextConverter(NativeExecutableSpec) {
|
||||||
|
sources {
|
||||||
|
cpp.source { srcDir 'TextConverter/src' include '**/*.cpp' }
|
||||||
|
cpp.lib project: ':Encodings', library: 'Encodings'
|
||||||
|
cpp.lib project: ':Foundation', library: 'Foundation'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
binaries {
|
||||||
|
all {
|
||||||
|
}
|
||||||
|
withType(SharedLibraryBinarySpec) {
|
||||||
|
lib project: ':Encodings', library: 'Encodings', linkage: 'shared'
|
||||||
|
lib project: ':Foundation', library: 'Foundation', linkage: 'shared'
|
||||||
|
}
|
||||||
|
withType(StaticLibraryBinarySpec) {
|
||||||
|
lib project: ':Encodings', library: 'Encodings', linkage: 'static'
|
||||||
|
lib project: ':Foundation', library: 'Foundation', linkage: 'static'
|
||||||
|
}
|
||||||
|
withType(NativeExecutableSpec) {
|
||||||
|
lib project: ':Encodings', library: 'Encodings', linkage: 'static'
|
||||||
|
lib project: ':Foundation', library: 'Foundation', linkage: 'static'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
task samples { dependsOn "assemble" }
|
||||||
|
|
||||||
|
|
81
Encodings/testsuite/build.gradle
Normal file
81
Encodings/testsuite/build.gradle
Normal file
@ -0,0 +1,81 @@
|
|||||||
|
import org.gradle.nativeplatform.test.cppunit.CppUnitTestSuiteSpec
|
||||||
|
|
||||||
|
model {
|
||||||
|
components {
|
||||||
|
withType(NativeComponentSpec) {
|
||||||
|
binaries.withType(NativeBinarySpec) {
|
||||||
|
if (buildType == buildTypes.debug) {
|
||||||
|
if (it instanceof NativeExecutableBinarySpec) {
|
||||||
|
executable.file = toLocalBin(appendDebugSuffix(executable.file), targetPlatform)
|
||||||
|
}
|
||||||
|
} else
|
||||||
|
if (buildType == buildTypes.release) {
|
||||||
|
if (it instanceof NativeExecutableBinarySpec) {
|
||||||
|
executable.file = toLocalBin(executable.file, targetPlatform)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
TestSuite(NativeLibrarySpec) { m ->
|
||||||
|
sources {
|
||||||
|
cpp {
|
||||||
|
source {
|
||||||
|
srcDir 'src'
|
||||||
|
include '**/*.cpp'
|
||||||
|
exclude 'Win*.cpp'
|
||||||
|
exclude 'Driver.cpp'
|
||||||
|
}
|
||||||
|
exportedHeaders {
|
||||||
|
srcDir 'src'
|
||||||
|
}
|
||||||
|
lib project: ':CppUnit', library: 'CppUnit', linkage: 'shared'
|
||||||
|
lib project: ':Encodings', library: 'Encodings', linkage: 'shared'
|
||||||
|
lib project: ':Foundation', library: 'Foundation', linkage: 'shared'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
binaries.all {
|
||||||
|
if (targetPlatform.operatingSystem.windows) {
|
||||||
|
sources {
|
||||||
|
platformWindows(CppSourceSet) {
|
||||||
|
lib m.sources.cpp
|
||||||
|
source {
|
||||||
|
srcDir 'src'
|
||||||
|
include 'Win*.cpp'
|
||||||
|
exclude '*Driver.cpp'
|
||||||
|
}
|
||||||
|
exportedHeaders {
|
||||||
|
srcDir 'src'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
testSuites {
|
||||||
|
UtilTestSuite(org.gradle.nativeplatform.test.cppunit.CppUnitTestSuiteSpec) {
|
||||||
|
testing $.components.TestSuite
|
||||||
|
}
|
||||||
|
}
|
||||||
|
binaries {
|
||||||
|
withType(org.gradle.nativeplatform.test.cppunit.CppUnitTestSuiteBinarySpec) {
|
||||||
|
lib project: ':CppUnit', library: 'CppUnit', linkage: 'shared'
|
||||||
|
if (toolChain in VisualCpp) {
|
||||||
|
if (buildType == buildTypes.debug) {
|
||||||
|
cCompiler.args "/MDd"
|
||||||
|
cppCompiler.args "/MDd"
|
||||||
|
} else
|
||||||
|
if (buildType == buildTypes.release) {
|
||||||
|
cCompiler.args "/MD"
|
||||||
|
cppCompiler.args "/MD"
|
||||||
|
} else {
|
||||||
|
throw new GradleException("Unknown buildType" + buildType)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (toolChain in Gcc) {
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
task testsuite { dependsOn "assemble" }
|
||||||
|
|
@ -1,4 +1,4 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project DefaultTargets="Build" ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project DefaultTargets="Build" ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<ItemGroup Label="ProjectConfigurations">
|
<ItemGroup Label="ProjectConfigurations">
|
||||||
<ProjectConfiguration Include="debug_shared|Win32">
|
<ProjectConfiguration Include="debug_shared|Win32">
|
||||||
@ -277,6 +277,8 @@
|
|||||||
</ItemDefinitionGroup>
|
</ItemDefinitionGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ClCompile Include="src\adler32.c" />
|
<ClCompile Include="src\adler32.c" />
|
||||||
|
<ClCompile Include="src\AttributedString.cpp" />
|
||||||
|
<ClCompile Include="src\Cell.cpp" />
|
||||||
<ClCompile Include="src\compress.c" />
|
<ClCompile Include="src\compress.c" />
|
||||||
<ClCompile Include="src\crc32.c" />
|
<ClCompile Include="src\crc32.c" />
|
||||||
<ClCompile Include="src\deflate.c" />
|
<ClCompile Include="src\deflate.c" />
|
||||||
@ -369,8 +371,10 @@
|
|||||||
<ClCompile Include="src\pngwrite.c" />
|
<ClCompile Include="src\pngwrite.c" />
|
||||||
<ClCompile Include="src\pngwtran.c" />
|
<ClCompile Include="src\pngwtran.c" />
|
||||||
<ClCompile Include="src\pngwutil.c" />
|
<ClCompile Include="src\pngwutil.c" />
|
||||||
|
<ClCompile Include="src\Table.cpp" />
|
||||||
<ClCompile Include="src\TextAnnotation.cpp" />
|
<ClCompile Include="src\TextAnnotation.cpp" />
|
||||||
<ClCompile Include="src\trees.c" />
|
<ClCompile Include="src\trees.c" />
|
||||||
|
<ClCompile Include="src\XMLTemplate.cpp" />
|
||||||
<ClCompile Include="src\zutil.c" />
|
<ClCompile Include="src\zutil.c" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Filter Include="Source Files">
|
<Filter Include="Source Files">
|
||||||
@ -327,6 +327,12 @@
|
|||||||
<ClCompile Include="src\hpdf_xref.c">
|
<ClCompile Include="src\hpdf_xref.c">
|
||||||
<Filter>3rd Party\HARU\Source Files</Filter>
|
<Filter>3rd Party\HARU\Source Files</Filter>
|
||||||
</ClCompile>
|
</ClCompile>
|
||||||
|
<ClCompile Include="src\XMLTemplate.cpp">
|
||||||
|
<Filter>Source Files</Filter>
|
||||||
|
</ClCompile>
|
||||||
|
<ClCompile Include="src\AttributedString.cpp" />
|
||||||
|
<ClCompile Include="src\Cell.cpp" />
|
||||||
|
<ClCompile Include="src\Table.cpp" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ClInclude Include="include\Poco\PDF\Destination.h">
|
<ClInclude Include="include\Poco\PDF\Destination.h">
|
||||||
|
@ -390,6 +390,10 @@
|
|||||||
<Files>
|
<Files>
|
||||||
<Filter
|
<Filter
|
||||||
Name="Source Files">
|
Name="Source Files">
|
||||||
|
<File
|
||||||
|
RelativePath=".\src\AttributedString.cpp"/>
|
||||||
|
<File
|
||||||
|
RelativePath=".\src\Cell.cpp"/>
|
||||||
<File
|
<File
|
||||||
RelativePath=".\src\Destination.cpp"/>
|
RelativePath=".\src\Destination.cpp"/>
|
||||||
<File
|
<File
|
||||||
@ -408,8 +412,12 @@
|
|||||||
RelativePath=".\src\Page.cpp"/>
|
RelativePath=".\src\Page.cpp"/>
|
||||||
<File
|
<File
|
||||||
RelativePath=".\src\PDFException.cpp"/>
|
RelativePath=".\src\PDFException.cpp"/>
|
||||||
|
<File
|
||||||
|
RelativePath=".\src\Table.cpp"/>
|
||||||
<File
|
<File
|
||||||
RelativePath=".\src\TextAnnotation.cpp"/>
|
RelativePath=".\src\TextAnnotation.cpp"/>
|
||||||
|
<File
|
||||||
|
RelativePath=".\src\XMLTemplate.cpp"/>
|
||||||
</Filter>
|
</Filter>
|
||||||
<Filter
|
<Filter
|
||||||
Name="Header Files">
|
Name="Header Files">
|
||||||
|
@ -21,6 +21,7 @@ project(":PDF") {
|
|||||||
srcDirs 'include', 'include/Poco/PDF'
|
srcDirs 'include', 'include/Poco/PDF'
|
||||||
}
|
}
|
||||||
lib project: ':Util', library: 'Util'
|
lib project: ':Util', library: 'Util'
|
||||||
|
lib project: ':XML', library: 'XML'
|
||||||
lib project: ':Foundation', library: 'Foundation'
|
lib project: ':Foundation', library: 'Foundation'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -2,6 +2,7 @@ def os = org.gradle.internal.os.OperatingSystem.current()
|
|||||||
rootProject.name = 'Poco'
|
rootProject.name = 'Poco'
|
||||||
|
|
||||||
include ':CppUnit'
|
include ':CppUnit'
|
||||||
|
include ':Encodings'
|
||||||
include ':Foundation'
|
include ':Foundation'
|
||||||
include ':XML'
|
include ':XML'
|
||||||
include ':JSON'
|
include ':JSON'
|
||||||
@ -12,12 +13,12 @@ include ':NetSSL_OpenSSL'
|
|||||||
if (os.windows) {
|
if (os.windows) {
|
||||||
include ':NetSSL_Win'
|
include ':NetSSL_Win'
|
||||||
}
|
}
|
||||||
include ':Data'
|
include ':SQL'
|
||||||
if (os.windows) {
|
if (os.windows) {
|
||||||
include ':Data:ODBC'
|
include ':SQL:ODBC'
|
||||||
include ':Data:SQLite'
|
include ':SQL:SQLite'
|
||||||
include ':Data:MySQL'
|
include ':SQL:MySQL'
|
||||||
include ':Data:PostgreSQL'
|
include ':SQL:PostgreSQL'
|
||||||
}
|
}
|
||||||
include ':Zip'
|
include ':Zip'
|
||||||
include ':PageCompiler'
|
include ':PageCompiler'
|
||||||
@ -29,38 +30,40 @@ include ':Redis'
|
|||||||
include ':PocoDoc'
|
include ':PocoDoc'
|
||||||
include ':ProGen'
|
include ':ProGen'
|
||||||
|
|
||||||
|
include ':Encodings:testsuite'
|
||||||
include ':Foundation:testsuite'
|
include ':Foundation:testsuite'
|
||||||
include ':XML:testsuite'
|
include ':XML:testsuite'
|
||||||
include ':JSON:testsuite'
|
include ':JSON:testsuite'
|
||||||
include ':Util:testsuite'
|
include ':Util:testsuite'
|
||||||
include ':Net:testsuite'
|
include ':Net:testsuite'
|
||||||
include ':Crypto:testsuite'
|
//include ':Crypto:testsuite'
|
||||||
include ':NetSSL_OpenSSL:testsuite'
|
include ':NetSSL_OpenSSL:testsuite'
|
||||||
if (os.windows) {
|
if (os.windows) {
|
||||||
include ':NetSSL_Win:testsuite'
|
include ':NetSSL_Win:testsuite'
|
||||||
}
|
}
|
||||||
include ':Data:testsuite'
|
include ':SQL:testsuite'
|
||||||
if (os.windows) {
|
if (os.windows) {
|
||||||
include ':Data:ODBC:testsuite'
|
include ':SQL:ODBC:testsuite'
|
||||||
include ':Data:SQLite:testsuite'
|
include ':SQL:SQLite:testsuite'
|
||||||
include ':Data:MySQL:testsuite'
|
include ':SQL:MySQL:testsuite'
|
||||||
include ':Data:PostgreSQL:testsuite'
|
include ':SQL:PostgreSQL:testsuite'
|
||||||
}
|
}
|
||||||
//include ':MongoDB:testsuite'
|
//include ':MongoDB:testsuite'
|
||||||
include ':Redis:testsuite'
|
include ':Redis:testsuite'
|
||||||
include ':CppParser:testsuite'
|
include ':CppParser:testsuite'
|
||||||
include ':Zip:testsuite'
|
include ':Zip:testsuite'
|
||||||
|
|
||||||
|
include ':Encodings:samples'
|
||||||
include ':Foundation:samples'
|
include ':Foundation:samples'
|
||||||
if (os.windows) {
|
if (os.windows) {
|
||||||
include ':Data:samples'
|
include ':SQL:samples'
|
||||||
}
|
}
|
||||||
include ':NetSSL_OpenSSL:samples'
|
include ':NetSSL_OpenSSL:samples'
|
||||||
if (os.windows) {
|
if (os.windows) {
|
||||||
include ':NetSSL_Win:samples'
|
include ':NetSSL_Win:samples'
|
||||||
}
|
}
|
||||||
include ':JSON:samples'
|
include ':JSON:samples'
|
||||||
include ':MongoDB:samples'
|
//include ':MongoDB:samples'
|
||||||
include ':Net:samples'
|
include ':Net:samples'
|
||||||
include ':PageCompiler:samples'
|
include ':PageCompiler:samples'
|
||||||
include ':PDF:samples'
|
include ':PDF:samples'
|
||||||
|
Loading…
x
Reference in New Issue
Block a user