Fix make distcheck if systemd is installed

The automatically determined path for systemd units is an absolute system
path that doesn't respect $(prefix).  That's a problem for make distcheck,
which is usually ran as regular user and it's not expected to have any
impact on the system (it does a local install in a subdir).  To avoid
these issues we override the configure flags used by make distcheck and
set the path to one relative to the specified prefix.
This commit is contained in:
Tobias Brunner 2018-11-09 16:48:40 +01:00
parent cab4b3a341
commit d8d756e306
1 changed files with 5 additions and 0 deletions

View File

@ -24,6 +24,11 @@ config_includedir = $(ipseclibdir)/include
nodist_config_include_HEADERS = config.h
endif
# we can't (and shouldn't) install/uninstall system files during make distcheck,
# so override the autodetected path for systemd units
AM_DISTCHECK_CONFIGURE_FLAGS = \
--with-systemdsystemunitdir='$$(prefix)/lib/systemd/system'
# we leave config files behind intentionally so prevent distcheck from complaining
distuninstallcheck_listfiles = find . -type f \! -name '*.conf' \! -name '*.secrets' -print