This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
.PHONY not portable in dist/Locale-Maketext/Makefile.PL
[perl5.git] / dist / Locale-Maketext / Makefile.PL
index 72cc31e..212982d 100644 (file)
@@ -28,8 +28,15 @@ WriteMakefile(
 );
 
 sub MY::postamble {
-    return <<'MAKE_FRAG';
-.PHONY: tags critic
+    # .PHONY is not portable
+    my $self = shift;
+    my $phony_line = $self->can('is_make_type')
+                     && ($self->is_make_type('gmake')
+                         || $self->is_make_type('bsdmake'))
+                     ? '.PHONY: tags critic'
+                     : '';
+
+    return "$phony_line\n\n" . <<'MAKE_FRAG';
 
 tags:
        ctags -f tags --recurse --totals \