From: Ralf Wildenhues Date: Sat, 22 Nov 2008 10:46:39 +0000 (+0100) Subject: When installing COPYING, recommend adding the file to VCS. X-Git-Tag: v1.10b~57 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=4c23b9a9810d05b5ac4369a55c840b20fb77649b;p=thirdparty%2Fautomake.git When installing COPYING, recommend adding the file to VCS. * automake.in (require_file_internal): If installing `COPYING', mention that we install the GPLv3 file and recommend adding the file to version control. * doc/automake.texi (Invoking Automake): Point to `Gnits' node for `--add-missing'. (Gnits): Clarify semantics: that for strictness gnu or higher, INSTALL is installed, and that COPYING is installed as GPLv3 if no COPYING file exists. * tests/license2.test: New test. * tests/Makefile.am: Update. * NEWS, THANKS: Update. Report by Brian Cameron. Signed-off-by: Ralf Wildenhues --- diff --git a/ChangeLog b/ChangeLog index 06ffd167b..2548528ec 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,19 @@ +2008-11-22 Ralf Wildenhues + + When installing COPYING, recommend adding the file to VCS. + * automake.in (require_file_internal): If installing `COPYING', + mention that we install the GPLv3 file and recommend adding the + file to version control. + * doc/automake.texi (Invoking Automake): Point to `Gnits' node + for `--add-missing'. + (Gnits): Clarify semantics: that for strictness gnu or higher, + INSTALL is installed, and that COPYING is installed as GPLv3 + if no COPYING file exists. + * tests/license2.test: New test. + * tests/Makefile.am: Update. + * NEWS, THANKS: Update. + Report by Brian Cameron. + 2008-11-20 William Pursell * doc/automake.texi (Timeline): Fix typos and grammaros. diff --git a/NEWS b/NEWS index 7ccc3e140..50a0a77d7 100644 --- a/NEWS +++ b/NEWS @@ -57,8 +57,9 @@ New in 1.10a: - Automake is licensed under GPLv3+. `automake --add-missing' will by default install the GPLv3 file as COPYING if it is missing. - Note that Automake will never overwrite an existing COPYING file, - even when the `--force-missing' option is used. + It will also warn that the license file should be added to source + control. Note that Automake will never overwrite an existing COPYING + file, even when the `--force-missing' option is used. - The manual is now distributed under the terms of the GNU FDL 1.3. diff --git a/THANKS b/THANKS index 526dd47f8..55ec6dfa9 100644 --- a/THANKS +++ b/THANKS @@ -43,6 +43,7 @@ Bob Rossi bob@brasko.net Bobby Jack bobbykjack@yahoo.co.uk Braden N. McDaniel braden@endoframe.com Brendan O'Dea bod@compusol.com.au +Brian Cameron Brian.Cameron@Sun.COM Brian Ford ford@vss.fsi.com Brian Gough bjg@network-theory.co.uk Brian Jones cbj@nortel.net diff --git a/automake.in b/automake.in index 66633dfca..ac1c8c2ef 100755 --- a/automake.in +++ b/automake.in @@ -7380,6 +7380,7 @@ sub require_file_internal ($$$@) } my $trailer = ''; + my $trailer2 = ''; my $suppress = 0; # Only install missing files according to our desired @@ -7395,6 +7396,17 @@ sub require_file_internal ($$$@) # can, copy if we must. Note: delete the file # first, in case it is a dangling symlink. $message = "installing `$fullfile'"; + + # The license file should not be volatile. + if ($file eq "COPYING") + { + $message .= " using GNU General Public License v3 file"; + $trailer2 = "\n Consider adding the COPYING file" + . " to the version control system" + . "\n for your code, to avoid questions" + . " about which license your project uses."; + } + # Windows Perl will hang if we try to delete a # file that doesn't exist. unlink ($fullfile) if -f $fullfile; @@ -7447,7 +7459,7 @@ sub require_file_internal ($$$@) next if !$suppress && rule $file; - msg ($suppress ? 'note' : 'error', $where, "$message$trailer"); + msg ($suppress ? 'note' : 'error', $where, "$message$trailer$trailer2"); } } } diff --git a/doc/automake.texi b/doc/automake.texi index 3d12c61dc..2fe3adbaa 100644 --- a/doc/automake.texi +++ b/doc/automake.texi @@ -2438,6 +2438,9 @@ Therefore, @code{AC_CONFIG_AUX_DIR}'s setting affects whether a file is considered missing, and where the missing file is added (@pxref{Optional}). +In some strictness modes, additional files are installed, see @ref{Gnits} +for more information. + @item --libdir=@var{dir} @opindex --libdir Look for Automake data files in directory @var{dir} instead of in the @@ -9152,6 +9155,14 @@ The files @file{INSTALL}, @file{NEWS}, @file{README}, @file{AUTHORS}, and @file{ChangeLog}, plus one of @file{COPYING.LIB}, @file{COPYING.LESSER} or @file{COPYING}, are required at the topmost directory of the package. +If the @option{--add-missing} option is given, @command{automake} will +add a generic version of the @file{INSTALL} file as well as the +@file{COPYING} file containing the text of the current version of the +GNU General Public License existing at the time of this Automake release +(version 3 as this is written, @uref{http://www.gnu.org/@/copyleft/@/gpl.html}). +However, an existing @file{COPYING} file will never be overwritten by +@command{automake}. + @item The options @option{no-installman} and @option{no-installinfo} are prohibited. diff --git a/tests/Makefile.am b/tests/Makefile.am index 023e1f73a..46fe0d510 100644 --- a/tests/Makefile.am +++ b/tests/Makefile.am @@ -359,6 +359,7 @@ libtool9.test \ libtoo10.test \ libtoo11.test \ license.test \ +license2.test \ link_c_cxx.test \ link_dist.test \ link_f90_only.test \ diff --git a/tests/Makefile.in b/tests/Makefile.in index 4207f6c42..57451a2fe 100644 --- a/tests/Makefile.in +++ b/tests/Makefile.in @@ -512,6 +512,7 @@ libtool9.test \ libtoo10.test \ libtoo11.test \ license.test \ +license2.test \ link_c_cxx.test \ link_dist.test \ link_f90_only.test \ diff --git a/tests/license2.test b/tests/license2.test new file mode 100755 index 000000000..f16ed00c7 --- /dev/null +++ b/tests/license2.test @@ -0,0 +1,41 @@ +#! /bin/sh +# Copyright (C) 2008 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, 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 . + +# Check that installing `COPYING' outputs a warning. + +. ./defs || Exit 1 + +set -e + +cat > Makefile.am << 'END' +AUTOMAKE_OPTIONS = gnu +END + +: >AUTHORS +: >NEWS +: >README +: >ChangeLog +: >INSTALL + +$ACLOCAL +AUTOMAKE_fails +grep 'COPYING' stderr + +AUTOMAKE_run 0 --add-missing +grep 'COPYING' stderr +grep 'GNU General Public License' stderr +grep 'Consider adding.*version control' stderr +test -f COPYING