From 4813cf4bde61a5bb9256ebbee3bf874718d13045 Mon Sep 17 00:00:00 2001 From: Kim Alvefur Date: Sat, 1 Oct 2016 01:38:28 +0200 Subject: Makefile: Use more specific globbing for util.sasl.* (like 5a60b4705bc3) --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index 06e67c9c..d442e452 100644 --- a/Makefile +++ b/Makefile @@ -37,7 +37,7 @@ install: prosody.install prosodyctl.install prosody.cfg.lua.install util/encodin install -m644 util/*.lua $(SOURCE)/util install -m644 util/*.so $(SOURCE)/util install -d $(SOURCE)/util/sasl - install -m644 util/sasl/* $(SOURCE)/util/sasl + install -m644 util/sasl/*.lua $(SOURCE)/util/sasl umask 0022 && cp -r plugins/* $(MODULES) install -m644 certs/* $(CONFIG)/certs install -m644 man/prosodyctl.man $(MAN)/man1/prosodyctl.1 -- cgit v1.2.3 From b0701fb30f8f4b6e6cbd567aed29c1d660708875 Mon Sep 17 00:00:00 2001 From: Kim Alvefur Date: Sat, 1 Oct 2016 01:39:46 +0200 Subject: Makefile: Use install to copy plugins that live in subdirectories instead of recursive cp --- Makefile | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index d442e452..b3e39e30 100644 --- a/Makefile +++ b/Makefile @@ -38,7 +38,12 @@ install: prosody.install prosodyctl.install prosody.cfg.lua.install util/encodin install -m644 util/*.so $(SOURCE)/util install -d $(SOURCE)/util/sasl install -m644 util/sasl/*.lua $(SOURCE)/util/sasl - umask 0022 && cp -r plugins/* $(MODULES) + install -d $(MODULES)/mod_s2s $(MODULES)/mod_pubsub $(MODULES)/adhoc $(MODULES)/muc + install -m644 plugins/*.lua $(MODULES) + install -m644 plugins/mod_s2s/*.lua $(MODULES) + install -m644 plugins/mod_pubsub/*.lua $(MODULES) + install -m644 plugins/adhoc/*.lua $(MODULES) + install -m644 plugins/muc/*.lua $(MODULES) install -m644 certs/* $(CONFIG)/certs install -m644 man/prosodyctl.man $(MAN)/man1/prosodyctl.1 test -f $(CONFIG)/prosody.cfg.lua || install -m644 prosody.cfg.lua.install $(CONFIG)/prosody.cfg.lua -- cgit v1.2.3 From 07c7d4e7946b6209070a7c7246363195264daaf1 Mon Sep 17 00:00:00 2001 From: Kim Alvefur Date: Sat, 1 Oct 2016 01:46:43 +0200 Subject: Makefile: Refactor all uses of the install command with variables, allowing them to be overridden --- Makefile | 58 ++++++++++++++++++++++++++++++++-------------------------- 1 file changed, 32 insertions(+), 26 deletions(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index b3e39e30..9dcd80c3 100644 --- a/Makefile +++ b/Makefile @@ -13,6 +13,12 @@ INSTALLEDCONFIG = $(SYSCONFDIR) INSTALLEDMODULES = $(LIBDIR)/prosody/modules INSTALLEDDATA = $(DATADIR) +INSTALL=install +INSTALL_DATA=$(INSTALL) -m644 +INSTALL_EXEC=$(INSTALL) -m755 +MKDIR=install -d +MKDIR_PRIVATE=$(MKDIR) -m750 + .PHONY: all clean install all: prosody.install prosodyctl.install prosody.cfg.lua.install prosody.version @@ -22,32 +28,32 @@ ifeq ($(EXCERTS),yes) endif install: prosody.install prosodyctl.install prosody.cfg.lua.install util/encodings.so util/encodings.so util/pposix.so util/signal.so - install -d $(BIN) $(CONFIG) $(MODULES) $(SOURCE) - install -m750 -d $(DATA) - install -d $(MAN)/man1 - install -d $(CONFIG)/certs - install -d $(SOURCE)/core $(SOURCE)/net $(SOURCE)/util - install -m755 ./prosody.install $(BIN)/prosody - install -m755 ./prosodyctl.install $(BIN)/prosodyctl - install -m644 core/*.lua $(SOURCE)/core - install -m644 net/*.lua $(SOURCE)/net - install -d $(SOURCE)/net/http $(SOURCE)/net/websocket - install -m644 net/http/*.lua $(SOURCE)/net/http - install -m644 net/websocket/*.lua $(SOURCE)/net/websocket - install -m644 util/*.lua $(SOURCE)/util - install -m644 util/*.so $(SOURCE)/util - install -d $(SOURCE)/util/sasl - install -m644 util/sasl/*.lua $(SOURCE)/util/sasl - install -d $(MODULES)/mod_s2s $(MODULES)/mod_pubsub $(MODULES)/adhoc $(MODULES)/muc - install -m644 plugins/*.lua $(MODULES) - install -m644 plugins/mod_s2s/*.lua $(MODULES) - install -m644 plugins/mod_pubsub/*.lua $(MODULES) - install -m644 plugins/adhoc/*.lua $(MODULES) - install -m644 plugins/muc/*.lua $(MODULES) - install -m644 certs/* $(CONFIG)/certs - install -m644 man/prosodyctl.man $(MAN)/man1/prosodyctl.1 - test -f $(CONFIG)/prosody.cfg.lua || install -m644 prosody.cfg.lua.install $(CONFIG)/prosody.cfg.lua - -test -f prosody.version && install -m644 prosody.version $(SOURCE)/prosody.version + $(MKDIR) $(BIN) $(CONFIG) $(MODULES) $(SOURCE) + $(MKDIR_PRIVATE) $(DATA) + $(MKDIR) $(MAN)/man1 + $(MKDIR) $(CONFIG)/certs + $(MKDIR) $(SOURCE)/core $(SOURCE)/net $(SOURCE)/util + $(INSTALL_EXEC) ./prosody.install $(BIN)/prosody + $(INSTALL_EXEC) ./prosodyctl.install $(BIN)/prosodyctl + $(INSTALL_DATA) core/*.lua $(SOURCE)/core + $(INSTALL_DATA) net/*.lua $(SOURCE)/net + $(MKDIR) $(SOURCE)/net/http $(SOURCE)/net/websocket + $(INSTALL_DATA) net/http/*.lua $(SOURCE)/net/http + $(INSTALL_DATA) net/websocket/*.lua $(SOURCE)/net/websocket + $(INSTALL_DATA) util/*.lua $(SOURCE)/util + $(INSTALL_DATA) util/*.so $(SOURCE)/util + $(MKDIR) $(SOURCE)/util/sasl + $(INSTALL_DATA) util/sasl/*.lua $(SOURCE)/util/sasl + $(MKDIR) $(MODULES)/mod_s2s $(MODULES)/mod_pubsub $(MODULES)/adhoc $(MODULES)/muc + $(INSTALL_DATA) plugins/*.lua $(MODULES) + $(INSTALL_DATA) plugins/mod_s2s/*.lua $(MODULES) + $(INSTALL_DATA) plugins/mod_pubsub/*.lua $(MODULES) + $(INSTALL_DATA) plugins/adhoc/*.lua $(MODULES) + $(INSTALL_DATA) plugins/muc/*.lua $(MODULES) + $(INSTALL_DATA) certs/* $(CONFIG)/certs + $(INSTALL_DATA) man/prosodyctl.man $(MAN)/man1/prosodyctl.1 + test -f $(CONFIG)/prosody.cfg.lua || $(INSTALL_DATA) prosody.cfg.lua.install $(CONFIG)/prosody.cfg.lua + -test -f prosody.version && $(INSTALL_DATA) prosody.version $(SOURCE)/prosody.version $(MAKE) install -C util-src clean: -- cgit v1.2.3 From ca9cbd607f1dd9621237c6284fbf53dc5ba321c8 Mon Sep 17 00:00:00 2001 From: Kim Alvefur Date: Sat, 1 Oct 2016 01:49:26 +0200 Subject: Makefile: Preserve timestamps of installed files (fixes #547) --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index 9dcd80c3..67730b9f 100644 --- a/Makefile +++ b/Makefile @@ -13,7 +13,7 @@ INSTALLEDCONFIG = $(SYSCONFDIR) INSTALLEDMODULES = $(LIBDIR)/prosody/modules INSTALLEDDATA = $(DATADIR) -INSTALL=install +INSTALL=install -p INSTALL_DATA=$(INSTALL) -m644 INSTALL_EXEC=$(INSTALL) -m755 MKDIR=install -d -- cgit v1.2.3