]> git.ipfire.org Git - thirdparty/automake.git/commitdiff
dist: don't bother putting README first in $(DIST_COMMON)
authorStefano Lattarini <stefano.lattarini@gmail.com>
Thu, 3 May 2012 15:30:56 +0000 (17:30 +0200)
committerStefano Lattarini <stefano.lattarini@gmail.com>
Thu, 3 May 2012 18:29:36 +0000 (20:29 +0200)
Comments on some of our automake-time pre-processing of $(DIST_COMMON)
said that it was done in order to "put README first because it then
becomes easier to make a Usenet-compliant shar file".  But such a
format is hardly relevant anymore, and not worth the (albeit small)
added complexity.

* automake.in (handle_dist): Don't sort @dist_common.
(for_dist_common): Delete this function, is not used anymore.
* lib/am/distdir.am (DISTFILES): Remove obsolete comment.
* t/distcom4.sh: Adjust.

Signed-off-by: Stefano Lattarini <stefano.lattarini@gmail.com>
automake.in
lib/am/distdir.am
t/distcom4.sh

index 555aadba4d06be2880edb3d2d7242b93a2c4d3a8..72ca9562a4f8adfc7df71c168117693175dc1649 100644 (file)
@@ -3696,26 +3696,6 @@ sub user_phony_rule ($)
 }
 
 
-# $BOOLEAN
-# &for_dist_common ($A, $B)
-# -------------------------
-# Subroutine for &handle_dist: sort files to dist.
-#
-# We put README first because it then becomes easier to make a
-# Usenet-compliant shar file (in these, README must be first).
-#
-# FIXME: do more ordering of files here.
-sub for_dist_common
-{
-    return 0
-       if $a eq $b;
-    return -1
-       if $a eq 'README';
-    return 1
-       if $b eq 'README';
-    return $a cmp $b;
-}
-
 # handle_dist
 # -----------
 # Handle 'dist' target.
@@ -3826,7 +3806,7 @@ sub handle_dist ()
   # Files to distributed.  Don't use ->value_as_list_recursive
   # as it recursively expands '$(dist_pkgdata_DATA)' etc.
   my @dist_common = split (' ', rvar ('DIST_COMMON')->variable_value);
-  @dist_common = uniq (sort for_dist_common (@dist_common));
+  @dist_common = uniq @dist_common;
   variable_delete 'DIST_COMMON';
   define_pretty_variable ('DIST_COMMON', TRUE, INTERNAL, @dist_common);
 
index e27b6504d82e9f4b450f344f5e5620a8f77eaf7b..3a5e1a5317c1114d30e4f16668dbe96122db3f92 100644 (file)
@@ -14,7 +14,6 @@
 ## You should have received a copy of the GNU General Public License
 ## along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
-## DIST_COMMON comes first so that README can be the very first file.
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 
 if %?TOPDIR_P%
index dc37fcf4f62a6e01bde0f9e35f42c8510898251e..6f9d8716c974ad3e54b2c5d5e055dd7337cb9fac 100755 (executable)
@@ -18,7 +18,6 @@
 # This tries to distribute a file from a subdirectory, without
 # Makefile in that directory.  distcom5.test performs the same
 # test with a Makefile in the directory.
-# Also make sure that README appears first in DIST_COMMON.
 
 . ./defs || Exit 1
 
@@ -71,7 +70,5 @@ cat dc.txt # For debugging.
 
 test 1 = `grep tests dc.txt | wc -l`
 grep configure dc.txt
-# README must come first.
-grep 'DIST_COMMON = README' Makefile.in
 
 :