SWDEV-354543 Remove explicit install permission, Enhanced comments
Change-Id: Ie7a3b5b026666d65056e426eb7fa9c184a46eb07
[ROCm/rocm-core commit: c9058d2442]
Этот коммит содержится в:
коммит произвёл
Nirmal Unnikrishnan
родитель
2bef503049
Коммит
a462406388
@@ -123,7 +123,6 @@ endif()
|
||||
file ( WRITE "${CMAKE_CURRENT_BINARY_DIR}/version" "${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH}-${BUILD_ID}\n" )
|
||||
install ( FILES ${CMAKE_CURRENT_BINARY_DIR}/version DESTINATION .info COMPONENT runtime )
|
||||
install ( TARGETS ${CORE_TARGET} DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
||||
PERMISSIONS OWNER_WRITE OWNER_READ OWNER_EXECUTE GROUP_READ GROUP_EXECUTE WORLD_READ WORLD_EXECUTE
|
||||
COMPONENT ${COMP_TYPE} )
|
||||
install ( FILES ${BUILD_DIR}/rocm_version.h ${BUILD_DIR}/rocm_getpath.h
|
||||
DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/rocm-core
|
||||
|
||||
@@ -99,6 +99,8 @@ static int getROCmBase(char *buf)
|
||||
char libFileName[LIBRARY_FILENAME_BUFSZ];
|
||||
char *end=NULL;
|
||||
|
||||
// Check Environment Variable is set for ROCM
|
||||
// install base path, then use it directly.
|
||||
if ((envStr = getenv("ROCM_PATH"))) {
|
||||
/* User space override, essentially just copied through as long as it is not too long */
|
||||
len = strlen(envStr);
|
||||
@@ -119,6 +121,9 @@ static int getROCmBase(char *buf)
|
||||
}
|
||||
}
|
||||
|
||||
// If Environment Variable is not set
|
||||
// use dl APIs to get target lib path
|
||||
// and get rocm base install path using the lib Path.
|
||||
sprintf(libFileName, "lib%s.so", TARGET_LIBRARY_NAME);
|
||||
void *handle=dlopen(libFileName,RTLD_NOW);
|
||||
if (!handle){
|
||||
|
||||
Ссылка в новой задаче
Block a user