summaryrefslogtreecommitdiff
path: root/make
diff options
context:
space:
mode:
authorSadie Powell <sadie@witchery.services>2021-01-25 12:13:54 +0000
committerSadie Powell <sadie@witchery.services>2021-01-25 12:39:56 +0000
commitf6b861f12d070ba931d829505bfd3229653f5df2 (patch)
treeb043d1e05d9703ab0ec29be91055d793f0fd93d0 /make
parentcc28ba0f2164ea68db1bc373ee06fc58f82c3314 (diff)
Fix unnecessary begin blocks in Perl source files.
Diffstat (limited to 'make')
-rwxr-xr-xmake/calcdep.pl13
-rw-r--r--make/common.pm6
-rw-r--r--make/configure.pm6
-rw-r--r--make/console.pm6
-rw-r--r--make/directive.pm6
-rwxr-xr-xmake/unit-cc.pl9
6 files changed, 11 insertions, 35 deletions
diff --git a/make/calcdep.pl b/make/calcdep.pl
index 59b61e65a..3c02024fa 100755
--- a/make/calcdep.pl
+++ b/make/calcdep.pl
@@ -21,20 +21,13 @@
#
-BEGIN {
- push @INC, $ENV{SOURCEPATH};
- require 5.10.0;
- unless (-f 'configure') {
- print "Error: $0 must be run from the main source directory!\n";
- exit 1;
- }
-}
-
use strict;
use warnings FATAL => qw(all);
-use File::Basename qw(basename);
+use File::Basename qw(basename dirname);
+use FindBin qw($RealDir);
+use lib dirname $RealDir;
use make::common;
use constant {
diff --git a/make/common.pm b/make/common.pm
index 4d4cd397c..38b77e215 100644
--- a/make/common.pm
+++ b/make/common.pm
@@ -17,13 +17,9 @@
#
-BEGIN {
- require 5.10.0;
-}
-
package make::common;
-use feature ':5.10';
+use v5.10.0;
use strict;
use warnings FATAL => qw(all);
diff --git a/make/configure.pm b/make/configure.pm
index 001de5fc7..dcdcd0aca 100644
--- a/make/configure.pm
+++ b/make/configure.pm
@@ -21,13 +21,9 @@
#
-BEGIN {
- require 5.10.0;
-}
-
package make::configure;
-use feature ':5.10';
+use v5.10.0;
use strict;
use warnings FATAL => qw(all);
diff --git a/make/console.pm b/make/console.pm
index 33ce8f289..278c97d0f 100644
--- a/make/console.pm
+++ b/make/console.pm
@@ -19,11 +19,7 @@
package make::console;
-BEGIN {
- require 5.10.0;
-}
-
-use feature ':5.10';
+use v5.10.0;
use strict;
use warnings FATAL => qw(all);
diff --git a/make/directive.pm b/make/directive.pm
index 0c789ebf4..25e61160e 100644
--- a/make/directive.pm
+++ b/make/directive.pm
@@ -19,11 +19,7 @@
package make::directive;
-BEGIN {
- require 5.10.0;
-}
-
-use feature ':5.10';
+use v5.10.0;
use strict;
use warnings FATAL => qw(all);
diff --git a/make/unit-cc.pl b/make/unit-cc.pl
index 8006afe9b..f8991cb67 100755
--- a/make/unit-cc.pl
+++ b/make/unit-cc.pl
@@ -22,16 +22,15 @@
#
-BEGIN {
- push @INC, $ENV{SOURCEPATH};
- require 5.10.0;
-}
-
+use v5.10.0;
use strict;
use warnings FATAL => qw(all);
+use File::Basename qw(dirname);
use File::Spec::Functions qw(abs2rel);
+use FindBin qw($RealDir);
+use lib dirname $RealDir;
use make::console;
use make::directive;