Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame^] | 1 | From 081385f4d4bba367afad3bff1fa034f5263305e6 Mon Sep 17 00:00:00 2001 |
Brad Bishop | 6e60e8b | 2018-02-01 10:27:11 -0500 | [diff] [blame] | 2 | From: Serhii Popovych <spopovyc@cisco.com> |
| 3 | Date: Wed, 10 Feb 2016 17:07:32 +0000 |
| 4 | Subject: [PATCH] perl: Replace -w option in shebangs with modern "use |
| 5 | warnings" In some builds we might provide ac_cv_path_PERL as /usr/bin/env |
| 6 | perl to use newer version of the perl from users PATH rather than older from |
| 7 | standard system path. |
| 8 | |
| 9 | However using /usr/bin/env perl -w from shebang line isn't |
| 10 | possible because it translates to something like |
| 11 | /usr/bin/env -w perl and env complains about illegal option. |
| 12 | |
| 13 | To address this we can remove -w option from perl shebang |
| 14 | line and add "use warnings" statement. |
| 15 | |
| 16 | Upstream-Status: Pending |
| 17 | Signed-off-by: Serhii Popovych <spopovyc@cisco.com> |
Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame^] | 18 | Signed-off-by: Robert Yang <liezhi.yang@windriver.com> |
Brad Bishop | 6e60e8b | 2018-02-01 10:27:11 -0500 | [diff] [blame] | 19 | |
Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame^] | 20 | --- |
| 21 | bin/aclocal.in | 3 ++- |
| 22 | bin/automake.in | 3 ++- |
| 23 | 2 files changed, 4 insertions(+), 2 deletions(-) |
| 24 | |
| 25 | diff --git a/bin/aclocal.in b/bin/aclocal.in |
| 26 | index b3715d9..461d453 100644 |
| 27 | --- a/bin/aclocal.in |
| 28 | +++ b/bin/aclocal.in |
Brad Bishop | 6e60e8b | 2018-02-01 10:27:11 -0500 | [diff] [blame] | 29 | @@ -1,4 +1,4 @@ |
| 30 | -#!@PERL@ -w |
| 31 | +#!@PERL@ |
| 32 | # -*- perl -*- |
| 33 | # @configure_input@ |
| 34 | |
Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame^] | 35 | @@ -32,6 +32,7 @@ BEGIN |
Brad Bishop | 6e60e8b | 2018-02-01 10:27:11 -0500 | [diff] [blame] | 36 | } |
| 37 | |
| 38 | use strict; |
| 39 | +use warnings; |
| 40 | |
| 41 | use Automake::Config; |
| 42 | use Automake::General; |
Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame^] | 43 | diff --git a/bin/automake.in b/bin/automake.in |
| 44 | index 8377d20..3a66965 100644 |
| 45 | --- a/bin/automake.in |
| 46 | +++ b/bin/automake.in |
Brad Bishop | 6e60e8b | 2018-02-01 10:27:11 -0500 | [diff] [blame] | 47 | @@ -1,4 +1,4 @@ |
| 48 | -#!@PERL@ -w |
| 49 | +#!@PERL@ |
| 50 | # -*- perl -*- |
| 51 | # @configure_input@ |
| 52 | |
Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame^] | 53 | @@ -28,6 +28,7 @@ eval 'case $# in 0) exec @PERL@ -S "$0";; *) exec @PERL@ -S "$0" "$@";; esac' |
Brad Bishop | 6e60e8b | 2018-02-01 10:27:11 -0500 | [diff] [blame] | 54 | package Automake; |
| 55 | |
| 56 | use strict; |
| 57 | +use warnings; |
| 58 | |
| 59 | BEGIN |
| 60 | { |