mirror of
https://github.com/pocoproject/poco.git
synced 2024-12-14 19:13:49 +01:00
61 lines
1.1 KiB
Groovy
61 lines
1.1 KiB
Groovy
model {
|
|
components {
|
|
Util(NativeLibrarySpec) { m ->
|
|
sources {
|
|
rc {
|
|
source {
|
|
srcDir '..'
|
|
include 'DLLVersion.rc'
|
|
}
|
|
}
|
|
c {
|
|
source {
|
|
srcDir 'src'
|
|
include '**/*.c'
|
|
}
|
|
exportedHeaders {
|
|
srcDir 'include'
|
|
}
|
|
}
|
|
cpp {
|
|
source {
|
|
srcDir 'src'
|
|
include '**/*.cpp'
|
|
exclude '**/Win*.cpp'
|
|
}
|
|
exportedHeaders {
|
|
srcDir 'include'
|
|
}
|
|
lib project: ':Foundation', library: 'Foundation'
|
|
lib project: ':XML', library: 'XML'
|
|
lib project: ':JSON', library: 'JSON'
|
|
}
|
|
}
|
|
binaries.all {
|
|
if (targetPlatform.operatingSystem.windows) {
|
|
sources {
|
|
platformWindows(CppSourceSet) {
|
|
lib m.sources.cpp
|
|
source {
|
|
srcDir 'src'
|
|
include '**/Win*.cpp'
|
|
}
|
|
lib project: ':Foundation', library: 'Foundation'
|
|
lib project: ':XML', library: 'XML'
|
|
lib project: ':JSON', library: 'JSON'
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
binaries {
|
|
withType(SharedLibraryBinarySpec) {
|
|
if (toolChain in VisualCpp) {
|
|
cppCompiler.define "Util_EXPORTS"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
task poco { dependsOn "assemble" }
|