mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-07-03 03:01:44 +00:00
Adds wpiUtil to HAL and JNI (#280)
This commit is contained in:
committed by
Peter Johnson
parent
f2751db5c2
commit
c46c490376
@@ -4,6 +4,8 @@
|
||||
|
||||
apply plugin: 'cpp'
|
||||
|
||||
defineWpiUtilProperties()
|
||||
|
||||
model {
|
||||
components {
|
||||
HALAthena(NativeLibrarySpec) {
|
||||
@@ -11,6 +13,7 @@ model {
|
||||
binaries.all {
|
||||
tasks.withType(CppCompile) {
|
||||
addNiLibraryLinks(linker, targetPlatform)
|
||||
addWpiUtilLibraryLinks(it, linker, targetPlatform)
|
||||
}
|
||||
}
|
||||
sources {
|
||||
@@ -20,7 +23,7 @@ model {
|
||||
includes = ["**/*.cpp"]
|
||||
}
|
||||
exportedHeaders {
|
||||
srcDirs = ["include", "lib/athena/FRC_FPGA_ChipObject"]
|
||||
srcDirs = ["include", "lib/athena/FRC_FPGA_ChipObject", wpiUtilInclude]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -14,6 +14,8 @@ dependencies {
|
||||
athenaRuntime 'edu.wpi.first.wpilib.networktables.java:NetworkTables:+:arm'
|
||||
}
|
||||
|
||||
defineWpiUtilProperties()
|
||||
|
||||
// Configuration for the HAL bindings
|
||||
model {
|
||||
components {
|
||||
@@ -23,6 +25,7 @@ model {
|
||||
tasks.withType(CppCompile) {
|
||||
dependsOn jniHeaders
|
||||
addNiLibraryLinks(linker, targetPlatform)
|
||||
addWpiUtilLibraryLinks(it, linker, targetPlatform)
|
||||
}
|
||||
}
|
||||
sources {
|
||||
@@ -35,7 +38,7 @@ model {
|
||||
// JDK is included for jni.h. We also need the arm-linux specific headers. This does not need to change
|
||||
// when compiling on Windows
|
||||
// The JNI headers are put into the build/include directory by the jniHeaders task on wpilibJavaDevices
|
||||
srcDirs = ["$jniDir/include", "$jniDir/include/linux"]
|
||||
srcDirs = ["$jniDir/include", "$jniDir/include/linux", wpiUtilInclude]
|
||||
jniHeaders.outputs.files.each { file ->
|
||||
srcDirs file.getPath()
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user