summaryrefslogtreecommitdiffstats
path: root/package/lockfile-progs/lockfile-progs.mk
diff options
context:
space:
mode:
Diffstat (limited to 'package/lockfile-progs/lockfile-progs.mk')
-rw-r--r--package/lockfile-progs/lockfile-progs.mk54
1 files changed, 21 insertions, 33 deletions
diff --git a/package/lockfile-progs/lockfile-progs.mk b/package/lockfile-progs/lockfile-progs.mk
index 3925ca3c6..f8d8ceeca 100644
--- a/package/lockfile-progs/lockfile-progs.mk
+++ b/package/lockfile-progs/lockfile-progs.mk
@@ -3,42 +3,30 @@
# lockfile-progs
#
#############################################################
-LOCKFILE_PROGS_VERSION=0.1.11-0.1
-LOCKFILE_PROGS_SOURCE:=lockfile-progs_$(LOCKFILE_PROGS_VERSION).tar.gz
-LOCKFILE_PROGS_SITE:=$(BR2_DEBIAN_MIRROR)/debian/pool/main/l/lockfile-progs/
-LOCKFILE_PROGS_CAT:=$(ZCAT)
-LOCKFILE_PROGS_DIR:=$(BUILD_DIR)/lockfile-progs-0.1.11
-LOCKFILE_PROGS_BINARY:=usr/bin/lockfile-create
+LOCKFILE_PROGS_VERSION = 0.1.15
+LOCKFILE_PROGS_SOURCE = lockfile-progs_$(LOCKFILE_PROGS_VERSION).tar.gz
+LOCKFILE_PROGS_SITE = $(BR2_DEBIAN_MIRROR)/debian/pool/main/l/lockfile-progs/
-$(DL_DIR)/$(LOCKFILE_PROGS_SOURCE):
- $(call DOWNLOAD,$(LOCKFILE_PROGS_SITE),$(LOCKFILE_PROGS_SOURCE))
+LOCKFILE_BINS = \
+ $(addprefix lockfile-,check create remove touch) \
+ $(addprefix mail-,lock touchlock unlock)
-lockfile-progs-source: $(DL_DIR)/$(LOCKFILE_PROGS_SOURCE)
+define LOCKFILE_PROGS_BUILD_CMDS
+ $(MAKE) $(TARGET_CONFIGURE_OPTS) -C $(@D)
+endef
-$(LOCKFILE_PROGS_DIR)/.unpacked: $(DL_DIR)/$(LOCKFILE_PROGS_SOURCE)
- $(LOCKFILE_PROGS_CAT) $(DL_DIR)/$(LOCKFILE_PROGS_SOURCE) | tar -C $(BUILD_DIR) $(TAR_OPTIONS) -
- toolchain/patch-kernel.sh $(LOCKFILE_PROGS_DIR) package/lockfile-progs/ \*.patch
- touch $(LOCKFILE_PROGS_DIR)/.unpacked
+define LOCKFILE_PROGS_INSTALL_TARGET_CMDS
+ for i in $(LOCKFILE_BINS); do \
+ install -D -m 755 $(@D)/bin/$$i $(TARGET_DIR)/usr/bin/$$i; \
+ done
+endef
-$(TARGET_DIR)/$(LOCKFILE_PROGS_BINARY): $(LOCKFILE_PROGS_DIR)/.unpacked
- $(MAKE) $(TARGET_CONFIGURE_OPTS) -C $(LOCKFILE_PROGS_DIR)
- cp -a $(LOCKFILE_PROGS_DIR)/bin/lockfile* $(TARGET_DIR)/usr/bin
- $(STRIPCMD) $(STRIP_STRIP_UNNEEDED) $(TARGET_DIR)/$(LOCKFILE_PROGS_BINARY)
+define LOCKFILE_PROGS_UNINSTALL_TARGET_CMDS
+ rm -f $(addprefix $(TARGET_DIR)/usr/bin/,$(LOCKFILE_BINS))
+endef
-lockfile-progs: liblockfile $(TARGET_DIR)/$(LOCKFILE_PROGS_BINARY)
+define LOCKFILE_PROGS_CLEAN_CMDS
+ -$(MAKE) -C $(@D) clean
+endef
-lockfile-progs-clean:
- -rm -f $(TARGET_DIR)/usr/bin/lockfile-*
- -$(MAKE) -C $(LOCKFILE_PROGS_DIR) clean
-
-lockfile-progs-dirclean:
- rm -rf $(LOCKFILE_PROGS_DIR)
-
-#############################################################
-#
-# Toplevel Makefile options
-#
-#############################################################
-ifeq ($(BR2_PACKAGE_LOCKFILE_PROGS),y)
-TARGETS+=lockfile-progs
-endif
+$(eval $(call GENTARGETS,package,lockfile-progs))