Last change
on this file since 145 was
120,
checked in by (none), 14 years ago
|
Added the mail files for the Hadoop JUNit Project
|
-
Property svn:executable set to
*
|
File size:
980 bytes
|
Line | |
---|
1 | BIN := classes |
---|
2 | HADOOP_DIR := hadoop-0.20.1 |
---|
3 | HADOOP_CONF := $(HADOOP_DIR)/conf |
---|
4 | HADOOP_BIN := $(HADOOP_DIR)/bin |
---|
5 | HADOOP_LOGS := $(HADOOP_DIR)/logs |
---|
6 | |
---|
7 | JAR_FILE := junit-runner-0.1.jar |
---|
8 | HADOOP_JARS := $(shell find . -name \*.jar | tr '\n' ':') |
---|
9 | HADOOP_OPTS := -Dhadoop.log.dir=$(HADOOP_LOGS) -Dhadoop.log.file=hadoop.log -Dhadoop.home.dir=$(HADOOP_DIR) -Dhadoop.id.str= -Dhadoop.root.logger=INFO,console |
---|
10 | # conf/ dir should be in class path (ref. org.apache.hadoop.conf.Configuration) |
---|
11 | CLASSPATH := $(CLASSPATH):$(BIN)/:$(HADOOP_JARS):$(HADOOP_CONF) |
---|
12 | |
---|
13 | run: build |
---|
14 | rm -rf /tmp/junit_* |
---|
15 | java -Xmx1000m $(HADOOP_OPTS) org.junit.runner.JUnitCore TestAdd |
---|
16 | |
---|
17 | build: |
---|
18 | javac src/*.java -d $(BIN)/ |
---|
19 | jar cf $(JAR_FILE) $(BIN)/Hadoop*.class $(BIN)/Base64.class |
---|
20 | |
---|
21 | clean: |
---|
22 | rm -rf $(BIN)/* |
---|
23 | |
---|
24 | # setup hadoop |
---|
25 | setup: shutdown |
---|
26 | sudo rm -rf /tmp/hadoop* |
---|
27 | rm -rf $(HADOOP_LOGS)/* |
---|
28 | $(HADOOP_BIN)/hadoop namenode -format |
---|
29 | $(HADOOP_BIN)/start-all.sh |
---|
30 | |
---|
31 | shutdown: |
---|
32 | $(HADOOP_BIN)/stop-all.sh |
---|
33 | #sudo killall -9 java || true |
---|
34 | |
---|
Note: See
TracBrowser
for help on using the repository browser.