Do not move libclang out from the clang distribution

Also load libclang using the absolute path to simplify cinterop
This commit is contained in:
Svyatoslav Scherbina
2017-04-25 15:38:13 +03:00
committed by SvyatoslavScherbina
parent ab392bf9ed
commit 8ebc0bd1ea
4 changed files with 3 additions and 25 deletions
-22
View File
@@ -215,32 +215,10 @@ task dist_compiler(type: Copy) {
into('konan')
}
from("$llvmDir/lib") {
into('konan/nativelib')
include '**/libclang.*'
includeEmptyDirs = false
}
// TODO: check if we use native libraries copied to dist (see above) or not.
from(project(':tools:helpers').file('build/libs')) {
into('konan/lib')
}
doLast {
// MacOS System Integrity Protection strips DYLD_LIBRARY_PATH from
// environment of all the binaries residing in /bin /usr/bin etc.
// That means /usr/bin/java can't use DYLD_LIBRARY_PATH to pick up
// rpath'ed libraries.
// See dyld(1), install_name_tool(1) for rpath details.
if (isMac()) {
exec {
commandLine "install_name_tool"
args '-add_rpath', '@loader_path/',
'dist/konan/nativelib/libclangstubs.dylib'
}
}
}
}
task list_dist(type: Exec) {