emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[nongnu] elpa/caml aba3de4 05/14: Subtler detection of Emacs executable


From: ELPA Syncer
Subject: [nongnu] elpa/caml aba3de4 05/14: Subtler detection of Emacs executable
Date: Tue, 24 Aug 2021 05:57:22 -0400 (EDT)

branch: elpa/caml
commit aba3de4469d7c1976633bf3c8812faa4ae762b1b
Author: Christophe Troestler <Christophe.Troestler@umons.ac.be>
Commit: Christophe Troestler <Christophe.Troestler@umons.ac.be>

    Subtler detection of Emacs executable
---
 Makefile | 19 ++++++++++++++++++-
 1 file changed, 18 insertions(+), 1 deletion(-)

diff --git a/Makefile b/Makefile
index a8c19b1..53b0761 100644
--- a/Makefile
+++ b/Makefile
@@ -31,7 +31,24 @@ DIST_FILES = $(FILES) Makefile README* COPYING* CHANGES.md 
ocamltags.in
 #EMACSDIR=
 
 # Name of Emacs executable
-EMACS=emacs
+EMACSFORMACOSX = /Applications/Emacs.app/Contents/MacOS/Emacs
+EMACSMACPORTS = /Applications/MacPorts/Emacs.app/Contents/MacOS/Emacs
+AQUAMACS = $(shell test -d /Applications \
+       && find /Applications -type f | grep 'Aquamacs$$')
+ifeq ($(wildcard $(EMACSFORMACOSX)),$(EMACSFORMACOSX))
+EMACS ?= $(EMACSFORMACOSX)
+else
+ifeq ($(wildcard $(EMACSMACPORTS)),$(EMACSMACPORTS))
+EMACS ?= $(EMACSMACPORTS)
+else
+ifneq ($(strip $(AQUAMACS)),)
+ifeq ($(wildcard $(AQUAMACS)),$(AQUAMACS))
+EMACS ?= $(AQUAMACS)
+endif
+endif
+endif
+endif
+EMACS ?= emacs
 
 # Where to install ocamltags script
 SCRIPTDIR = $(BINDIR)



reply via email to

[Prev in Thread] Current Thread [Next in Thread]