1999-11-17 10:59:06 -08:00
|
|
|
# $Id$
|
|
|
|
|
1999-10-18 02:40:46 -07:00
|
|
|
include ../config/Makefile
|
|
|
|
|
1997-02-23 08:24:53 -08:00
|
|
|
# Files to install
|
1998-12-16 01:32:04 -08:00
|
|
|
FILES= caml-font.el caml-hilit.el caml.el camldebug.el \
|
2003-07-28 11:07:11 -07:00
|
|
|
inf-caml.el caml-compat.el caml-help.el caml-types.el \
|
2003-07-31 06:39:42 -07:00
|
|
|
caml-xemacs.el caml-emacs.el
|
1997-02-23 08:24:53 -08:00
|
|
|
|
|
|
|
# Where to install. If empty, automatically determined.
|
1997-06-12 08:25:38 -07:00
|
|
|
#EMACSDIR=
|
1997-02-23 08:24:53 -08:00
|
|
|
|
|
|
|
# Name of Emacs executable
|
|
|
|
EMACS=emacs
|
|
|
|
|
1998-12-16 01:32:04 -08:00
|
|
|
# Where to install ocamltags script
|
1999-10-18 02:40:46 -07:00
|
|
|
SCRIPTDIR = $(BINDIR)
|
1998-12-16 01:32:04 -08:00
|
|
|
|
1997-02-23 08:24:53 -08:00
|
|
|
# Command for byte-compiling the files
|
|
|
|
COMPILECMD=(progn \
|
|
|
|
(setq load-path (cons "." load-path)) \
|
2003-08-25 08:01:20 -07:00
|
|
|
(byte-compile-file "caml-xemacs.el") \
|
|
|
|
(byte-compile-file "caml-emacs.el") \
|
1997-02-23 08:24:53 -08:00
|
|
|
(byte-compile-file "caml.el") \
|
|
|
|
(byte-compile-file "inf-caml.el") \
|
2002-03-19 01:45:46 -08:00
|
|
|
(byte-compile-file "caml-help.el") \
|
1997-02-23 08:24:53 -08:00
|
|
|
(byte-compile-file "camldebug.el"))
|
|
|
|
|
|
|
|
install:
|
|
|
|
@if test "$(EMACSDIR)" = ""; then \
|
1997-07-02 11:16:15 -07:00
|
|
|
set xxx `($(EMACS) --batch --eval "(mapcar 'print load-path)") \
|
|
|
|
2>/dev/null | \
|
|
|
|
sed -n -e '/\/site-lisp/s/"//gp'`; \
|
|
|
|
if test "$$2" = ""; then \
|
1997-02-23 08:24:53 -08:00
|
|
|
echo "Cannot determine Emacs site-lisp directory"; \
|
|
|
|
exit 2; \
|
|
|
|
fi; \
|
1997-07-02 11:16:15 -07:00
|
|
|
$(MAKE) EMACSDIR="$$2" simple-install; \
|
1997-02-23 08:24:53 -08:00
|
|
|
else \
|
|
|
|
$(MAKE) simple-install; \
|
|
|
|
fi
|
|
|
|
|
1999-01-31 17:55:27 -08:00
|
|
|
simple-install:
|
1997-02-23 08:24:53 -08:00
|
|
|
@echo "Installing in $(EMACSDIR)..."
|
1997-08-26 08:21:16 -07:00
|
|
|
if test -d $(EMACSDIR); then : ; else mkdir -p $(EMACSDIR); fi
|
1997-02-23 08:24:53 -08:00
|
|
|
cp $(FILES) $(EMACSDIR)
|
|
|
|
cd $(EMACSDIR); $(EMACS) --batch --eval '$(COMPILECMD)'
|
1999-01-31 17:55:27 -08:00
|
|
|
|
|
|
|
ocamltags: ocamltags.in
|
|
|
|
sed -e 's:@EMACS@:$(EMACS):' ocamltags.in >ocamltags
|
|
|
|
chmod a+x ocamltags
|
|
|
|
|
|
|
|
install-ocamltags: ocamltags
|
1999-10-18 02:40:46 -07:00
|
|
|
cp ocamltags $(SCRIPTDIR)/ocamltags
|
1997-02-23 08:24:53 -08:00
|
|
|
|
|
|
|
clean:
|
1998-12-16 01:32:04 -08:00
|
|
|
rm -f ocamltags *~ #*#
|