diff options
author | Pirama Arumuga Nainar <pirama@google.com> | 2015-05-07 15:52:48 -0700 |
---|---|---|
committer | Pirama Arumuga Nainar <pirama@google.com> | 2015-05-11 20:21:25 +0000 |
commit | 21732f493bd56ed83fb27f8823a66910ecbcf870 (patch) | |
tree | 44846ec2b9c09a461445660ac0197425a58f6cc7 | |
parent | 2978324090dd36479a03649c8057afdf584edf86 (diff) | |
download | rs-21732f493bd56ed83fb27f8823a66910ecbcf870.tar.gz |
Add /system/vendor/{lib|lib64} to linker args
Add vendor-specific lib directory to ld.mc's library search path. Since
ld.mc takes multiple search directories, there is no need to derive a
single path at runtime.
bug 20894664
Change-Id: Id62d2acbd94914c70bf4668f553a94a33e2a0587
(cherry-pick 682672e36b05349bc4d9dee74e9fab73ce804183 from AOSP)
-rw-r--r-- | cpu_ref/rsCpuExecutable.cpp | 3 | ||||
-rw-r--r-- | cpu_ref/rsCpuScript.h | 2 |
2 files changed, 4 insertions, 1 deletions
diff --git a/cpu_ref/rsCpuExecutable.cpp b/cpu_ref/rsCpuExecutable.cpp index f59b41a7..f229f523 100644 --- a/cpu_ref/rsCpuExecutable.cpp +++ b/cpu_ref/rsCpuExecutable.cpp @@ -128,12 +128,13 @@ bool SharedLibraryUtils::createSharedLibrary(const char *driverName, const char *compiler_rt = SYSLIBPATH"/libcompiler_rt.so"; const char *mTriple = "-mtriple=" DEFAULT_TARGET_TRIPLE_STRING; const char *libPath = "--library-path=" SYSLIBPATH; + const char *vendorLibPath = "--library-path=" SYSLIBPATH_VENDOR; std::vector<const char *> args = { LD_EXE_PATH, "-shared", "-nostdlib", - compiler_rt, mTriple, libPath, + compiler_rt, mTriple, vendorLibPath, libPath, linkDriverName.c_str(), "-lm", "-lc", objFileName.c_str(), "-o", sharedLibName.c_str(), diff --git a/cpu_ref/rsCpuScript.h b/cpu_ref/rsCpuScript.h index 5ee3749a..b7e12e7f 100644 --- a/cpu_ref/rsCpuScript.h +++ b/cpu_ref/rsCpuScript.h @@ -158,8 +158,10 @@ uint32_t constructBuildChecksum(uint8_t const *bitcode, size_t bitcodeSize, #ifdef __LP64__ #define SYSLIBPATH "/system/lib64" +#define SYSLIBPATH_VENDOR "/system/vendor/lib64" #else #define SYSLIBPATH "/system/lib" +#define SYSLIBPATH_VENDOR "/system/vendor/lib" #endif } |