diff --git a/CMakeLists.txt b/CMakeLists.txt index 0ef7f668f6..aa4f14f8ef 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -38,7 +38,12 @@ set(ROCM_PATH /opt/rocm CACHE PATH "Default ROCm installation path") if(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT) set(CMAKE_INSTALL_PREFIX ${ROCM_PATH} CACHE PATH "MIVisionX default installation path" FORCE) endif(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT) -set(CMAKE_INSTALL_RPATH_USE_LINK_PATH TRUE) + +# Changes for RPATH Removal from Binaries: +# Since all public interface libraries are present in same folder +# RPATH/RUNPATH is not required +set(CMAKE_INSTALL_RPATH_USE_LINK_PATH FALSE) +set(CMAKE_SKIP_INSTALL_RPATH TRUE) # MIVisionX Default Options option(ENHANCED_MESSAGE "MIVisionX Enhanced Message Option" ON) diff --git a/amd_openvx_extensions/amd_custom/custom_lib/CMakeLists.txt b/amd_openvx_extensions/amd_custom/custom_lib/CMakeLists.txt index dddade3eed..33adce4623 100644 --- a/amd_openvx_extensions/amd_custom/custom_lib/CMakeLists.txt +++ b/amd_openvx_extensions/amd_custom/custom_lib/CMakeLists.txt @@ -29,7 +29,12 @@ set(ROCM_PATH /opt/rocm CACHE PATH "Default ROCm installation path") if(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT) set(CMAKE_INSTALL_PREFIX ${ROCM_PATH} CACHE PATH "MIVisionX default installation path" FORCE) endif(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT) -set(CMAKE_INSTALL_RPATH_USE_LINK_PATH TRUE) + +# Changes for RPATH Removal from Binaries: +# Since all public interface libraries are present in same folder +# RPATH/RUNPATH is not required +set(CMAKE_INSTALL_RPATH_USE_LINK_PATH FALSE) +set(CMAKE_SKIP_INSTALL_RPATH TRUE) # Add Default libdir set(CMAKE_INSTALL_LIBDIR "lib" CACHE STRING "Library install directory") diff --git a/apps/cloud_inference/server_app/CMakeLists.txt b/apps/cloud_inference/server_app/CMakeLists.txt index 1081e444c3..5a2e3f4d01 100644 --- a/apps/cloud_inference/server_app/CMakeLists.txt +++ b/apps/cloud_inference/server_app/CMakeLists.txt @@ -29,7 +29,12 @@ set(ROCM_PATH /opt/rocm CACHE PATH "Default ROCm installation path") if(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT) set(CMAKE_INSTALL_PREFIX ${ROCM_PATH} CACHE PATH "MIVisionX default installation path" FORCE) endif(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT) -set(CMAKE_INSTALL_RPATH_USE_LINK_PATH TRUE) + +# Changes for RPATH Removal from Binaries: +# Since all public interface libraries are present in same folder +# RPATH/RUNPATH is not required +set(CMAKE_INSTALL_RPATH_USE_LINK_PATH FALSE) +set(CMAKE_SKIP_INSTALL_RPATH TRUE) # Add Default libdir set(CMAKE_INSTALL_LIBDIR "lib" CACHE STRING "Library install directory") diff --git a/apps/dg_test/CMakeLists.txt b/apps/dg_test/CMakeLists.txt index 6bdc6de487..4c760e3175 100644 --- a/apps/dg_test/CMakeLists.txt +++ b/apps/dg_test/CMakeLists.txt @@ -29,7 +29,12 @@ set(ROCM_PATH /opt/rocm CACHE PATH "Default ROCm installation path") if(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT) set(CMAKE_INSTALL_PREFIX ${ROCM_PATH} CACHE PATH "MIVisionX default installation path" FORCE) endif(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT) -set(CMAKE_INSTALL_RPATH_USE_LINK_PATH TRUE) + +# Changes for RPATH Removal from Binaries: +# Since all public interface libraries are present in same folder +# RPATH/RUNPATH is not required +set(CMAKE_INSTALL_RPATH_USE_LINK_PATH FALSE) +set(CMAKE_SKIP_INSTALL_RPATH TRUE) # Add Default libdir set(CMAKE_INSTALL_LIBDIR "lib" CACHE STRING "Library install directory") diff --git a/apps/image_augmentation/CMakeLists.txt b/apps/image_augmentation/CMakeLists.txt index 65fcaa309f..81afd51d48 100644 --- a/apps/image_augmentation/CMakeLists.txt +++ b/apps/image_augmentation/CMakeLists.txt @@ -36,7 +36,12 @@ set(ROCM_PATH /opt/rocm CACHE PATH "Default ROCm installation path") if(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT) set(CMAKE_INSTALL_PREFIX ${ROCM_PATH} CACHE PATH "MIVisionX default installation path" FORCE) endif(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT) -set(CMAKE_INSTALL_RPATH_USE_LINK_PATH TRUE) + +# Changes for RPATH Removal from Binaries: +# Since all public interface libraries are present in same folder +# RPATH/RUNPATH is not required +set(CMAKE_INSTALL_RPATH_USE_LINK_PATH FALSE) +set(CMAKE_SKIP_INSTALL_RPATH TRUE) # Add Default libdir set(CMAKE_INSTALL_LIBDIR "lib" CACHE STRING "Library install directory") diff --git a/apps/mivisionx_openvx_classifier/CMakeLists.txt b/apps/mivisionx_openvx_classifier/CMakeLists.txt index f52926559d..64519a6dd7 100644 --- a/apps/mivisionx_openvx_classifier/CMakeLists.txt +++ b/apps/mivisionx_openvx_classifier/CMakeLists.txt @@ -32,7 +32,12 @@ set(ROCM_PATH /opt/rocm CACHE PATH "Default ROCm installation path") if(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT) set(CMAKE_INSTALL_PREFIX ${ROCM_PATH} CACHE PATH "MIVisionX default installation path" FORCE) endif(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT) -set(CMAKE_INSTALL_RPATH_USE_LINK_PATH TRUE) + +# Changes for RPATH Removal from Binaries: +# Since all public interface libraries are present in same folder +# RPATH/RUNPATH is not required +set(CMAKE_INSTALL_RPATH_USE_LINK_PATH FALSE) +set(CMAKE_SKIP_INSTALL_RPATH TRUE) # Add Default libdir set(CMAKE_INSTALL_LIBDIR "lib" CACHE STRING "Library install directory") diff --git a/model_compiler/python/nnir_to_clib.py b/model_compiler/python/nnir_to_clib.py index ab0296457a..86f5c4d619 100644 --- a/model_compiler/python/nnir_to_clib.py +++ b/model_compiler/python/nnir_to_clib.py @@ -128,7 +128,12 @@ def generateCMakeFiles(graph,outputFolder): if(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT) set(CMAKE_INSTALL_PREFIX ${ROCM_PATH} CACHE PATH "mivisionx default installation path" FORCE) endif(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT) -set(CMAKE_INSTALL_RPATH_USE_LINK_PATH TRUE) + +# Changes for RPATH Removal from Binaries: +# Since all public interface libraries are present in same folder +# RPATH/RUNPATH is not required +set(CMAKE_INSTALL_RPATH_USE_LINK_PATH FALSE) +set(CMAKE_SKIP_INSTALL_RPATH TRUE) list(APPEND CMAKE_MODULE_PATH ${PROJECT_SOURCE_DIR}/cmake)