Skip to content
This repository has been archived by the owner on Nov 17, 2020. It is now read-only.

Commit

Permalink
converts plugin to rabbitmq-public-umbrella
Browse files Browse the repository at this point in the history
  • Loading branch information
videlalvaro committed Oct 14, 2011
1 parent 1673023 commit 54d7e9e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 38 deletions.
39 changes: 1 addition & 38 deletions Makefile
@@ -1,38 +1 @@
REBAR=`which rebar || echo ./rebar`
PACKAGE=rh-exchange
DIST_DIR=dist
EBIN_DIR=ebin
INCLUDE_DIRS=include
DEPS_DIR=deps
DEPS ?=
DEPS_EZ=$(foreach DEP, $(DEPS), $(DEPS_DIR)/$(DEP).ez)
RABBITMQ_HOME ?= .

all: compile

clean:
rm -rf $(DIST_DIR)
rm -rf $(EBIN_DIR)

distclean: clean
rm -rf $(DEPS_DIR)

package: compile $(DEPS_EZ)
rm -f $(DIST_DIR)/$(PACKAGE).ez
mkdir -p $(DIST_DIR)/$(PACKAGE)
cp -r $(EBIN_DIR) $(DIST_DIR)/$(PACKAGE)
$(foreach EXTRA_DIR, $(INCLUDE_DIRS), cp -r $(EXTRA_DIR) $(DIST_DIR)/$(PACKAGE);)
(cd $(DIST_DIR); zip -r $(PACKAGE).ez $(PACKAGE))

install: package
$(foreach DEP, $(DEPS_EZ), cp $(DEP) $(RABBITMQ_HOME)/plugins;)
cp $(DIST_DIR)/$(PACKAGE).ez $(RABBITMQ_HOME)/plugins

$(DEPS_DIR):
@$(REBAR) get-deps

$(DEPS_EZ):
cd $(DEPS_DIR); $(foreach DEP, $(DEPS), zip -r $(DEP).ez $(DEP);)

compile: $(DEPS_DIR)
@$(REBAR) compile
include ../umbrella.mk
2 changes: 2 additions & 0 deletions package.mk
@@ -0,0 +1,2 @@
DEPS:=rabbitmq-server rabbitmq-erlang-client

0 comments on commit 54d7e9e

Please sign in to comment.