diff --git a/snap/local/scripts/remove_dcgmproftester.sh b/snap/local/scripts/remove_dcgmproftester.sh index 0eac9ae..af01425 100755 --- a/snap/local/scripts/remove_dcgmproftester.sh +++ b/snap/local/scripts/remove_dcgmproftester.sh @@ -1,28 +1,16 @@ #!/bin/bash -LIBS_TO_REMOVE=( +FILES_TO_REMOVE=( "dcgmproftester*" "libdcgm_cublas_proxy*" - # libs that library linter warn that is unused - # see https://snapcraft.io/docs/linters-library - "libnvperf_dcgm_host.so" - "libnvml_injection.so.1.0" - "libdcgmmodulesysmon.so.*" - "libdcgmmoduleprofiling.so.*" - "libdcgmmodulepolicy.so.*" - "libdcgmmodulenvswitch.so.*" - "libdcgmmoduleintrospect.so.*" - "libdcgmmodulehealth.so.*" - "libdcgmmodulediag.so.*" - "libdcgmmoduleconfig.so.*" ) echo "Removing dcgmproftester libs" -for lib in "${LIBS_TO_REMOVE[@]}"; do +for lib in "${FILES_TO_REMOVE[@]}"; do find "$SNAPCRAFT_PRIME" -type f -name "$lib" | while read -r file; do echo "Removing file $file" rm -f "$file"