diff --git a/pkgs/servers/samba/4.x.nix b/pkgs/servers/samba/4.x.nix index 4aceb10d93a3..88defab93025 100644 --- a/pkgs/servers/samba/4.x.nix +++ b/pkgs/servers/samba/4.x.nix @@ -159,7 +159,7 @@ stdenv.mkDerivation rec { # Use find -type f -executable -exec echo {} \; -exec sh -c 'ldd {} | grep "not found"' \; # Looks like a bug in installer scripts. postFixup = '' - export SAMBA_LIBS="$(find $out -type f -name \*.so -exec dirname {} \; | sort | uniq)" + export SAMBA_LIBS="$(find $out -type f -regex '.*\.so\(\..*\)?' -exec dirname {} \; | sort | uniq)" read -r -d "" SCRIPT << EOF || true [ -z "\$SAMBA_LIBS" ] && exit 1; BIN='{}'; @@ -168,7 +168,7 @@ stdenv.mkDerivation rec { patchelf --set-rpath "\$ALL_LIBS" "\$BIN" 2>/dev/null || exit $?; patchelf --shrink-rpath "\$BIN"; EOF - find $out -type f -name \*.so -exec $SHELL -c "$SCRIPT" \; + find $out -type f -regex '.*\.so\(\..*\)?' -exec $SHELL -c "$SCRIPT" \; # Samba does its own shebang patching, but uses build Python find "$out/bin" -type f -executable -exec \