my $ne_loaded = 1; eval "use Non::Existent"; if ($@) { warn "You don't have Non::Existent installed so..."; $ne_loaded = 0; }