mirror of
https://git.savannah.gnu.org/git/emacs/org-mode.git
synced 2024-11-29 07:58:21 +00:00
b567341443
* lisp/Makefile: remove stop targets, make autoloads depend on source files again (not .PHONY). Keep autoload files around after compile, but make sure to re-create them before installation and compile. Remove autoload files before re-creating them to avoid errors from Emacs when saving the buffer. * targets.mk: remove stop targets and the mess that was necessary to support them. * default.mk: must use $(CURDIR) not $(PWD), $(PWD) is not well defined when using sudo.
49 lines
1.2 KiB
Makefile
49 lines
1.2 KiB
Makefile
.NOTPARALLEL: # always run this make serially
|
|
.SUFFIXES: # we don't need default suffix rules
|
|
ifeq ($(MAKELEVEL), 0)
|
|
$(error This make needs to be started as a sub-make from the toplevel directory.)
|
|
endif
|
|
|
|
LISPV = org-version.el
|
|
LISPI = org-install.el
|
|
LISPA = $(LISPV) $(LISPI)
|
|
LISPF = $(filter-out $(LISPA),$(wildcard *.el))
|
|
LISPC = $(LISPF:%el=%elc)
|
|
|
|
.PHONY: all compile compile-dirty \
|
|
autoloads \
|
|
install clean cleanauto cleanall clean-install
|
|
|
|
# do not clean here, done in toplevel make
|
|
all compile:: autoloads
|
|
all compile compile-dirty:: $(LISPA)
|
|
$(ELCDIR)
|
|
|
|
autoloads: cleanauto $(LISPA)
|
|
|
|
$(LISPV): $(LISPF)
|
|
@echo "org-version: $(ORGVERSION) ($(GITVERSION))"
|
|
@$(RM) $(@)
|
|
@$(MAKE_ORG_VERSION)
|
|
|
|
$(LISPI): $(LISPV) $(LISPF)
|
|
@echo "org-install: $(ORGVERSION) ($(GITVERSION))"
|
|
@$(RM) $(@)
|
|
@$(MAKE_ORG_INSTALL)
|
|
|
|
install: $(LISPF) compile
|
|
if [ ! -d $(DESTDIR)$(lispdir) ] ; then \
|
|
$(MKDIR) $(DESTDIR)$(lispdir) ; \
|
|
fi ;
|
|
$(CP) $(LISPC) $(LISPF) $(LISPA) $(DESTDIR)$(lispdir)
|
|
|
|
cleanauto clean cleanall::
|
|
$(RM) $(LISPA) $(LISPA:%el=%elc)
|
|
clean cleanall::
|
|
$(RM) *.elc
|
|
|
|
clean-install:
|
|
if [ -d $(DESTDIR)$(lispdir) ] ; then \
|
|
$(RM) $(DESTDIR)$(lispdir)/org*.el* $(DESTDIR)$(lispdir)/ob*.el* ; \
|
|
fi ;
|