Build.PL
changeset 101 bdd9a0816a33
parent 100 ecbfe57939c1
child 102 3000f3962b14
--- a/Build.PL	Tue Jan 25 23:00:34 2011 +0100
+++ b/Build.PL	Tue Jan 25 23:10:48 2011 +0100
@@ -6,19 +6,25 @@
 
 my $builder = Module::Build->subclass(
     class => "My::Module::Build",
-    code => <<'___CODE',
+    code  => <<'___CODE',
     use strict;
     use warnings;
     use File::Path;
     sub ACTION_build {
 	my $self = shift;
-	File::Path::make_path("tmp/bind/master", "tmp/bind/zones.d");
+	File::Path::make_path(qw(tmp/bind/master tmp/bind/zones.d));
 	$self->SUPER::ACTION_build;
     }
+    sub ACTION_realclean {
+	my $self = shift;
+	File::Path::remove_tree(qw(tmp/bind/master tmp/bind/zones.d), { safe => 1 });
+	map { rmdir } qw(tmp/bind tmp);
+	$self->SUPER::ACTION_realclean;
+    }
 ___CODE
 );
 
-my $build = My::Module::Build->new(
+my $build = $builder->new(
     module_name    => "dnstools",
     dist_author    => "schlittermann.de",
     dist_version   => "0.1.1",