XERCES_SERIES = 3 VERSION=3.1.1 TARFILE=xerces-c-$(VERSION).tar.gz PWD := $(shell pwd) export XERCESCROOT=$(PWD)/xerces-c-$(VERSION) all: prod_link prod_link: $(XERCESCROOT)/.make_install_done test -L prod || ln -s xerces-c-$(VERSION) prod # will not overwrite existing link $(XERCESCROOT)/.make_install_done: $(XERCESCROOT)/.make_done $(MAKE) -C$(XERCESCROOT) install date > $@ $(XERCESCROOT)/.make_done: $(XERCESCROOT)/.configure_done $(MAKE) -C$(XERCESCROOT) date > $@ $(XERCESCROOT)/.untar_done: $(TARFILE) tar zxf $(TARFILE) date > $@ $(XERCESCROOT)/.configure_done: $(XERCESCROOT)/.untar_done cd $(XERCESCROOT); ./configure --prefix=$(XERCESCROOT) date > $@ $(TARFILE): wget http://www.apache.org/dist/xerces/c/$(XERCES_SERIES)/sources/$(TARFILE)