mirror of
https://github.com/troglobit/finit.git
synced 2026-10-01 05:22:48 +07:00
The installation path for plugins was encoded wrong in the finit binary if *not* unset, i.e., "prefix=". Updated the README with information on all build related environment variables. Much of it is perhaps only needed for packagers and distributions. New version bump, v1.2 already. Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
36 lines
891 B
Makefile
36 lines
891 B
Makefile
# Plugin based services architecture for finit -*-Makefile-*-
|
|
CFLAGS = -fPIC -g -Os
|
|
CPPFLAGS += -I..
|
|
LDFLAGS = -shared
|
|
PLUGINS ?= initctl.so alsa-utils.so bootmisc.so dbus.so hwclock.so \
|
|
resolvconf.so urandom.so x11-common.so
|
|
DEPS = $(addprefix .,$(PLUGINS:.so=.d))
|
|
|
|
include ../common.mk
|
|
|
|
all: $(PLUGINS)
|
|
|
|
clean:
|
|
-@$(RM) $(PLUGINS) *.o
|
|
|
|
distclean: clean
|
|
-@$(RM) $(JUNK) $(DEPS)
|
|
|
|
install: all
|
|
@install -d $(DESTDIR)$(prefix)$(PLUGIN_DIR)
|
|
@for plugin in $(PLUGINS); do \
|
|
echo " INSTALL $(DESTDIR)$(prefix)$(PLUGIN_DIR)/$$plugin"; \
|
|
cp $$plugin $(DESTDIR)$(prefix)$(PLUGIN_DIR); \
|
|
done
|
|
|
|
uninstall:
|
|
-@for plugin in $(PLUGINS); do \
|
|
echo " RM $(PLUGIN_DIR)/$$plugin"; \
|
|
rm $(DESTDIR)$(prefix)$(PLUGIN_DIR)/$$plugin 2>/dev/null; \
|
|
done
|
|
-@rmdir $(DESTDIR)$(prefix)$(PLUGIN_DIR) 2>/dev/null
|
|
|
|
ifneq ($(MAKECMDGOALS),clean)
|
|
-include $(DEPS)
|
|
endif
|