Set rpath on all unix platforms to $ORIGIN (#2299)

* Set rpath on all unix platforms to $ORIGIN

Will make it possible to extract JNI libraries easier
This commit is contained in:
Thad House
2020-06-23 21:03:04 -07:00
committed by GitHub
parent 62b8a36ce9
commit 3bcb89fb84
2 changed files with 9 additions and 5 deletions

View File

@@ -9,9 +9,9 @@ nativeUtils {
configureDependencies {
wpiVersion = "-1"
niLibVersion = "2020.10.1"
opencvVersion = "3.4.7-2"
opencvVersion = "3.4.7-3"
googleTestVersion = "1.9.0-4-437e100-1"
imguiVersion = "1.72b-3"
imguiVersion = "1.72b-4"
}
}
}
@@ -21,8 +21,12 @@ nativeUtils.wpi.addWarningsAsErrors()
nativeUtils.setSinglePrintPerPlatform()
nativeUtils.platformConfigs.named("osxx86-64").configure {
it.linker.args << "-headerpad_max_install_names"
nativeUtils.platformConfigs.each {
if (it.name.contains('windows')) return
it.linker.args << '-Wl,-rpath,\'$ORIGIN\''
if (it.name == 'osxx86-64') {
it.linker.args << "-headerpad_max_install_names"
}
}
model {

View File

@@ -1,4 +1,4 @@
def opencvVersion = '3.4.7-2'
def opencvVersion = '3.4.7-3'
if (project.hasProperty('useCpp') && project.useCpp) {
model {