$ssfx ||= "";
$dsfx ||= "";
- # We can output two kinds of rules: the "generic" rules use Make
- # suffix rules and are appropriate when $source and $dest do not lie
- # in a sub-directory; the "specific" rules are needed in the other
- # case.
+ # We can output two kinds of rules: the "generic" rules use pattern
+ # rules and are appropriate when $source and $dest do not lie in a
+ # sub-directory; the "specific" rules are needed in the other case.
#
# The former are output only once (this is not really apparent here,
# but just remember that some logic deeper in Automake will not
# if needed.)
$generic = 0 unless $insrc;
- # We cannot use a suffix rule to build info files with an empty
- # extension. Otherwise we would output a single suffix inference
- # rule, with separate dependencies, as in
- #
- # .texi:
- # $(MAKEINFO) ...
- # foo.info: foo.texi
- #
- # which confuse Solaris make. (See the Autoconf manual for
- # details.) Therefore we use a specific rule in this case. This
- # applies to info files only (dvi and pdf files always have an
- # extension).
- my $generic_info = ($generic && $dsfx) ? 1 : 0;
-
my $dipfx = ($insrc ? '$(srcdir)/' : '') . $dpfx;
$output_rules .= file_contents ('texibuild',
DEST_INFO_PREFIX => $dipfx,
DEST_SUFFIX => $dsfx,
GENERIC => $generic,
- GENERIC_INFO => $generic_info,
INSRC => $insrc,
MAKEINFOFLAGS => $makeinfoflags,
SOURCE => ($generic
? '$<' : $source),
- SOURCE_INFO => ($generic_info
- ? '$<' : $source),
SOURCE_REAL => $source,
SOURCE_SUFFIX => $ssfx,
TEXIQUIET => verbose_flag('texinfo'),
## You should have received a copy of the GNU General Public License
## along with this program. If not, see <http://www.gnu.org/licenses/>.
-?GENERIC_INFO?%%DEST_SUFFIX%: %%SOURCE_SUFFIX%
-?!GENERIC_INFO?%DEST_INFO_PREFIX%%DEST_SUFFIX%: %SOURCE_INFO% %DEPS%
+%%DEST_SUFFIX%: %%SOURCE_SUFFIX%
?!INSRC? @$(am__ensure_target_dir_exists)
## Back up the info files before running makeinfo. This is the cheapest
## way to ensure that
fi
## If we are using the generic rules, we need separate dependencies.
-if %?GENERIC_INFO%
%DEST_INFO_PREFIX%%DEST_SUFFIX%: %SOURCE_REAL% %DEPS%
-endif %?GENERIC_INFO%
if %?GENERIC%
%DEST_PREFIX%.dvi: %SOURCE_REAL% %DEPS%
%DEST_PREFIX%.pdf: %SOURCE_REAL% %DEPS%
END
cat > Makefile.am << 'END'
-info_TEXINFOS = textutils.texi
+info_TEXINFOS = textutils.texi doc/automake-ng.texi
+.PHONY: echo-info-deps
+echo-info-deps:
+ echo ' ' $(INFO_DEPS) ' '
END
cat > textutils.texi <<EOF
@bye
EOF
+mkdir doc
+cat > doc/automake-ng.texi <<EOF
+\input texinfo
+@setfilename automake-ng
+@settitle automake-ng
+@node Top
+Blurb.
+@bye
+EOF
+
$ACLOCAL
$AUTOCONF
$AUTOMAKE --add-missing
-grep '^INFO_DEPS.*textutils$' Makefile.in
-
-# We should not use single suffix inference rules (with separate
-# dependencies), this confuses Solaris make.
-grep '^\.texi:$' Makefile.in && Exit 1
-grep 'textutils: *textutils\.texi' Makefile.in
-
./configure
$MAKE distcheck
+$MAKE
+test -f textutils
+test -f doc/automake-ng
+test ! -f textutils.info
+test ! -f doc/automake-ng.info
+
+$MAKE distdir
+test -f $distdir/textutils
+test -f $distdir/doc/automake-ng
+
+$MAKE echo-info-deps | grep '[ /]textutils '
+$MAKE echo-info-deps | grep '[ /]doc/automake-ng '
+
: