find( { wanted => sub { ... }, no_chdir => 1, preprocess => sub { grep not m/$dir/ => @_ }, }, $search_root );