Compiling Java with makefile

http://www.google.com.hk/search?hl=zh-CN&newwindow=1&safe=strict&q=makefile+shell+find+java&oq=makefile+shell+find+java&gs_l=serp.3...1547.3193.0.3429.5.5.0.0.0.0.0.0..0.0...0.0...1c.1.8.serp.Z_mbAZayu8w

http://www.makelinux.net/make3/make3-CHP-9-SECT-3


# all_javas - Temp file for holding source file list


#all_javas := $(OUTPUT_DIR)/all.javas
OUTPUT_DIR := .
SOURCE_DIR := libcore/luni/src/main/java
all_javas := $(OUTPUT_DIR)/all.javas
JAVAC := javac -target 1.5  -classpath "libcore/xml/src/main/java:libcore/dalvik/src/main/java:/media/linux/1/android-20120605-2.3.4_r1/classes:libcore/luni/src/main/java/:/media/linux/1/android-20120605-2.3.4_r1/libcore/luni/src/main/java/org/apache/harmony/luni/lang/reflect/" -d classes
FIND := /usr/bin/find


# compile - Compile the source


.PHONY: compile


compile: $(all_javas)


$(JAVAC) @$<
#        $(JAVAC) $(JFLAGS) @$<






# all_javas - Gather source file list


.INTERMEDIATE: $(all_javas)


$(all_javas):


$(FIND) $(SOURCE_DIR) -name '*.java' > $@


******************************************************************************

out/host/linux-x86/bin/dx  -JXmx256m --debug --dex --dump-to=classes.lst --output=classes.dex     --dump-width=1000 --core-library classes




zip core.jar classes.dex
cp core.jar out/debug/host/linux-x86/pr/sim/system/framework/
ll out/debug/host/linux-x86/pr/sim/system/framework/core.jar

 

你可能感兴趣的:(makefile)