From 50a1f70efb89a6b393758860373eadd1e63b77f5 Mon Sep 17 00:00:00 2001 From: amalec Date: Thu, 31 May 2001 22:26:35 +0000 Subject: [PATCH] Added Automake support to create and install documentation git-svn-id: svn+ssh://svn.code.sf.net/p/check/code/trunk@17 64e312b2-a51f-0410-8e61-82d0ca0eb02a --- check/ChangeLog | 9 ++++++ check/Makefile.am | 2 +- check/Makefile.in | 17 ++++++---- check/aclocal.m4 | 1 + check/configure | 6 ++-- check/configure.in | 3 +- check/doc/Makefile.am | 45 +++++++++++++++++++++++++++ check/src/Makefile.in | 66 +++++++++++++++++++++++++++++---------- check/tests/Makefile.in | 69 ++++++++++++++++++++++++++++++----------- 9 files changed, 173 insertions(+), 45 deletions(-) create mode 100644 check/doc/Makefile.am diff --git a/check/ChangeLog b/check/ChangeLog index d302d29..5355bf2 100644 --- a/check/ChangeLog +++ b/check/ChangeLog @@ -1,3 +1,12 @@ +2001-05-31 14:30 amalec + + * doc/money/: config.h, config.log, config.status: Removed unneded + files + +2001-05-31 08:37 amalec + + * ChangeLog, ChangeLogOld: Updated change logs + 2001-05-31 08:35 amalec * doc/example.lyx: Commit changes to example, get things in synch diff --git a/check/Makefile.am b/check/Makefile.am index c6b8cc9..b62b925 100644 --- a/check/Makefile.am +++ b/check/Makefile.am @@ -1,3 +1,3 @@ -SUBDIRS=src tests +SUBDIRS=src tests doc CLEANFILES=*.*~ \ No newline at end of file diff --git a/check/Makefile.in b/check/Makefile.in index d673d8e..f49e2f4 100644 --- a/check/Makefile.in +++ b/check/Makefile.in @@ -65,7 +65,7 @@ PACKAGE = @PACKAGE@ RANLIB = @RANLIB@ VERSION = @VERSION@ -SUBDIRS = src tests +SUBDIRS = src tests doc CLEANFILES = *.*~ ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 @@ -73,8 +73,8 @@ mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs CONFIG_HEADER = config.h CONFIG_CLEAN_FILES = DIST_COMMON = README ./stamp-h.in AUTHORS COPYING ChangeLog INSTALL \ -Makefile.am Makefile.in NEWS aclocal.m4 config.h.in configure \ -configure.in install-sh missing mkinstalldirs +Makefile.am Makefile.in NEWS acinclude.m4 aclocal.m4 config.h.in \ +configure configure.in install-sh missing mkinstalldirs DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST) @@ -84,13 +84,13 @@ GZIP_ENV = --best all: all-redirect .SUFFIXES: $(srcdir)/Makefile.in: Makefile.am $(top_srcdir)/configure.in $(ACLOCAL_M4) - cd $(top_srcdir) && $(AUTOMAKE) --gnu --include-deps Makefile + cd $(top_srcdir) && $(AUTOMAKE) --gnu Makefile -Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status $(BUILT_SOURCES) cd $(top_builddir) \ && CONFIG_FILES=$@ CONFIG_HEADERS= $(SHELL) ./config.status -$(ACLOCAL_M4): configure.in +$(ACLOCAL_M4): configure.in acinclude.m4 cd $(srcdir) && $(ACLOCAL) config.status: $(srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) @@ -253,6 +253,11 @@ distdir: $(DISTFILES) -rm -rf $(distdir) mkdir $(distdir) -chmod 777 $(distdir) + here=`cd $(top_builddir) && pwd`; \ + top_distdir=`cd $(distdir) && pwd`; \ + distdir=`cd $(distdir) && pwd`; \ + cd $(top_srcdir) \ + && $(AUTOMAKE) --include-deps --build-dir=$$here --srcdir-name=$(top_srcdir) --output-dir=$$top_distdir --gnu Makefile @for file in $(DISTFILES); do \ d=$(srcdir); \ if test -d $$d/$$file; then \ diff --git a/check/aclocal.m4 b/check/aclocal.m4 index f23ba29..85b52e9 100644 --- a/check/aclocal.m4 +++ b/check/aclocal.m4 @@ -10,6 +10,7 @@ dnl but WITHOUT ANY WARRANTY, to the extent permitted by law; without dnl even the implied warranty of MERCHANTABILITY or FITNESS FOR A dnl PARTICULAR PURPOSE. + # Do all the work for Automake. This macro actually does too much -- # some checks are only needed if your package does certain things. # But this isn't really a big deal. diff --git a/check/configure b/check/configure index c5725cc..0434364 100755 --- a/check/configure +++ b/check/configure @@ -1823,7 +1823,8 @@ ac_given_INSTALL="$INSTALL" trap 'rm -fr `echo "Makefile src/Makefile - tests/Makefile config.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15 + tests/Makefile + doc/Makefile config.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15 EOF cat >> $CONFIG_STATUS <> $CONFIG_STATUS <> $CONFIG_STATUS <<\EOF for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then diff --git a/check/configure.in b/check/configure.in index 0042446..a1c58c2 100644 --- a/check/configure.in +++ b/check/configure.in @@ -28,4 +28,5 @@ AC_CHECK_FUNCS(strerror) AC_OUTPUT(Makefile src/Makefile - tests/Makefile) + tests/Makefile + doc/Makefile) diff --git a/check/doc/Makefile.am b/check/doc/Makefile.am new file mode 100644 index 0000000..3e017e1 --- /dev/null +++ b/check/doc/Makefile.am @@ -0,0 +1,45 @@ +DOCROOTDIR= $(prefix)/doc/$(PACKAGE)-$(VERSION) +# Fake out automake to make the money subdirectory... +afakedir = $(DOCROOTDIR)/money +docdir = $(DOCROOTDIR) + +SUFFIXES = .sgml +%.sgml: %.lyx + lyx -e linuxdoc $< + +%.html : %.sgml + sgml2html --split=1 $< + +sgml_docs = example.sgml +html_docs =\ + example.html\ + example-1.html\ + example-2.html\ + example-3.html\ + example-4.html\ + example-5.html + +example_docs =\ + money\ + money/aclocal.m4\ + money/check_money.c\ + money/configure.in\ + money/INSTALL\ + money/money.c\ + money/README\ + money/AUTHORS\ + money/config.h.in\ + money/COPYING\ + money/Makefile.am\ + money/money.h\ + money/stamp-h.in\ + money/ChangeLog\ + money/configure\ + money/Makefile.in\ + money/NEWS + +afake_DATA = + +doc_DATA = example.lyx $(sgml_docs) $(html_docs) $(example_docs) + +CLEANFILES = $(sgml_docs) $(html_docs) *.*~ \ No newline at end of file diff --git a/check/src/Makefile.in b/check/src/Makefile.in index e17bdb9..5769360 100644 --- a/check/src/Makefile.in +++ b/check/src/Makefile.in @@ -99,6 +99,8 @@ DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST) TAR = gtar GZIP_ENV = --best +DEP_FILES = .deps/check.P .deps/check_msg.P .deps/check_run.P \ +.deps/error.P .deps/list.P SOURCES = $(libcheck_a_SOURCES) OBJECTS = $(libcheck_a_OBJECTS) @@ -106,9 +108,9 @@ all: all-redirect .SUFFIXES: .SUFFIXES: .S .c .o .s $(srcdir)/Makefile.in: Makefile.am $(top_srcdir)/configure.in $(ACLOCAL_M4) - cd $(top_srcdir) && $(AUTOMAKE) --gnu --include-deps src/Makefile + cd $(top_srcdir) && $(AUTOMAKE) --gnu src/Makefile -Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status $(BUILT_SOURCES) cd $(top_builddir) \ && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status @@ -145,9 +147,6 @@ uninstall-libLIBRARIES: rm -f $(DESTDIR)$(libdir)/$$p; \ done -.c.o: - $(COMPILE) -c $< - .s.o: $(COMPILE) -c $< @@ -218,6 +217,11 @@ distdir = $(top_builddir)/$(PACKAGE)-$(VERSION)/$(subdir) subdir = src distdir: $(DISTFILES) + here=`cd $(top_builddir) && pwd`; \ + top_distdir=`cd $(top_distdir) && pwd`; \ + distdir=`cd $(distdir) && pwd`; \ + cd $(top_srcdir) \ + && $(AUTOMAKE) --include-deps --build-dir=$$here --srcdir-name=$(top_srcdir) --output-dir=$$top_distdir --gnu src/Makefile @for file in $(DISTFILES); do \ d=$(srcdir); \ if test -d $$d/$$file; then \ @@ -228,12 +232,38 @@ distdir: $(DISTFILES) || cp -p $$d/$$file $(distdir)/$$file || :; \ fi; \ done -check.o: check.c error.h list.h check.h check_impl.h check_msg.h -check_msg.o: check_msg.c list.h error.h check.h check_impl.h check_msg.h -check_run.o: check_run.c error.h list.h check.h check_impl.h check_msg.h -error.o: error.c error.h -list.o: list.c list.h error.h +DEPS_MAGIC := $(shell mkdir .deps > /dev/null 2>&1 || :) + +-include $(DEP_FILES) + +mostlyclean-depend: + +clean-depend: + +distclean-depend: + -rm -rf .deps + +maintainer-clean-depend: + +%.o: %.c + @echo '$(COMPILE) -c $<'; \ + $(COMPILE) -Wp,-MD,.deps/$(*F).pp -c $< + @-cp .deps/$(*F).pp .deps/$(*F).P; \ + tr ' ' '\012' < .deps/$(*F).pp \ + | sed -e 's/^\\$$//' -e '/^$$/ d' -e '/:$$/ d' -e 's/$$/ :/' \ + >> .deps/$(*F).P; \ + rm .deps/$(*F).pp + +%.lo: %.c + @echo '$(LTCOMPILE) -c $<'; \ + $(LTCOMPILE) -Wp,-MD,.deps/$(*F).pp -c $< + @-sed -e 's/^\([^:]*\)\.o[ ]*:/\1.lo \1.o :/' \ + < .deps/$(*F).pp > .deps/$(*F).P; \ + tr ' ' '\012' < .deps/$(*F).pp \ + | sed -e 's/^\\$$//' -e '/^$$/ d' -e '/:$$/ d' -e 's/$$/ :/' \ + >> .deps/$(*F).P; \ + rm -f .deps/$(*F).pp info-am: info: info-am dvi-am: @@ -272,23 +302,24 @@ distclean-generic: maintainer-clean-generic: mostlyclean-am: mostlyclean-libLIBRARIES mostlyclean-compile \ - mostlyclean-tags mostlyclean-generic + mostlyclean-tags mostlyclean-depend mostlyclean-generic mostlyclean: mostlyclean-am -clean-am: clean-libLIBRARIES clean-compile clean-tags clean-generic \ - mostlyclean-am +clean-am: clean-libLIBRARIES clean-compile clean-tags clean-depend \ + clean-generic mostlyclean-am clean: clean-am distclean-am: distclean-libLIBRARIES distclean-compile distclean-tags \ - distclean-generic clean-am + distclean-depend distclean-generic clean-am distclean: distclean-am maintainer-clean-am: maintainer-clean-libLIBRARIES \ maintainer-clean-compile maintainer-clean-tags \ - maintainer-clean-generic distclean-am + maintainer-clean-depend maintainer-clean-generic \ + distclean-am @echo "This command is intended for maintainers to use;" @echo "it deletes files that may require special tools to rebuild." @@ -299,8 +330,9 @@ clean-libLIBRARIES maintainer-clean-libLIBRARIES uninstall-libLIBRARIES \ install-libLIBRARIES mostlyclean-compile distclean-compile \ clean-compile maintainer-clean-compile uninstall-includeHEADERS \ install-includeHEADERS tags mostlyclean-tags distclean-tags clean-tags \ -maintainer-clean-tags distdir info-am info dvi-am dvi check check-am \ -installcheck-am installcheck install-exec-am install-exec \ +maintainer-clean-tags distdir mostlyclean-depend distclean-depend \ +clean-depend maintainer-clean-depend info-am info dvi-am dvi check \ +check-am installcheck-am installcheck install-exec-am install-exec \ install-data-am install-data install-am install uninstall-am uninstall \ all-redirect all-am all installdirs mostlyclean-generic \ distclean-generic clean-generic maintainer-clean-generic clean \ diff --git a/check/tests/Makefile.in b/check/tests/Makefile.in index 472c9f0..c3b97b0 100644 --- a/check/tests/Makefile.in +++ b/check/tests/Makefile.in @@ -122,6 +122,8 @@ DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST) TAR = gtar GZIP_ENV = --best +DEP_FILES = .deps/check_check.P .deps/check_check_msg.P \ +.deps/check_list.P .deps/check_stress.P SOURCES = $(check_check_SOURCES) $(check_list_SOURCES) $(check_stress_SOURCES) $(check_check_msg_SOURCES) OBJECTS = $(check_check_OBJECTS) $(check_list_OBJECTS) $(check_stress_OBJECTS) $(check_check_msg_OBJECTS) @@ -129,9 +131,9 @@ all: all-redirect .SUFFIXES: .SUFFIXES: .S .c .o .s $(srcdir)/Makefile.in: Makefile.am $(top_srcdir)/configure.in $(ACLOCAL_M4) - cd $(top_srcdir) && $(AUTOMAKE) --gnu --include-deps tests/Makefile + cd $(top_srcdir) && $(AUTOMAKE) --gnu tests/Makefile -Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status $(BUILT_SOURCES) cd $(top_builddir) \ && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status @@ -145,9 +147,6 @@ distclean-noinstPROGRAMS: maintainer-clean-noinstPROGRAMS: -.c.o: - $(COMPILE) -c $< - .s.o: $(COMPILE) -c $< @@ -214,6 +213,11 @@ distdir = $(top_builddir)/$(PACKAGE)-$(VERSION)/$(subdir) subdir = tests distdir: $(DISTFILES) + here=`cd $(top_builddir) && pwd`; \ + top_distdir=`cd $(top_distdir) && pwd`; \ + distdir=`cd $(distdir) && pwd`; \ + cd $(top_srcdir) \ + && $(AUTOMAKE) --include-deps --build-dir=$$here --srcdir-name=$(top_srcdir) --output-dir=$$top_distdir --gnu tests/Makefile @for file in $(DISTFILES); do \ d=$(srcdir); \ if test -d $$d/$$file; then \ @@ -224,11 +228,38 @@ distdir: $(DISTFILES) || cp -p $$d/$$file $(distdir)/$$file || :; \ fi; \ done -check_check.o: check_check.c ../src/check.h ../src/error.h -check_check_msg.o: check_check_msg.c ../src/check.h ../src/check_msg.h -check_list.o: check_list.c ../src/list.h ../src/check.h -check_stress.o: check_stress.c ../src/check.h +DEPS_MAGIC := $(shell mkdir .deps > /dev/null 2>&1 || :) + +-include $(DEP_FILES) + +mostlyclean-depend: + +clean-depend: + +distclean-depend: + -rm -rf .deps + +maintainer-clean-depend: + +%.o: %.c + @echo '$(COMPILE) -c $<'; \ + $(COMPILE) -Wp,-MD,.deps/$(*F).pp -c $< + @-cp .deps/$(*F).pp .deps/$(*F).P; \ + tr ' ' '\012' < .deps/$(*F).pp \ + | sed -e 's/^\\$$//' -e '/^$$/ d' -e '/:$$/ d' -e 's/$$/ :/' \ + >> .deps/$(*F).P; \ + rm .deps/$(*F).pp + +%.lo: %.c + @echo '$(LTCOMPILE) -c $<'; \ + $(LTCOMPILE) -Wp,-MD,.deps/$(*F).pp -c $< + @-sed -e 's/^\([^:]*\)\.o[ ]*:/\1.lo \1.o :/' \ + < .deps/$(*F).pp > .deps/$(*F).P; \ + tr ' ' '\012' < .deps/$(*F).pp \ + | sed -e 's/^\\$$//' -e '/^$$/ d' -e '/:$$/ d' -e 's/$$/ :/' \ + >> .deps/$(*F).P; \ + rm -f .deps/$(*F).pp check-TESTS: $(TESTS) @failed=0; all=0; \ srcdir=$(srcdir); export srcdir; \ @@ -292,23 +323,24 @@ distclean-generic: maintainer-clean-generic: mostlyclean-am: mostlyclean-noinstPROGRAMS mostlyclean-compile \ - mostlyclean-tags mostlyclean-generic + mostlyclean-tags mostlyclean-depend mostlyclean-generic mostlyclean: mostlyclean-am -clean-am: clean-noinstPROGRAMS clean-compile clean-tags clean-generic \ - mostlyclean-am +clean-am: clean-noinstPROGRAMS clean-compile clean-tags clean-depend \ + clean-generic mostlyclean-am clean: clean-am distclean-am: distclean-noinstPROGRAMS distclean-compile distclean-tags \ - distclean-generic clean-am + distclean-depend distclean-generic clean-am distclean: distclean-am maintainer-clean-am: maintainer-clean-noinstPROGRAMS \ maintainer-clean-compile maintainer-clean-tags \ - maintainer-clean-generic distclean-am + maintainer-clean-depend maintainer-clean-generic \ + distclean-am @echo "This command is intended for maintainers to use;" @echo "it deletes files that may require special tools to rebuild." @@ -318,10 +350,11 @@ maintainer-clean: maintainer-clean-am clean-noinstPROGRAMS maintainer-clean-noinstPROGRAMS \ mostlyclean-compile distclean-compile clean-compile \ maintainer-clean-compile tags mostlyclean-tags distclean-tags \ -clean-tags maintainer-clean-tags distdir check-TESTS info-am info \ -dvi-am dvi check check-am installcheck-am installcheck install-exec-am \ -install-exec install-data-am install-data install-am install \ -uninstall-am uninstall all-redirect all-am all installdirs \ +clean-tags maintainer-clean-tags distdir mostlyclean-depend \ +distclean-depend clean-depend maintainer-clean-depend check-TESTS \ +info-am info dvi-am dvi check check-am installcheck-am installcheck \ +install-exec-am install-exec install-data-am install-data install-am \ +install uninstall-am uninstall all-redirect all-am all installdirs \ mostlyclean-generic distclean-generic clean-generic \ maintainer-clean-generic clean mostlyclean distclean maintainer-clean -- 2.40.0