From: Bruno Haible <bruno@clisp.org>
To: Paul Eggert <eggert@cs.ucla.edu>
Cc: "Eric Blake" <eblake@redhat.com>,
"Tim Rühsen" <tim.ruehsen@gmx.de>,
bug-gnulib@gnu.org
Subject: Re: Alpine: useless-if-before-free: Exec format error
Date: Wed, 19 Jun 2019 12:10:17 +0200 [thread overview]
Message-ID: <15019651.RDuQAadGsn@omega> (raw)
In-Reply-To: <7b2e3c71-e274-bd2a-5534-e1fc4289db92@cs.ucla.edu>
Paul Eggert wrote:
> > Prologue part 1 (2 lines with #!)
> > Program short description
> > Copyright and license notice
> > Written-by notice
> > Program short description (optional)
> > Program long description
> > Prologue part 2
> > Time stamp
> > Code
> >
> > Would that be OK with you?
>
> Yes, that sounds OK, thanks.
Done like this:
2019-06-19 Bruno Haible <bruno@clisp.org>
Reorder pieces of header in perl scripts.
The desired order is
- Prologue part 1 (2 lines with #!)
- Program short description
- Copyright and license notice
- Written-by notice
- Program short description (optional)
- Program long description (optional)
- Prologue part 2
- Time stamp
- Code
Reported by Paul Eggert.
* build-aux/announce-gen: Reorder header.
* build-aux/gitlog-to-changelog: Likewise.
* build-aux/useless-if-before-free: Likewise.
* build-aux/prefix-gnulib-mk: Add copyright notice and short
description.
* build-aux/update-copyright: Likewise. Add short description. Bump
time-stamp-line-limit to 200.
diff --git a/build-aux/announce-gen b/build-aux/announce-gen
index 5921dcc..8fe0cc8 100755
--- a/build-aux/announce-gen
+++ b/build-aux/announce-gen
@@ -1,5 +1,25 @@
#!/bin/sh
#! -*-perl-*-
+
+# Generate a release announcement message.
+
+# Copyright (C) 2002-2019 Free Software Foundation, Inc.
+#
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <https://www.gnu.org/licenses/>.
+#
+# Written by Jim Meyering
+
# This is a prologue that allows to run a perl script as an executable
# on systems that are compliant to a POSIX version before POSIX:2017.
# On such systems, the usual invocation of an executable through execlp()
@@ -15,33 +35,13 @@
eval 'exec perl -wSx "$0" "$@"'
if 0;
-# Generate a release announcement message.
-
my $VERSION = '2018-03-07 03:46'; # UTC
# The definition above must lie within the first 8 lines in order
# for the Emacs time-stamp write hook (at end) to update it.
# If you change this file with Emacs, please let the write hook
# do its job. Otherwise, update this string manually.
-# Copyright (C) 2002-2019 Free Software Foundation, Inc.
-
-# This program is free software: you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation, either version 3 of the License, or
-# (at your option) any later version.
-
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-
-# You should have received a copy of the GNU General Public License
-# along with this program. If not, see <https://www.gnu.org/licenses/>.
-
-# Written by Jim Meyering
-
use strict;
-
use Getopt::Long;
use POSIX qw(strftime);
diff --git a/build-aux/gitlog-to-changelog b/build-aux/gitlog-to-changelog
index 40b839e..3acfa8b 100755
--- a/build-aux/gitlog-to-changelog
+++ b/build-aux/gitlog-to-changelog
@@ -1,5 +1,25 @@
#!/bin/sh
#! -*-perl-*-
+
+# Convert git log output to ChangeLog format.
+
+# Copyright (C) 2008-2019 Free Software Foundation, Inc.
+#
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <https://www.gnu.org/licenses/>.
+#
+# Written by Jim Meyering
+
# This is a prologue that allows to run a perl script as an executable
# on systems that are compliant to a POSIX version before POSIX:2017.
# On such systems, the usual invocation of an executable through execlp()
@@ -15,31 +35,12 @@
eval 'exec perl -wSx "$0" "$@"'
if 0;
-# Convert git log output to ChangeLog format.
-
my $VERSION = '2018-03-07 03:47'; # UTC
# The definition above must lie within the first 8 lines in order
# for the Emacs time-stamp write hook (at end) to update it.
# If you change this file with Emacs, please let the write hook
# do its job. Otherwise, update this string manually.
-# Copyright (C) 2008-2019 Free Software Foundation, Inc.
-
-# This program is free software: you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation, either version 3 of the License, or
-# (at your option) any later version.
-
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-
-# You should have received a copy of the GNU General Public License
-# along with this program. If not, see <https://www.gnu.org/licenses/>.
-
-# Written by Jim Meyering
-
use strict;
use warnings;
use Getopt::Long;
diff --git a/build-aux/prefix-gnulib-mk b/build-aux/prefix-gnulib-mk
index f3ca725..445d916 100755
--- a/build-aux/prefix-gnulib-mk
+++ b/build-aux/prefix-gnulib-mk
@@ -1,5 +1,25 @@
#!/bin/sh
#! -*-perl-*-
+
+# Rewrite a gnulib.mk, adding prefixes to work with automake's subdir-objects.
+
+# Copyright (C) 2012-2019 Free Software Foundation, Inc.
+#
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <https://www.gnu.org/licenses/>.
+#
+# Written by Jim Meyering
+
# This is a prologue that allows to run a perl script as an executable
# on systems that are compliant to a POSIX version before POSIX:2017.
# On such systems, the usual invocation of an executable through execlp()
@@ -15,12 +35,17 @@
eval 'exec perl -wSx "$0" "$@"'
if 0;
+my $VERSION = '2012-01-21 17:13'; # UTC
+# The definition above must lie within the first 8 lines in order
+# for the Emacs time-stamp write hook (at end) to update it.
+# If you change this file with Emacs, please let the write hook
+# do its job. Otherwise, update this string manually.
+
use strict;
use IO::File;
use Getopt::Long;
use File::Basename; # for dirname
-my $VERSION = '2012-01-21 17:13'; # UTC
(my $ME = $0) =~ s|.*/||;
my $prefix;
diff --git a/build-aux/update-copyright b/build-aux/update-copyright
index 0bb482b..4a9ea7c 100755
--- a/build-aux/update-copyright
+++ b/build-aux/update-copyright
@@ -1,24 +1,8 @@
#!/bin/sh
#! -*-perl-*-
-# This is a prologue that allows to run a perl script as an executable
-# on systems that are compliant to a POSIX version before POSIX:2017.
-# On such systems, the usual invocation of an executable through execlp()
-# or execvp() fails with ENOEXEC if it is a script that does not start
-# with a #! line. The script interpreter mentioned in the #! line has
-# to be /bin/sh, because on GuixSD systems that is the only program that
-# has a fixed file name. The second line is essential for perl and is
-# also useful for editing this file in Emacs. The next two lines below
-# are valid code in both sh and perl. When executed by sh, they re-execute
-# the script through the perl program found in $PATH. The '-x' option
-# is essential as well; without it, perl would re-execute the script
-# through /bin/sh. When executed by perl, the next two lines are a no-op.
-eval 'exec perl -wSx "$0" "$@"'
- if 0;
# Update an FSF copyright year list to include the current year.
-my $VERSION = '2018-03-07.03:47'; # UTC
-
# Copyright (C) 2009-2019 Free Software Foundation, Inc.
#
# This program is free software: you can redistribute it and/or modify
@@ -33,9 +17,12 @@ my $VERSION = '2018-03-07.03:47'; # UTC
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <https://www.gnu.org/licenses/>.
-
+#
# Written by Jim Meyering and Joel E. Denny
+# This script updates an FSF copyright year list to include the current year.
+# Usage: update-copyright [FILE...]
+#
# The arguments to this script should be names of files that contain
# copyright statements to be updated. The copyright holder's name
# defaults to "Free Software Foundation, Inc." but may be changed to
@@ -135,6 +122,27 @@ my $VERSION = '2018-03-07.03:47'; # UTC
# 5. Set UPDATE_COPYRIGHT_HOLDER if the copyright holder is other
# than "Free Software Foundation, Inc.".
+# This is a prologue that allows to run a perl script as an executable
+# on systems that are compliant to a POSIX version before POSIX:2017.
+# On such systems, the usual invocation of an executable through execlp()
+# or execvp() fails with ENOEXEC if it is a script that does not start
+# with a #! line. The script interpreter mentioned in the #! line has
+# to be /bin/sh, because on GuixSD systems that is the only program that
+# has a fixed file name. The second line is essential for perl and is
+# also useful for editing this file in Emacs. The next two lines below
+# are valid code in both sh and perl. When executed by sh, they re-execute
+# the script through the perl program found in $PATH. The '-x' option
+# is essential as well; without it, perl would re-execute the script
+# through /bin/sh. When executed by perl, the next two lines are a no-op.
+eval 'exec perl -wSx "$0" "$@"'
+ if 0;
+
+my $VERSION = '2018-03-07.03:47'; # UTC
+# The definition above must lie within the first 8 lines in order
+# for the Emacs time-stamp write hook (at end) to update it.
+# If you change this file with Emacs, please let the write hook
+# do its job. Otherwise, update this string manually.
+
use strict;
use warnings;
@@ -284,7 +292,7 @@ else
# mode: perl
# indent-tabs-mode: nil
# eval: (add-hook 'before-save-hook 'time-stamp)
-# time-stamp-line-limit: 50
+# time-stamp-line-limit: 200
# time-stamp-start: "my $VERSION = '"
# time-stamp-format: "%:y-%02m-%02d.%02H:%02M"
# time-stamp-time-zone: "UTC0"
diff --git a/build-aux/useless-if-before-free b/build-aux/useless-if-before-free
index 0e479a3..6ac8aa9 100755
--- a/build-aux/useless-if-before-free
+++ b/build-aux/useless-if-before-free
@@ -1,5 +1,26 @@
#!/bin/sh
#! -*-perl-*-
+
+# Detect instances of "if (p) free (p);".
+# Likewise "if (p != 0)", "if (0 != p)", or with NULL; and with braces.
+
+# Copyright (C) 2008-2019 Free Software Foundation, Inc.
+#
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <https://www.gnu.org/licenses/>.
+#
+# Written by Jim Meyering
+
# This is a prologue that allows to run a perl script as an executable
# on systems that are compliant to a POSIX version before POSIX:2017.
# On such systems, the usual invocation of an executable through execlp()
@@ -15,32 +36,12 @@
eval 'exec perl -wSx "$0" "$@"'
if 0;
-# Detect instances of "if (p) free (p);".
-# Likewise "if (p != 0)", "if (0 != p)", or with NULL; and with braces.
-
my $VERSION = '2018-03-07 03:47'; # UTC
# The definition above must lie within the first 8 lines in order
# for the Emacs time-stamp write hook (at end) to update it.
# If you change this file with Emacs, please let the write hook
# do its job. Otherwise, update this string manually.
-# Copyright (C) 2008-2019 Free Software Foundation, Inc.
-
-# This program is free software: you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation, either version 3 of the License, or
-# (at your option) any later version.
-
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-
-# You should have received a copy of the GNU General Public License
-# along with this program. If not, see <https://www.gnu.org/licenses/>.
-
-# Written by Jim Meyering
-
use strict;
use warnings;
use Getopt::Long;
next prev parent reply other threads:[~2019-06-19 10:11 UTC|newest]
Thread overview: 30+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-06-14 17:04 Alpine: useless-if-before-free: Exec format error Tim Rühsen
2019-06-14 17:50 ` Paul Eggert
2019-06-14 19:47 ` Tim Rühsen
2019-06-14 21:28 ` Bruno Haible
2019-06-14 21:47 ` Eric Blake
2019-06-14 23:17 ` Bruno Haible
2019-06-14 23:51 ` Bruno Haible
2019-06-15 0:47 ` Paul Eggert
2019-06-15 2:03 ` Bruno Haible
2019-06-15 7:23 ` Paul Eggert
2019-06-15 11:06 ` Bruno Haible
2019-06-15 11:25 ` Darshit Shah
2019-06-15 12:01 ` Emacs time stamp hook Bruno Haible
2019-06-15 13:39 ` Darshit Shah
2019-06-15 15:25 ` Bruno Haible
2019-06-15 18:35 ` Paul Eggert
2019-06-15 19:48 ` Bruno Haible
2019-06-16 0:30 ` Jim Meyering
2019-06-16 12:57 ` Bruno Haible
2019-06-15 18:35 ` Alpine: useless-if-before-free: Exec format error Paul Eggert
2019-06-15 20:14 ` Bruno Haible
2019-06-15 23:17 ` Paul Eggert
2019-06-16 13:12 ` Bruno Haible
2019-06-18 0:51 ` Paul Eggert
2019-06-18 1:32 ` Bruno Haible
2019-06-18 2:30 ` Paul Eggert
2019-06-19 10:10 ` Bruno Haible [this message]
2019-06-23 16:32 ` Jim Meyering
2019-06-24 8:06 ` Tim Rühsen
2019-06-15 10:41 ` Bruno Haible
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://lists.gnu.org/mailman/listinfo/bug-gnulib
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=15019651.RDuQAadGsn@omega \
--to=bruno@clisp.org \
--cc=bug-gnulib@gnu.org \
--cc=eblake@redhat.com \
--cc=eggert@cs.ucla.edu \
--cc=tim.ruehsen@gmx.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).