build: Separate "Makefile.am" into more sections.
* Makefile.am: Add "Installation", "Distribution", "Test suite", "Programs", and "Guile modules" sections.
This commit is contained in:
parent
a0a82a2ef4
commit
f284b52446
1 changed files with 50 additions and 28 deletions
68
Makefile.am
68
Makefile.am
|
|
@ -17,6 +17,10 @@
|
||||||
# You should have received a copy of the GNU General Public License
|
# You should have received a copy of the GNU General Public License
|
||||||
# along with GNU Mcron. If not, see <http://www.gnu.org/licenses/>.
|
# along with GNU Mcron. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
|
## ---------- ##
|
||||||
|
## Programs. ##
|
||||||
|
## ---------- ##
|
||||||
|
|
||||||
bin_PROGRAMS = bin/mcron bin/crontab
|
bin_PROGRAMS = bin/mcron bin/crontab
|
||||||
sbin_PROGRAMS = bin/cron
|
sbin_PROGRAMS = bin/cron
|
||||||
|
|
||||||
|
|
@ -40,6 +44,13 @@ bin_crontab_SOURCES = src/wrapper.c
|
||||||
bin_crontab_CPPFLAGS = $(AM_CPPFLAGS) -DPROGRAM="\"crontab\""
|
bin_crontab_CPPFLAGS = $(AM_CPPFLAGS) -DPROGRAM="\"crontab\""
|
||||||
bin_crontab_DEPENDENCIES = $(compiled_modules)
|
bin_crontab_DEPENDENCIES = $(compiled_modules)
|
||||||
|
|
||||||
|
# wrapper to be used in the build environment and for running tests.
|
||||||
|
noinst_SCRIPTS = pre-inst-env
|
||||||
|
|
||||||
|
## --------------- ##
|
||||||
|
## Guile modules. ##
|
||||||
|
## --------------- ##
|
||||||
|
|
||||||
# Root directory used for installing Guile modules.
|
# Root directory used for installing Guile modules.
|
||||||
guilesitedir = $(datarootdir)/guile/site/$(GUILE_EFFECTIVE_VERSION)
|
guilesitedir = $(datarootdir)/guile/site/$(GUILE_EFFECTIVE_VERSION)
|
||||||
# Root directory used for installing Guile compiled modules.
|
# Root directory used for installing Guile compiled modules.
|
||||||
|
|
@ -77,16 +88,8 @@ compiled_modules = \
|
||||||
$(pkgmodulego_DATA) \
|
$(pkgmodulego_DATA) \
|
||||||
$(pkgscriptgo_DATA)
|
$(pkgscriptgo_DATA)
|
||||||
|
|
||||||
TEST_EXTENSIONS = .scm
|
CLEANFILES = $(compiled_modules)
|
||||||
AM_TESTS_ENVIRONMENT = env GUILE_AUTO_COMPILE='0'
|
DISTCLEANFILES = src/mcron/config.scm
|
||||||
|
|
||||||
SCM_LOG_DRIVER = \
|
|
||||||
$(builddir)/pre-inst-env $(GUILE) \
|
|
||||||
$(srcdir)/build-aux/test-driver.scm
|
|
||||||
|
|
||||||
TESTS = \
|
|
||||||
tests/environment.scm \
|
|
||||||
tests/job-specifier.scm
|
|
||||||
|
|
||||||
# Unset 'GUILE_LOAD_COMPILED_PATH' altogether while compiling. Otherwise, if
|
# Unset 'GUILE_LOAD_COMPILED_PATH' altogether while compiling. Otherwise, if
|
||||||
# $GUILE_LOAD_COMPILED_PATH contains $(pkgmoduledir), we may find .go files
|
# $GUILE_LOAD_COMPILED_PATH contains $(pkgmoduledir), we may find .go files
|
||||||
|
|
@ -103,17 +106,34 @@ TESTS = \
|
||||||
export GUILE_AUTO_COMPILE=0; unset GUILE_LOAD_COMPILED_PATH; \
|
export GUILE_AUTO_COMPILE=0; unset GUILE_LOAD_COMPILED_PATH; \
|
||||||
LC_ALL=C \
|
LC_ALL=C \
|
||||||
$(top_builddir)/pre-inst-env $(GUILD) compile \
|
$(top_builddir)/pre-inst-env $(GUILD) compile \
|
||||||
--load-path="$(top_builddir)/src" \
|
--load-path="$(builddir)/src" \
|
||||||
--load-path="$(top_srcdir)/src" \
|
--load-path="$(srcdir)/src" \
|
||||||
--warn=format --warn=unbound-variable --warn=arity-mismatch \
|
--warn=format --warn=unbound-variable --warn=arity-mismatch \
|
||||||
--target="$(host)" --output="$@" "$<" $(devnull_verbose)
|
--target="$(host)" --output="$@" "$<" $(devnull_verbose)
|
||||||
|
|
||||||
SUFFIXES = .go
|
## ------------ ##
|
||||||
noinst_SCRIPTS = pre-inst-env
|
## Test suite. ##
|
||||||
|
## ------------ ##
|
||||||
|
|
||||||
|
TEST_EXTENSIONS = .scm
|
||||||
|
AM_TESTS_ENVIRONMENT = env GUILE_AUTO_COMPILE='0'
|
||||||
|
|
||||||
|
SCM_LOG_DRIVER = \
|
||||||
|
$(builddir)/pre-inst-env $(GUILE) \
|
||||||
|
$(srcdir)/build-aux/test-driver.scm
|
||||||
|
|
||||||
|
TESTS = \
|
||||||
|
tests/environment.scm \
|
||||||
|
tests/job-specifier.scm
|
||||||
|
|
||||||
|
## -------------- ##
|
||||||
|
## Distribution. ##
|
||||||
|
## -------------- ##
|
||||||
|
|
||||||
dist-hook: gen-ChangeLog
|
dist-hook: gen-ChangeLog
|
||||||
$(AM_V_GEN)echo $(VERSION) > $(distdir)/.tarball-version
|
$(AM_V_GEN)echo $(VERSION) > $(distdir)/.tarball-version
|
||||||
|
|
||||||
|
# Generate the ChangeLog file from Git commit logs.
|
||||||
gen_start_date = 2015-06-26
|
gen_start_date = 2015-06-26
|
||||||
.PHONY: gen-ChangeLog
|
.PHONY: gen-ChangeLog
|
||||||
gen-ChangeLog:
|
gen-ChangeLog:
|
||||||
|
|
@ -128,6 +148,15 @@ gen-ChangeLog:
|
||||||
mv $(distdir)/cl-t $(distdir)/ChangeLog; } \
|
mv $(distdir)/cl-t $(distdir)/ChangeLog; } \
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
EXTRA_DIST = \
|
||||||
|
bootstrap \
|
||||||
|
build-aux/guix.scm \
|
||||||
|
$(TESTS)
|
||||||
|
|
||||||
|
## -------------- ##
|
||||||
|
## Installation. ##
|
||||||
|
## -------------- ##
|
||||||
|
|
||||||
#full program prefix
|
#full program prefix
|
||||||
fpp = $(DESTDIR)$(bindir)/@real_program_prefix@
|
fpp = $(DESTDIR)$(bindir)/@real_program_prefix@
|
||||||
|
|
||||||
|
|
@ -152,15 +181,6 @@ uninstall-hook:
|
||||||
rm -f $(fpp){cron,crontab}$(EXEEXT); \
|
rm -f $(fpp){cron,crontab}$(EXEEXT); \
|
||||||
fi
|
fi
|
||||||
|
|
||||||
EXTRA_DIST = \
|
|
||||||
bootstrap \
|
|
||||||
build-aux/guix.scm \
|
|
||||||
$(TESTS)
|
|
||||||
|
|
||||||
MAINTAINERCLEANFILES = $(dist_man_MANS)
|
|
||||||
DISTCLEANFILES = src/mcron/config.scm
|
|
||||||
CLEANFILES = $(compiled_modules)
|
|
||||||
|
|
||||||
## --------------- ##
|
## --------------- ##
|
||||||
## Documentation. ##
|
## Documentation. ##
|
||||||
## --------------- ##
|
## --------------- ##
|
||||||
|
|
@ -198,6 +218,8 @@ $(srcdir)/doc/crontab.1: src/mcron/scripts/crontab.scm bin/crontab
|
||||||
$(srcdir)/doc/cron.8: src/mcron/scripts/cron.scm bin/cron
|
$(srcdir)/doc/cron.8: src/mcron/scripts/cron.scm bin/cron
|
||||||
-@prog="cron"; man_section=8; $(gen_man)
|
-@prog="cron"; man_section=8; $(gen_man)
|
||||||
|
|
||||||
|
MAINTAINERCLEANFILES = $(dist_man_MANS)
|
||||||
|
|
||||||
## -------------- ##
|
## -------------- ##
|
||||||
## Silent rules. ##
|
## Silent rules. ##
|
||||||
## -------------- ##
|
## -------------- ##
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue