1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117
|
# Makefile.am
#
# Keepalived OpenSource project.
#
# Copyright (C) 2001-2017 Alexandre Cassen, <acassen@gmail.com>
export DEBUG_CFLAGS
export DEBUG_CPPFLAGS
export DEBUG_LDFLAGS
edit = echo " EDIT $@"; \
@SED@ -e "/^\[\!\[/d"
SUBDIRS = lib keepalived doc
SUBDIRS += bin_install
EXTRA_DIST = AUTHOR CONTRIBUTORS snap README.md build_setup autogen.sh tools/timed_reload
doc_DATA = README
MOSTLYCLEANFILES = README
MAINTAINERCLEANFILES = @MAINTAINERCLEANFILES@
ACLOCAL_AMFLAGS = -I m4 ${ACLOCAL_FLAGS}
README: $(srcdir)/README.md
@$(edit) '$(srcdir)/$@.md' >$@
if WITH_DBUS
install-data-hook:
@if [ @sysconfdir@ != /etc ]; then \
echo; \
echo "NOTE: To enable DBus to work you probably want to add:"; \
echo " <includedir>@sysconfdir@/dbus1/system.d</includedir>"; \
echo " to /etc/dbus-1/system-local.conf and restart dbus or reboot."; \
echo; \
echo " It should look something like:"; \
echo; \
echo "<!DOCTYPE busconfig PUBLIC \"-//freedesktop//DTD D-Bus Bus Configuration 1.0//EN\""; \
echo " \"http://www.freedesktop.org/standards/dbus/1.0/busconfig.dtd\">"; \
echo "<busconfig>"; \
echo ""; \
echo " <includedir>@sysconfdir@/dbus-1/system.d</includedir>"; \
echo ""; \
echo "</busconfig>"; \
echo; \
fi
endif
distclean-local:
@rm -f aclocal.m4 keepalived-$(VERSION).tar.gz config.log config.status
@rm -rf autom4te.cache
# If we are in a git tree, set the last modified date of each unmodified source file
# based on its git commit date. This will help repeatable builds.
dist-hook:
@if [ -x `type -p git` ]; then \
git rev-parse --is-inside-work-tree >/dev/null 2>&1; \
if [ $$? -eq 0 ]; then \
echo " DATESET git tree"; \
for f in `git ls-tree --full-tree -r --name-only HEAD`; \
do \
if [ -n "`git status --porcelain $$f`" ]; then continue; fi; \
if [ ! -f $(top_distdir)/$$f ]; then continue; fi; \
touch --date=@`git log -n 1 --format=%ct -- $$f` $(top_distdir)/$$f; \
done; \
cd lib; \
make git-commit.h; \
cd ..; \
fi \
fi
@rm -f $(distdir)/README
.PHONY: docker
docker: dist
docker build -t keepalived --build-arg GIT_VER=`grep GIT_COMMIT lib/git-commit.h | sed -e 's/.*"v[^-]*\(.*\)"/\1/'` .
# clean all files that are generated by automake/autoconf etc
autoclean:
@$(MAKE) distclean
@rm -f configure `find . -name Makefile.in` lib/config.h.in lib/git-commit.h lib/stamp-h[12] m4/pkg.m4
@rm -rf build-aux
git-clean:
@$(MAKE) autoclean
clean-local: clean-local-snap
# clean files that are generated by snapcraft
.PHONY: clean-local-snap
clean-local-snap:
-rm -rf parts/ prime/ stage/ keepalived_*.snap
# Added targets to maintain compatibility with keepalived releases 1.2.22 and earlier
.PHONY: tarball rpm debug profile mrproper
tarball: dist
@RPM_TRUE@rpm:
@RPM_TRUE@ @$(MAKE) dist
@RPM_TRUE@ @cp -p keepalived-$(VERSION).tar.gz `rpm --eval "%{_sourcedir}"`
@RPM_TRUE@@RPM_BIP_TRUE@ rpmbuild -ba --build-in-place keepalived.spec
@RPM_TRUE@@RPM_BIP_FALSE@ rpmbuild -ba keepalived.spec
debug:
@$(MAKE) DEBUG_LDFLAGS=-ggdb
profile:
@$(MAKE) DEBUG_CFLAGS=-pg
mrproper:
@echo Please use `make distclean`
AM_DISTCHECK_CONFIGURE_FLAGS = \
--with-systemdsystemunitdir=$$dc_install_base/$(systemdsystemunitdir)
|