Skip to content

Commit

Permalink
Search in current folder by default
Browse files Browse the repository at this point in the history
  • Loading branch information
milianw committed May 4, 2018
1 parent 2861f6c commit b866f13
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion find-old-lib-files
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,13 @@
# are checked by looking at where libFoo.so links
#

find "$1/" -type f -name "*.so.*" | while read f; do
dir="."

if [ ! -z "$1" ]; then
dir="$1/"; # trailing slash to enter symlinked folders
fi

find "$dir" -type f -name "*.so.*" | while read f; do
base=$(echo $f | sed 's/.so.*$/.so/');
if [[ -f "$base" && "$(readlink -f $base)" != "$(readlink -f $f)" ]]; then
echo $f;
Expand Down

0 comments on commit b866f13

Please sign in to comment.