Makefile 869 B

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. manifest = R$(if $(LOCAL),-local,).manifest
  2. target =
  3. exec_target = $(manifest)
  4. clean-extra = clean-local
  5. level = ../../
  6. include ../../Makefile
  7. local:
  8. make LOCAL=1
  9. R_SRC = R-3.1.2
  10. R_INSTALL = $(R_SRC)/build
  11. $(R_INSTALL)/lib/R/bin/exec/R: $(R_SRC)/Makefile
  12. cd $(R_SRC) && $(MAKE)
  13. cd $(R_SRC) && $(MAKE) install
  14. $(R_SRC)/Makefile: $(R_SRC)/configure
  15. cd $(R_SRC) && \
  16. ./configure --prefix=$(shell readlink -f $(R_INSTALL))
  17. $(R_SRC)/configure: $(R_SRC).tar.gz
  18. tar -xzf $<
  19. test_targets =
  20. test: all $(test_targets)
  21. R.manifest: R.manifest.template
  22. $(MAKE) -C .. r/$@ appdir=r/
  23. R-local.manifest: R-local.manifest.template $(R_INSTALL)/lib/R/bin/exec/R
  24. $(MAKE) -C .. r/$@ appdir=r/ \
  25. extra_rules="-e 's:\\\$$\$$(RDIR):$(shell readlink -f $(R_INSTALL)/lib/R)/:g'"
  26. distclean: clean
  27. rm -rf $(R_SRC)
  28. clean-local:
  29. ifneq ($(LOCAL),1)
  30. make clean LOCAL=1
  31. endif