Skip to content

Commit

Permalink
Merge pull request pocoproject#2235 from Kampbell/develop
Browse files Browse the repository at this point in the history
AppVeyor: readd SQL database unittests on MSBuild
  • Loading branch information
zosrothko authored Mar 20, 2018
2 parents e16a26c + 43c651a commit 3843cad
Show file tree
Hide file tree
Showing 19 changed files with 91 additions and 67 deletions.
1 change: 1 addition & 0 deletions CppParser/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -30,3 +30,4 @@ model {
}
}
task poco { dependsOn "assemble" }

1 change: 0 additions & 1 deletion CppUnit/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -32,4 +32,3 @@ model {
}
task poco { dependsOn "assemble" }


1 change: 0 additions & 1 deletion Foundation/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,6 @@ model {
}
withType(SharedLibraryBinarySpec) {
if (toolChain in VisualCpp) {
// addCompilerDefine "Foundation_EXPORTS" ""
cCompiler.define "Foundation_EXPORTS"
cppCompiler.define "Foundation_EXPORTS"
}
Expand Down
1 change: 0 additions & 1 deletion MongoDB/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -34,4 +34,3 @@ model {
}
task poco { dependsOn "assemble" }


1 change: 0 additions & 1 deletion Net/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -37,4 +37,3 @@ model {
}
task poco { dependsOn "assemble" }


1 change: 0 additions & 1 deletion NetSSL_OpenSSL/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -38,4 +38,3 @@ model {
}
task poco { dependsOn "assemble" }


1 change: 1 addition & 0 deletions NetSSL_Win/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -44,3 +44,4 @@ model {
}
}
task poco { dependsOn "assemble" }

1 change: 0 additions & 1 deletion PageCompiler/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -38,4 +38,3 @@ model {
}
task poco { dependsOn "assemble" }


1 change: 0 additions & 1 deletion Redis/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -34,4 +34,3 @@ model {
}
task poco { dependsOn "assemble" }


1 change: 0 additions & 1 deletion SQL/MySQL/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -101,4 +101,3 @@ model {
}
task poco { dependsOn "assemble" }


1 change: 0 additions & 1 deletion SQL/ODBC/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -43,4 +43,3 @@ model {
}
task poco { dependsOn "assemble" }


1 change: 0 additions & 1 deletion SQL/PostgreSQL/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -230,4 +230,3 @@ model {
}
task poco { dependsOn "assemble" }


1 change: 0 additions & 1 deletion SQL/SQLite/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -66,4 +66,3 @@ model {
}
task poco { dependsOn "assemble" }


1 change: 1 addition & 0 deletions Util/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -58,3 +58,4 @@ model {
}
}
task poco { dependsOn "assemble" }

1 change: 0 additions & 1 deletion Zip/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -35,4 +35,3 @@ model {
}
task poco { dependsOn "assemble" }


4 changes: 2 additions & 2 deletions appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -507,12 +507,12 @@ test_script:
if ($env:platform -eq "Win32")
{
$env:PATH = "$env:POCO_BASE\bin;" + $env:PATH;$suffix = '';
$excluded = @('SQL', 'SQL/ODBC', 'Redis', 'PDF')
$excluded = @('Redis', 'PDF')
}
if ($env:platform -eq "x64")
{
$env:PATH = "$env:POCO_BASE\bin64;" + $env:PATH;$suffix = 64;
$excluded = @('SQL', 'SQL/ODBC', 'Redis', 'PDF')
$excluded = @('Redis', 'PDF')
}
Write-Host -ForegroundColor Yellow '>>> current directory is ' $(get-location).Path;
Expand Down
96 changes: 79 additions & 17 deletions build.gradle
Original file line number Diff line number Diff line change
@@ -1,22 +1,16 @@
buildscript {
}

/*
dependencies {
testCompile group: 'org.jvnet.hudson.plugins', name: 'cppunit', version: '1.10'
}
*/
/*
dependencies {
classpath group: 'org.pocoproject', name: 'cppunit-test-suite', version:'1.0.0'
classpath group: 'org.pocoproject', name: 'windows-message-compiler', version:'1.0.0'
}
*/
plugins {
id 'net.saliman.cobertura' version '2.5.1'
id 'com.ullink.nuget' version '2.15'
// id 'net.saliman.cobertura' version '2.5.1'
// id 'com.jfrog.artifactory' version '4.1'
}
apply plugin: 'base'
apply plugin: 'base'
apply plugin: 'nuget'
nuget {
version = '4.4.1'
}

def os = org.gradle.internal.os.OperatingSystem.current()
def String version = file("VERSION").text.replaceAll("[\n\r]", "")
Expand Down Expand Up @@ -200,8 +194,9 @@ class SliceTasksPlugin extends RuleSource {
}
}


allprojects {
buildDir = new File('root') // DO NOT REMOVE OR CHANGE to 'build' since 'build' is a Poco directory
buildDir = new File('guild') // DO NOT REMOVE OR CHANGE to 'build' since 'build' is a Poco directory
file('bin').mkdirs()
file('bin64').mkdirs()
file('lib').mkdirs()
Expand All @@ -223,7 +218,7 @@ subprojects {
apply plugin: 'windows-messages'
apply plugin: SliceTasksPlugin

buildDir = new File("gradle")
buildDir = new File("guild")


model {
Expand Down Expand Up @@ -808,10 +803,15 @@ subprojects {

args test
}



}

tasks.withType(CppCompile) {
maxParallelForks = 2
}

task PocoDocIni {
def file = new File("$rootDir/PocoDoc/PocoDoc.ini")
file.createNewFile()
Expand All @@ -828,7 +828,7 @@ PocoDoc.version=${version}-all
javaWDK = javaWDK.replace('\\','/')

file.text += """
Includes=-I${postgres32Home}/include,-I${mysql32Home}/include,-ICppParser/include,-ICppUnit/include,-ICrypto/include,-IData/include,-ISQL/include,-ISQL/MySQL/include,-ISQL/ODBC/include,-ISQL/PostgreSQL/include,-ISQL/SQLite/include, -ISQL/SQLite/src,-IFoundation/include,-IJSON/include,-IMongoDB/include,-INet/include,-INetSSL_OpenSSL/include,-INetSSL_Win/include,-IRedis/include,-IUtil/include,-IXML/include,-IZip/include,-ISevenZip/include,-IPDF/include
Includes=-I${postgres32Home}/include,-I${mysql32Home}/include,-ICppParser/include,-ICppUnit/include,-ICrypto/include,-ISQL/include,-ISQL/include,-ISQL/MySQL/include,-ISQL/ODBC/include,-ISQL/PostgreSQL/include,-ISQL/SQLite/include, -ISQL/SQLite/src,-IFoundation/include,-IJSON/include,-IMongoDB/include,-INet/include,-INetSSL_OpenSSL/include,-INetSSL_Win/include,-IRedis/include,-IUtil/include,-IXML/include,-IZip/include,-ISevenZip/include,-IPDF/include
VCH=${javaVCH}
WDK=${javaWDK}
CLP=${javaCLP}
Expand Down Expand Up @@ -942,6 +942,69 @@ task wix() {
}
});
}
/*
ext.commonNuspecMetadata = [
version: '2.0.0',
owners: 'Günter Obiltschnig & Aleksandar Fabijanic',
authors: 'Applied Informatics & Contributors',
projectUrl: 'https://pocoproject.org/',
licenseUrl: 'https://pocoproject.org/license.html',
iconUrl: 'https://avatars1.githubusercontent.com/u/201918?v=4&s=200',
copyright: 'Applied Informatics copyright 2018',
requireLicenseAcceptance: false,
description: 'Modern, powerful open source C++ class libraries for building network- and internet-based applications that run on desktop, server, mobile and embedded systems.',
tags: 'string filesystem thread date log event regex uri uuid cache native nativepackage sockets mime http ftp mail pop3 smtp html sax sax2 dom xml'
]
def pocoNugetSpec(os) {
return tasks.create("nugetSpec-$os", nugetSpec) {
def String vers = commonNuspecMetadata.find { it.key == "version" }.value;
nuspec = [
metadata: commonNuspecMetadata + [
id: "Pocoproject.Poco.vs150",
title: "Poco $vers",
dependencies: [
]
],
files: [
{ file(src: "$rootDir\\packaging\\Windows\\NuGet\\Pocoproject.Poco.vs150.targets", target: "build\\native") },
{ file(src: "$rootDir\\bin\\Poco*.*", target: "build\\native\\bin") },
{ file(src: "$rootDir\\lib\\Poco*.*", target: "build\\native\\lib") },
{ file(src: "$rootDir\\bin64\\Poco*64.*", target: "build\\native\\bin64") },
{ file(src: "$rootDir\\lib64\\Poco*.*", target: "build\\native\\lib64") },
{ file(src: "$rootDir\\bin\\Poco*d.*", target: "build\\native\\bin") },
{ file(src: "$rootDir\\lib\\Poco*d.*", target: "build\\native\\lib") },
{ file(src: "$rootDir\\bin64\\Poco*64d.*", target: "build\\native\\bin64") },
{ file(src: "$rootDir\\lib64\\Poco*d.*", target: "build\\native\\lib64") },
{ file(src: "$rootDir\\CppUnit\\include\\**", target: "build\\native\\inc") },
{ file(src: "$rootDir\\Crypto\\include\\**", target: "build\\native\\inc") },
{ file(src: "$rootDir\\SQL\\MySQL\\include\\**", target: "build\\native\\inc") },
{ file(src: "$rootDir\\SQL\\include\\**", target: "build\\native\\inc") },
{ file(src: "$rootDir\\SQL\\ODBC\\include\\**", target: "build\\native\\inc") },
{ file(src: "$rootDir\\SQL\\SQLite\\include\\**", target: "build\\native\\inc") },
{ file(src: "$rootDir\\Encodings\\include\\**", target: "build\\native\\inc") },
{ file(src: "$rootDir\\Foundation\\include\\**", target: "build\\native\\inc") },
{ file(src: "$rootDir\\JSON\\include\\**", target: "build\\native\\inc") },
{ file(src: "$rootDir\\MongoDB\\include\\**", target: "build\\native\\inc") },
{ file(src: "$rootDir\\Net\\include\\**", target: "build\\native\\inc") },
{ file(src: "$rootDir\\NetSSL_OpenSSL\\include\\**", target: "build\\native\\inc") },
{ file(src: "$rootDir\\NetSSL_Win\\include\\**", target: "build\\native\\inc") },
{ file(src: "$rootDir\\PDF\\include\\**", target: "build\\native\\inc") },
{ file(src: "$rootDir\\Util\\include\\**", target: "build\\native\\inc") },
{ file(src: "$rootDir\\XML\\include\\**", target: "build\\native\\inc") },
{ file(src: "$rootDir\\Zip\\include\\**", target: "build\\native\\inc") }
]
]
}
}
nugetPack {
destinationDir "$rootDir/packaging/Windows/Nuget"
def Set<Task> pocos = project.getTasksByName('poco', true)
// setDependsOn(pocos)
dependsOn pocoNugetSpec('x86')
}
*/

task nuget(type: Exec) {
String nugetVersion = version.replace('p', '-')
def Set<Task> pocos = project.getTasksByName('poco', true)
Expand Down Expand Up @@ -1075,7 +1138,6 @@ task coverage() {
tasksSet.each { task -> dependsOn report(os, task.project.parent.path.replace(':','/').substring(1), task.project.parent.name) }
}
}

/*
task all() {
FileCollection incs = task.includes;
Expand Down
12 changes: 7 additions & 5 deletions packaging/Windows/NuGet/Pocoproject.Poco.vs150.nuspec
Original file line number Diff line number Diff line change
Expand Up @@ -26,11 +26,12 @@
</dependencies>
</metadata>
<files>
<file src='packaging\Windows\NuGet\Pocoproject.Poco.vs150.targets' target='build\native'/>
<file src='bin\*' target='build\native\bin' exclude='bin\PocoCppParser*'/>
<file src='lib\*' target='build\native\lib' exclude='lib\PocoCppParser*'/>
<file src='bin64\*' target='build\native\bin64' exclude='bin64\PocoCppParser*'/>
<file src='lib64\*' target='build\native\lib64' exclude='lib64\PocoCppParser*'/>
<file src='packaging\Windows\NuGet\Pocoproject.Poco.vs150.targets' target='build\native'/>
<file src='bin\*' target='build\native\bin' exclude='bin\Poco*d.*, bin\PocoCppParser*'/>
<file src='lib\*' target='build\native\lib' exclude='bin\Poco*d.*, bin\PocoCppParser*'/>
<file src='bin64\*' target='build\native\bin64' exclude='bin\Poco*d.*, bin\PocoCppParser*'/>
<file src='lib64\*' target='build\native\lib64' exclude='bin\Poco*d.*, bin\PocoCppParser*'/>
<!--
<file src='openssl\build\win32\bin\debug\*' target='build\native\bin' exclude='bin\PocoCppParser*'/>
<file src='openssl\build\win32\bin\release\*' target='build\native\bin' exclude='bin\PocoCppParser*'/>
<file src='openssl\build\win32\lib\debug\*' target='build\native\lib' exclude='lib\PocoCppParser*'/>
Expand All @@ -39,6 +40,7 @@
<file src='openssl\build\win64\bin\release\*' target='build\native\bin64' exclude='bin\PocoCppParser*'/>
<file src='openssl\build\win64\lib\debug\*' target='build\native\lib64' exclude='lib\PocoCppParser*'/>
<file src='openssl\build\win64\lib\release\*' target='build\native\lib64' exclude='lib\PocoCppParser*'/>
-->
<file src='CppUnit\include\**' target='build\native\inc' />
<file src='Crypto\include\**' target='build\native\inc' />
<file src='Data\MySQL\include\**' target='build\native\inc' />
Expand Down
31 changes: 0 additions & 31 deletions packaging/Windows/NuGet/Pocoproject.Poco.vs150.symbols.nuspec

This file was deleted.

0 comments on commit 3843cad

Please sign in to comment.