summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Tromey <tromey@redhat.com>1997-09-28 23:18:35 +0000
committerTom Tromey <tromey@redhat.com>1997-09-28 23:18:35 +0000
commit5644b376ae1332c5e189096464ca3a1d6ff0fcf0 (patch)
treef8f672df393193c800c2cd9ce5456f865a8a73c7
parent38cf778f68a61f92986e37a379a42ebe7199f81a (diff)
downloadautomake-5644b376ae1332c5e189096464ca3a1d6ff0fcf0.tar.gz
added new options
-rw-r--r--ChangeLog8
-rw-r--r--TODO1
-rwxr-xr-xautomake.in53
-rw-r--r--automake.texi47
-rwxr-xr-xtests/cxxnoc.test2
5 files changed, 75 insertions, 36 deletions
diff --git a/ChangeLog b/ChangeLog
index b2cac0518..a3f80545d 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,13 @@
Sun Sep 28 15:55:46 1997 Tom Tromey <tromey@cygnus.com>
+ * automake.in (handle_minor_options): New sub.
+ (check_gnits_standards): Don't handle README-alpha here.
+ (handle_dist_worker): Check NEWS file if `check-news' option
+ requested.
+ (generate_makefile): Run handle_minor_options.
+ (handle_options): Handle readme-alpha and check-news. Set them if
+ --gnits.
+
* depend.am (MKDEP): Use $(CC), not gcc.
Wed Sep 24 23:48:26 1997 Tom Tromey <tromey@cygnus.com>
diff --git a/TODO b/TODO
index efe3d3032..f7df486b7 100644
--- a/TODO
+++ b/TODO
@@ -48,6 +48,7 @@
* cross-compilation support:
programs built and used by the build process need to be
built for CC_FOR_BUILD
+ introduce a new variable for this
* if foo.y is a source, foo.h isn't auto-distributed?
diff --git a/automake.in b/automake.in
index 1dff245b6..e4c639fe9 100755
--- a/automake.in
+++ b/automake.in
@@ -561,6 +561,7 @@ sub generate_makefile
&handle_clean;
&handle_phony;
+ &handle_minor_options;
&check_typos;
if (! -d ($output_directory . '/' . $am_relative_dir))
@@ -609,6 +610,12 @@ sub generate_makefile
# Handle AUTOMAKE_OPTIONS variable. Return 1 on error, 0 otherwise.
sub handle_options
{
+ if ($strictness == $GNITS)
+ {
+ $options{'readme-alpha'} = 1;
+ $options{'check-news'} = 1;
+ }
+
return 0 if ! &variable_defined ('AUTOMAKE_OPTIONS');
foreach (&variable_value_as_list ('AUTOMAKE_OPTIONS', ''))
@@ -628,7 +635,8 @@ sub handle_options
elsif ($_ eq 'no-installman' || $_ eq 'no-installinfo'
|| $_ eq 'dist-shar' || $_ eq 'dist-zip'
|| $_ eq 'dist-tarZ' || $_ eq 'dejagnu'
- || $_ eq 'no-texinfo.tex')
+ || $_ eq 'no-texinfo.tex'
+ || $_ eq 'readme-alpha' || $_ eq 'check-news')
{
# Explicitly recognize these.
}
@@ -2285,7 +2293,7 @@ sub handle_dist_worker
# Initialization; only at top level.
if ($relative_dir eq '.')
{
- if ($strictness >= $GNITS)
+ if (defined $options{'check-news'})
{
# For Gnits users, this is pretty handy. Look at 15 lines
# in case some explanatory text is desirable.
@@ -3803,6 +3811,30 @@ sub handle_emacs_lisp
}
}
+# Handle some of the minor options.
+sub handle_minor_options
+{
+ if (defined $options{'readme-alpha'})
+ {
+ if ($relative_dir eq '.')
+ {
+ if ($package_version !~ /^$GNITS_VERSION_PATTERN$/)
+ {
+ # FIXME: allow real filename.
+ &am_conf_line_error ('configure.in',
+ $package_version_line,
+ "version \`$package_version' doesn't follow Gnits standards");
+ }
+ elsif (defined $1 && -f 'README-alpha')
+ {
+ # This means we have an alpha release. See
+ # GNITS_VERSION_PATTERN for details.
+ &require_file ($FOREIGN, 'README-alpha');
+ }
+ }
+ }
+}
+
################################################################
# Scan one file for interesting things. Subroutine of scan_configure.
@@ -4239,23 +4271,6 @@ sub check_gnits_standards
{
&am_error ("\`${relative_dir}/COPYING.LIB' disallowed by Gnits standards");
}
-
- if ($relative_dir eq '.')
- {
- if ($package_version !~ /^$GNITS_VERSION_PATTERN$/)
- {
- # FIXME: allow real filename.
- &am_conf_line_error ('configure.in',
- $package_version_line,
- "version \`$package_version' doesn't follow Gnits standards");
- }
- elsif (defined $1 && -f 'README-alpha')
- {
- # This means we have an alpha release. See
- # GNITS_VERSION_PATTERN for details.
- &require_file ($GNITS, 'README-alpha');
- }
- }
}
if ($relative_dir eq '.')
diff --git a/automake.texi b/automake.texi
index 395428a6d..514267e85 100644
--- a/automake.texi
+++ b/automake.texi
@@ -2203,22 +2203,8 @@ Various features of Automake can be controlled by options in the
@item @code{gnits}
@itemx @code{gnu}
@itemx @code{foreign}
-Set the strictness as appropriate.
-
-@item @code{no-installman}
-The generated @file{Makefile.in} will not cause man pages to be
-installed by default. However, an @code{install-man} target will still
-be available for optional installation. This option is disallowed at
-@samp{GNU} strictness and above.
-@trindex install-man
-
-@item @code{no-installinfo}
-The generated @file{Makefile.in} will not cause info pages to be built
-or installed by default. However, @code{info} and @code{install-info}
-targets will still be available. This option is disallowed at
-@samp{GNU} strictness and above.
-@trindex info
-@trindex install-info
+Set the strictness as appropriate. The @code{gnits} option also implies
+@code{readme-alpha} and @code{check-news}.
@item @code{ansi2knr}
@itemx @code{path/ansi2knr}
@@ -2228,6 +2214,10 @@ directory to find the @file{ansi2knr} program. Generally the path
should be a relative path to another directory in the same distribution
(though Automake currently does not check this).
+@item @code{check-news}
+Cause @code{make dist} to fail unless the current version number appears
+in the first few lines of the @file{NEWS} file.
+
@item @code{dejagnu}
Cause @code{dejagnu}-specific rules to be generated. @xref{Tests}.
@@ -2256,10 +2246,35 @@ is useful for those situations where you don't have the necessary bits
to make automatic dependency tracking work @xref{Dependencies}. In this
case the effect is to effectively disable automatic dependency tracking.
+@item @code{no-installinfo}
+The generated @file{Makefile.in} will not cause info pages to be built
+or installed by default. However, @code{info} and @code{install-info}
+targets will still be available. This option is disallowed at
+@samp{GNU} strictness and above.
+@trindex info
+@trindex install-info
+
+@item @code{no-installman}
+The generated @file{Makefile.in} will not cause man pages to be
+installed by default. However, an @code{install-man} target will still
+be available for optional installation. This option is disallowed at
+@samp{GNU} strictness and above.
+@trindex install-man
+
@item @code{no-texinfo.tex}
Don't require @file{texinfo.tex}, even if there are texinfo files in
this directory.
+@item @code{readme-alpha}
+If this release is an alpha release, and the file @file{README-alpha}
+exists, then it will be added to the distribution. If this option is
+given, version numbers are expected to follow one of two forms. The
+first form is @samp{@var{MAJOR}.@var{MINOR}.@var{ALPHA}}, where each
+element is a number; the final period and number should be left off for
+non-alpha releases. The second form is
+@samp{@var{MAJOR}.@var{MINOR}@var{ALPHA}}, where @var{ALPHA} is a
+letter; it should be omitted for non-alpha releases.
+
@item @var{version}
A version number (eg @samp{0.30}) can be specified. If Automake is not
newer than the version specified, creation of the @file{Makefile.in}
diff --git a/tests/cxxnoc.test b/tests/cxxnoc.test
index a4f5b0091..558040d27 100755
--- a/tests/cxxnoc.test
+++ b/tests/cxxnoc.test
@@ -18,5 +18,5 @@ END
$AUTOMAKE || exit 1
-grep CC Makefile.in && exit 1
+grep CC Makefile.in | grep -v MKDEP && exit 1
exit 0