my $full_pm_path=''; for my $base_path (@INC) { if(-f "$base_path/$pm_path") { $full_pm_path="$base_path/$pm_path"; last; } } return 0 unless($full_pm_path);