Created
February 8, 2009 02:18
-
-
Save gugod/60143 to your computer and use it in GitHub Desktop.
A little program that I used to get correct dependency list in Makefile.PL
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env perl | |
use strict; | |
use warnings; | |
use Module::ExtractUse; | |
my %used; | |
while (my $file = shift @ARGV) { | |
my $p = Module::ExtractUse->new; | |
$p->extract_use($file); | |
%used = (%used, %{$p->used}); | |
} | |
delete @used{qw(strict warnings feature)}; | |
print "requires\n"; | |
for (sort keys %used) { | |
print " '$_' => 0,\n"; | |
} | |
print ";\n"; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment