File tree Expand file tree Collapse file tree 1 file changed +25
-2
lines changed Expand file tree Collapse file tree 1 file changed +25
-2
lines changed Original file line number Diff line number Diff line change @@ -22,12 +22,35 @@ my $secure_perl_path = get_perl_filename();
22
22
23
23
sub MY ::postamble { # TODO also handle Windows nmake syntax (SET vs. export)
24
24
return <<EOT ;
25
+
26
+ # Uninstallation: mimic what the normal "uninstall" target does, but actually
27
+ # carry out the actions.
28
+ # Note: this may leave empty directories in place, since the packlist only
29
+ # includes files.
30
+
31
+ ACTUALLY_UNINSTALL = "$secure_perl_path " -MExtUtils::Install -e 'uninstall(shift,1)' --
32
+
33
+ actually_uninstall :: actually_uninstall_from_\$ (INSTALLDIRS)dirs
34
+ \t\$ (NOECHO) \$ (NOOP)
35
+
36
+ actually_uninstall_from_perldirs ::
37
+ \t -\$ (ACTUALLY_UNINSTALL) "\$ (PERL_ARCHLIB)/auto/\$ (FULLEXT)/.packlist"
38
+
39
+ actually_uninstall_from_sitedirs ::
40
+ \t -\$ (ACTUALLY_UNINSTALL) "\$ (SITEARCHEXP)/auto/\$ (FULLEXT)/.packlist"
41
+
42
+ actually_uninstall_from_vendordirs ::
43
+ \t -\$ (ACTUALLY_UNINSTALL) "\$ (VENDORARCHEXP)/auto/\$ (FULLEXT)/.packlist"
44
+
45
+ # Run author tests
25
46
authortest:
26
- \t RELEASE_TESTING=1 prove -l xt"
47
+ \t RELEASE_TESTING=1 prove -l xt
27
48
28
- testhere: # Run the tests from lib rather than blib
49
+ # Test without installing: run the tests from lib rather than blib
50
+ testhere: actually_uninstall
29
51
\t "$secure_perl_path " -Ilib -e 'use Test::Harness "runtests"; runtests \@ ARGV;' -- t/*.t
30
52
EOT
53
+
31
54
} # postamble
32
55
33
56
WriteMakefile(
You can’t perform that action at this time.
0 commit comments