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

Commit

Permalink
Consistency of naming; correction of pa path (previously even the dir…
Browse files Browse the repository at this point in the history
…ect remote tests were being supplied with a pa path which included the broker); correction of dependencies in construction of packages (never depend on a directory)
  • Loading branch information
Matthew Sackman committed Jan 28, 2011
1 parent 026250f commit 5f4d0f1
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 10 deletions.
7 changes: 3 additions & 4 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -86,10 +86,8 @@ $(TEST_DIR): $(DEPS_DIR)/$(COMMON_PACKAGE_DIR)

COPY=cp -pR

$(DIST_DIR)/$(COMMON_PACKAGE_EZ): $(DIST_DIR)/$(COMMON_PACKAGE_DIR) | $(DIST_DIR)
(cd $(DIST_DIR); zip -r $(COMMON_PACKAGE_EZ) $(COMMON_PACKAGE_DIR))

$(DIST_DIR)/$(COMMON_PACKAGE_DIR): $(BROKER_DEPS) $(COMMON_PACKAGE).app | $(DIST_DIR)
$(DIST_DIR)/$(COMMON_PACKAGE_EZ): $(BROKER_DEPS) $(COMMON_PACKAGE).app | $(DIST_DIR)
rm -f $@
$(MAKE) -C $(BROKER_DIR)
rm -rf $(DIST_DIR)/$(COMMON_PACKAGE_DIR)
mkdir -p $(DIST_DIR)/$(COMMON_PACKAGE_DIR)/$(INCLUDE_DIR)
Expand All @@ -99,6 +97,7 @@ $(DIST_DIR)/$(COMMON_PACKAGE_DIR): $(BROKER_DEPS) $(COMMON_PACKAGE).app | $(DIST
( cp $(BROKER_DIR)/ebin/$(DEP).beam $(DIST_DIR)/$(COMMON_PACKAGE_DIR)/$(EBIN_DIR)/ \
);)
cp $(BROKER_DIR)/include/*.hrl $(DIST_DIR)/$(COMMON_PACKAGE_DIR)/$(INCLUDE_DIR)/
(cd $(DIST_DIR); zip -r $(COMMON_PACKAGE_EZ) $(COMMON_PACKAGE_DIR))

source_tarball: $(DIST_DIR)/$(COMMON_PACKAGE_EZ) $(EBIN_DIR)/$(PACKAGE).app | $(DIST_DIR)
mkdir -p $(DIST_DIR)/$(SOURCE_PACKAGE_DIR)/$(DIST_DIR)
Expand Down
9 changes: 4 additions & 5 deletions common.mk
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ else
LIBS_PATH=ERL_LIBS=$(LIBS_PATH_UNIX)
endif

LOAD_PATH=$(EBIN_DIR) $(BROKER_DIR)/ebin $(TEST_DIR) $(ERL_PATH)
LOAD_PATH=$(EBIN_DIR) $(TEST_DIR) $(ERL_PATH)

RUN:=$(LIBS_PATH) erl -pa $(LOAD_PATH) -sname amqp_client

Expand Down Expand Up @@ -150,17 +150,16 @@ run: compile
## Packaging
###############################################################################

$(DIST_DIR)/$(PACKAGE_NAME_EZ): $(DIST_DIR)/$(PACKAGE_DIR) | $(DIST_DIR)
(cd $(DIST_DIR); zip -r $(PACKAGE_NAME_EZ) $(PACKAGE_DIR))

$(DIST_DIR)/$(PACKAGE_DIR): $(TARGETS) $(EBIN_DIR)/$(PACKAGE).app | $(DIST_DIR)
$(DIST_DIR)/$(PACKAGE_NAME_EZ): $(TARGETS) $(EBIN_DIR)/$(PACKAGE).app | $(DIST_DIR)
rm -f $@
rm -rf $(DIST_DIR)/$(PACKAGE_DIR)
mkdir -p $(DIST_DIR)/$(PACKAGE_DIR)/$(EBIN_DIR)
mkdir -p $(DIST_DIR)/$(PACKAGE_DIR)/$(INCLUDE_DIR)
cp -r $(EBIN_DIR)/*.beam $(DIST_DIR)/$(PACKAGE_DIR)/$(EBIN_DIR)
cp -r $(EBIN_DIR)/*.app $(DIST_DIR)/$(PACKAGE_DIR)/$(EBIN_DIR)
mkdir -p $(DIST_DIR)/$(PACKAGE_DIR)/$(INCLUDE_DIR)
cp -r $(INCLUDE_DIR)/* $(DIST_DIR)/$(PACKAGE_DIR)/$(INCLUDE_DIR)
(cd $(DIST_DIR); zip -r $(PACKAGE_NAME_EZ) $(PACKAGE_DIR))

package: $(DIST_DIR)/$(PACKAGE_NAME_EZ)

Expand Down
2 changes: 1 addition & 1 deletion test.mk
Original file line number Diff line number Diff line change
Expand Up @@ -112,5 +112,5 @@ test_network_coverage: prepare_tests
test_direct_coverage: prepare_tests
$(MAKE) run_test_in_broker RUN_TEST_ARGS="-s direct_client_SUITE test_coverage"

test_direct_remote_coverage: prepare_tests
test_remote_direct_coverage: prepare_tests
$(MAKE) run_test_detached RUN_TEST_ARGS="-s direct_client_SUITE test_coverage"

0 comments on commit 5f4d0f1

Please sign in to comment.