mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-06-30 02:31:44 +00:00
29 lines
813 B
Groovy
29 lines
813 B
Groovy
apply plugin: 'cpp'
|
|
apply plugin: 'visual-studio'
|
|
|
|
model {
|
|
components {
|
|
gmock(NativeLibrarySpec) {
|
|
sources {
|
|
cpp {
|
|
source {
|
|
srcDirs = ['src', 'gtest/src']
|
|
includes = ['*-all.cc']
|
|
}
|
|
exportedHeaders {
|
|
srcDirs = ['include', 'gtest/include', '.', 'gtest']
|
|
includes = ['**/*.h', '**/*.cc']
|
|
}
|
|
}
|
|
}
|
|
binaries.all {
|
|
if (toolChain in VisualCpp) {
|
|
cppCompiler.args '-D_UNICODE', '-DUNICODE', '-DWIN32', '-D_WIN32', '-DSTRICT', '-DWIN32_LEAN_AND_MEAN', '-D_HAS_EXCEPTIONS=1'
|
|
} else {
|
|
cppCompiler.args '-Wall', '-Wshadow', '-fexceptions', '-Wextra', '-Wno-unused-parameter', '-Wno-missing-field-initializers', '-lpthreads', '-fPIC'
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|