diff --git a/ChangeLog b/ChangeLog index c604b83..15e01c0 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,7 +1,17 @@ +2014-05-25 Dale Mellor + + * Juggled build infrastructure so that we can make the minimal man + page in the proper autotools way. + + * configure.ac: version to 1.0.8. + + 2014-04-28 Dale Mellor * We now run against, and require, guile-2.0. + * configure.ac: version to 1.0.7. + 2012-02-04 Dale Mellor @@ -148,7 +158,7 @@ ________________________________________________________________________________ -Copyright (C) 2003, 2005, 2006 Dale Mellor +Copyright (C) 2003, 2005, 2006, 2014 Dale Mellor Copying and distribution of this file, with or without modification, are permitted in any medium without royalty provided the copyright diff --git a/configure.ac b/configure.ac index 0ffd581..c819d4d 100644 --- a/configure.ac +++ b/configure.ac @@ -21,7 +21,7 @@ AC_PREREQ(2.61) -AC_INIT([mcron], [1.0.7], [dale_mellor@users.sourceforge.net]) +AC_INIT([mcron], [1.0.8], [dale_mellor@users.sourceforge.net]) AM_INIT_AUTOMAKE @@ -44,10 +44,12 @@ AC_PROG_AWK AC_PROG_EGREP AM_PROG_CC_C_O -PKG_CHECK_MODULES(GUILE, guile-2.0 >= 2.0.7) +PKG_CHECK_MODULES(GUILE, guile-2.0) # Checks for programs. +AM_MISSING_PROG(HELP2MAN, help2man, $missing_dir) + AC_CHECK_PROGS(SED, sed) if test "x$ac_cv_prog_SED" = "x"; then AC_MSG_ERROR(sed not found) @@ -169,5 +171,5 @@ real_program_prefix=`echo $program_prefix | sed s/NONE//` AC_SUBST(real_program_prefix) -AC_CONFIG_FILES(mcron.texinfo makefile config.scm) +AC_CONFIG_FILES(mcron.texinfo makefile scm/mcron/makefile scm/mcron/config.scm) AC_OUTPUT diff --git a/makefile.am b/makefile.am index 85610df..a7f0e75 100644 --- a/makefile.am +++ b/makefile.am @@ -18,40 +18,33 @@ ## Process this file with automake to produce Makefile.in +SUBDIRS = scm/mcron . + ED = @ED@ # !!!! Are these needed? CP = @CP@ MAINTAINERCLEANFILES = configure makefile makefile.in config.guess config.sub \ install-sh missing texinfo.tex INSTALL \ - aclocal.m4 compile depcomp + aclocal.m4 compile depcomp mcron.1 CLEANFILES = mcron.c core.scm -EXTRA_DIST = makefile.ed main.scm mcron-core.scm vixie-specification.scm \ - crontab.scm environment.scm job-specifier.scm redirect.scm \ - vixie-time.scm mcron.c.template BUGS +EXTRA_DIST = makefile.ed mcron.c.template BUGS info_TEXINFOS = mcron.texinfo -dist_man1_MANS = mcron.1 +man_MANS = mcron.1 bin_PROGRAMS = mcron mcron_SOURCES = mcron.c mcron_LDADD = @GUILE_LIBS@ -mcron_CFLAGS = @GUILE_CFLAGS@ -DGUILE_LOAD_PATH=\"$(datadir)\" -pkgdata_DATA = core.scm environment.scm job-specifier.scm redirect.scm \ - vixie-time.scm vixie-specification.scm config.scm +# The second option is so that we can execute the binary in the local directory, +# in turn so that we can do mcron --help during the build process. +mcron_CFLAGS = @GUILE_CFLAGS@ -DGUILE_LOAD_PATH=\"$(datadir):./scm:...\" -# If you're wondering, the configure script keeps deleting all files with a name -# like core.*, so we have to keep re-making it (I lost a good day's work because -# of this). - -core.scm : mcron-core.scm - $(CP) mcron-core.scm core.scm - -mcron.c : main.scm crontab.scm makefile.ed mcron.c.template +mcron.c : scm/mcron/main.scm scm/mcron/crontab.scm makefile.ed mcron.c.template @echo 'Building mcron.c...' @$(ED) < makefile.ed > /dev/null 2>&1 @rm -f mcron.escaped.scm > /dev/null 2>&1 @@ -76,9 +69,6 @@ install-exec-hook: else \ echo "+++ WARNING: NON-ROOT INSTALL: ONLY mcron WILL BE INSTALLED, NOT ANY OF THE VIXIE REPLACEMENT PROGRAMS"; \ fi - @echo - @echo " AFTER INSTALLATION, CONSIDER RUNNING make cook-up-man" - @echo uninstall-hook: @@ -89,7 +79,6 @@ uninstall-hook: # Not part of formal package building, but a rule for manual use to get the # elemental man page. Will only work once the mcron program is installed. -cook-up-man: - help2man -n 'a program to run tasks at regular (or not) intervals' \ - $(fpp)mcron > mcron.1 - $(MAKE) install +mcron.1 : mcron.c + $(HELP2MAN) -n 'a program to run tasks at regular (or not) intervals' \ + ./mcron > mcron.1 diff --git a/makefile.ed b/makefile.ed index 5c89344..7047ec7 100644 --- a/makefile.ed +++ b/makefile.ed @@ -17,9 +17,9 @@ # # # -e main.scm +e scm/mcron/main.scm /\(load "crontab.scm"\)/d --1r crontab.scm +-1r scm/mcron/crontab.scm %s/\\/\\\\/g %s/"/\\"/g %s/ *;;.*$/ /g diff --git a/mcron.1 b/mcron.1 deleted file mode 100644 index e69de29..0000000 diff --git a/config.scm.in b/scm/mcron/config.scm.in similarity index 100% rename from config.scm.in rename to scm/mcron/config.scm.in diff --git a/crontab.scm b/scm/mcron/crontab.scm similarity index 100% rename from crontab.scm rename to scm/mcron/crontab.scm diff --git a/environment.scm b/scm/mcron/environment.scm similarity index 100% rename from environment.scm rename to scm/mcron/environment.scm diff --git a/job-specifier.scm b/scm/mcron/job-specifier.scm similarity index 100% rename from job-specifier.scm rename to scm/mcron/job-specifier.scm diff --git a/main.scm b/scm/mcron/main.scm similarity index 100% rename from main.scm rename to scm/mcron/main.scm diff --git a/mcron-core.scm b/scm/mcron/mcron-core.scm similarity index 100% rename from mcron-core.scm rename to scm/mcron/mcron-core.scm diff --git a/redirect.scm b/scm/mcron/redirect.scm similarity index 100% rename from redirect.scm rename to scm/mcron/redirect.scm diff --git a/vixie-specification.scm b/scm/mcron/vixie-specification.scm similarity index 100% rename from vixie-specification.scm rename to scm/mcron/vixie-specification.scm diff --git a/vixie-time.scm b/scm/mcron/vixie-time.scm similarity index 100% rename from vixie-time.scm rename to scm/mcron/vixie-time.scm