如何區分makefile中的哪些目標以及如何在內部調用它們(時)?我有一個具有實際變量的目標數量的makefile。makefile內部調用目標
UPD:這裏有一個例子
build_dir := $(bin_dir)/build
xpi_built := $(build_dir)/$(install_rdf) \
$(build_dir)/$(chrome_manifest) \
$(chrome_jar_file) \
$(default_prefs)/*
xpi_built_no_dir := $(subst $(build_dir)/,,$(xpi_built))
.PHONY: install
install: $(build_dir) $(xpi_built)
@echo "Installing in profile folder: $(profile_location)"
@cp -Rf $(build_dir)/* $(profile_location)
@echo "Installing in profile folder. Done!"
@echo
$(xpi_file): $(build_dir) $(xpi_built)
@echo "Creating XPI file."
@cd $(build_dir); $(ZIP) -r ../$(xpi_file) $(xpi_built_no_dir)
@echo "Creating XPI file. Done!"
@cp update.rdf $(bin_dir)/
@cp -u *.xhtml $(bin_dir)/
@cp -Rf $(default_prefs) $(build_dir)/; \
$(build_dir)/%: %
cp -f $< [email protected]
$(build_dir):
@if [ ! -x $(build_dir) ]; \
then \
mkdir $(build_dir); \
fi
很好。現在在你的問題的文本中,你應該參考這個例子來解釋你在問什麼。 – 2010-05-02 15:18:36