Makefile
author Oleksandr Gavenko <gavenkoa@gmail.com>
Wed, 04 Feb 2015 23:43:38 +0200
changeset 1202 17ed3f571ca4
parent 1199 dff272add01e
child 1209 aa1de5eb3665
permissions -rw-r--r--
Add shortcut for recentf.
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
279
fd6164dfec82 Update copyright statement and year.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 275
diff changeset
     1
# Copyright (C) 2008-2010 by Oleksandr Gavenko <gavenkoa@gmail.com>
fd6164dfec82 Update copyright statement and year.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 275
diff changeset
     2
#
fd6164dfec82 Update copyright statement and year.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 275
diff changeset
     3
# You can do anything with this file without any warranty.
43
7c9cd891400b Added makefile to install dot-emacs.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
     4
1002
73a5303842e3 Delete target file if command fails.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 908
diff changeset
     5
73a5303842e3 Delete target file if command fails.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 908
diff changeset
     6
################################################################
73a5303842e3 Delete target file if command fails.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 908
diff changeset
     7
# Standard Makefile settings.
73a5303842e3 Delete target file if command fails.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 908
diff changeset
     8
536
14583eae4848 Added standard Makefile settings.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 518
diff changeset
     9
SHELL = /bin/sh
678
203ac8ba3934 Add work-around for PATH. Under Windows find.exe going in collision with
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 581
diff changeset
    10
export PATH := /bin:/usr/bin:${PATH}
536
14583eae4848 Added standard Makefile settings.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 518
diff changeset
    11
14583eae4848 Added standard Makefile settings.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 518
diff changeset
    12
# Disable built in pattern rules.
14583eae4848 Added standard Makefile settings.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 518
diff changeset
    13
MAKEFLAGS += -r
14583eae4848 Added standard Makefile settings.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 518
diff changeset
    14
# Disable built in variables.
14583eae4848 Added standard Makefile settings.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 518
diff changeset
    15
MAKEFLAGS += -R
14583eae4848 Added standard Makefile settings.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 518
diff changeset
    16
# Disable built in suffix rules.
14583eae4848 Added standard Makefile settings.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 518
diff changeset
    17
.SUFFIXES:
1002
73a5303842e3 Delete target file if command fails.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 908
diff changeset
    18
# Delete target file if command fails.
73a5303842e3 Delete target file if command fails.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 908
diff changeset
    19
.DELETE_ON_ERROR:
536
14583eae4848 Added standard Makefile settings.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 518
diff changeset
    20
# Default target.
14583eae4848 Added standard Makefile settings.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 518
diff changeset
    21
.DEFAULT_GOAL = all
14583eae4848 Added standard Makefile settings.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 518
diff changeset
    22
518
576a7e0fd9e0 Prefer native Windows Emacs, so use it if available.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 386
diff changeset
    23
################################################################
576a7e0fd9e0 Prefer native Windows Emacs, so use it if available.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 386
diff changeset
    24
# Helper definition.
576a7e0fd9e0 Prefer native Windows Emacs, so use it if available.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 386
diff changeset
    25
576a7e0fd9e0 Prefer native Windows Emacs, so use it if available.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 386
diff changeset
    26
which = $(firstword $(foreach item,$(subst :, ,$(PATH)),$(wildcard $(item)/$1)))
576a7e0fd9e0 Prefer native Windows Emacs, so use it if available.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 386
diff changeset
    27
576a7e0fd9e0 Prefer native Windows Emacs, so use it if available.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 386
diff changeset
    28
################################################################
576a7e0fd9e0 Prefer native Windows Emacs, so use it if available.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 386
diff changeset
    29
# Platform/environment definition.
576a7e0fd9e0 Prefer native Windows Emacs, so use it if available.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 386
diff changeset
    30
43
7c9cd891400b Added makefile to install dot-emacs.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    31
ifeq '' '$(HOME)'
7c9cd891400b Added makefile to install dot-emacs.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    32
  $(error Home env var not set!)
7c9cd891400b Added makefile to install dot-emacs.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    33
endif
7c9cd891400b Added makefile to install dot-emacs.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    34
379
271ed5d61644 Special case for Windows if emacs-nox from Cygwin installed along with native Emacs.
user@localhost
parents: 318
diff changeset
    35
host_os = unix
271ed5d61644 Special case for Windows if emacs-nox from Cygwin installed along with native Emacs.
user@localhost
parents: 318
diff changeset
    36
ifneq '' '$(COMSPEC)'
752
079c2e27357a Add terget to convert RST to HTML.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 750
diff changeset
    37
  ifneq '' '$(WINDIR)'
079c2e27357a Add terget to convert RST to HTML.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 750
diff changeset
    38
    # Probably under Windows.
079c2e27357a Add terget to convert RST to HTML.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 750
diff changeset
    39
    host_os = windows
079c2e27357a Add terget to convert RST to HTML.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 750
diff changeset
    40
  endif
379
271ed5d61644 Special case for Windows if emacs-nox from Cygwin installed along with native Emacs.
user@localhost
parents: 318
diff changeset
    41
endif
271ed5d61644 Special case for Windows if emacs-nox from Cygwin installed along with native Emacs.
user@localhost
parents: 318
diff changeset
    42
752
079c2e27357a Add terget to convert RST to HTML.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 750
diff changeset
    43
################################################################
1199
dff272add01e Move all configs to "~/.emacs.d/my".
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1150
diff changeset
    44
# Installation directories.
dff272add01e Move all configs to "~/.emacs.d/my".
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1150
diff changeset
    45
dff272add01e Move all configs to "~/.emacs.d/my".
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1150
diff changeset
    46
emacsdir := $(HOME)/.emacs.d
dff272add01e Move all configs to "~/.emacs.d/my".
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1150
diff changeset
    47
mylispdir := $(emacsdir)/my
dff272add01e Move all configs to "~/.emacs.d/my".
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1150
diff changeset
    48
dff272add01e Move all configs to "~/.emacs.d/my".
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1150
diff changeset
    49
################################################################
752
079c2e27357a Add terget to convert RST to HTML.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 750
diff changeset
    50
# Build tool definition/switches.
079c2e27357a Add terget to convert RST to HTML.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 750
diff changeset
    51
379
271ed5d61644 Special case for Windows if emacs-nox from Cygwin installed along with native Emacs.
user@localhost
parents: 318
diff changeset
    52
EMACS = emacs
518
576a7e0fd9e0 Prefer native Windows Emacs, so use it if available.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 386
diff changeset
    53
# I prefer native Windows Emacs, so use it if available.
379
271ed5d61644 Special case for Windows if emacs-nox from Cygwin installed along with native Emacs.
user@localhost
parents: 318
diff changeset
    54
ifeq 'windows' '$(host_os)'
518
576a7e0fd9e0 Prefer native Windows Emacs, so use it if available.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 386
diff changeset
    55
  ifneq '' '$(call which,runemacs.exe)'
576a7e0fd9e0 Prefer native Windows Emacs, so use it if available.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 386
diff changeset
    56
    EMACS = runemacs
576a7e0fd9e0 Prefer native Windows Emacs, so use it if available.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 386
diff changeset
    57
  endif
379
271ed5d61644 Special case for Windows if emacs-nox from Cygwin installed along with native Emacs.
user@localhost
parents: 318
diff changeset
    58
endif
271ed5d61644 Special case for Windows if emacs-nox from Cygwin installed along with native Emacs.
user@localhost
parents: 318
diff changeset
    59
752
079c2e27357a Add terget to convert RST to HTML.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 750
diff changeset
    60
RST2HTML = rst2html
079c2e27357a Add terget to convert RST to HTML.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 750
diff changeset
    61
ifeq '$(host_os)' 'windows'
079c2e27357a Add terget to convert RST to HTML.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 750
diff changeset
    62
  RST2HTML = rst2html.py
079c2e27357a Add terget to convert RST to HTML.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 750
diff changeset
    63
endif
079c2e27357a Add terget to convert RST to HTML.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 750
diff changeset
    64
079c2e27357a Add terget to convert RST to HTML.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 750
diff changeset
    65
################################################################
079c2e27357a Add terget to convert RST to HTML.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 750
diff changeset
    66
# Proj dirs/files.
079c2e27357a Add terget to convert RST to HTML.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 750
diff changeset
    67
1082
964519e5a5ac maven-central helper.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1060
diff changeset
    68
EL_FILES := $(wildcard *-mode.el) debian-doc.el maven-central.el
752
079c2e27357a Add terget to convert RST to HTML.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 750
diff changeset
    69
079c2e27357a Add terget to convert RST to HTML.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 750
diff changeset
    70
RST_FILES := $(wildcard *.rst)
079c2e27357a Add terget to convert RST to HTML.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 750
diff changeset
    71
HTML_FILES := $(RST_FILES:.rst=.html)
079c2e27357a Add terget to convert RST to HTML.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 750
diff changeset
    72
518
576a7e0fd9e0 Prefer native Windows Emacs, so use it if available.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 386
diff changeset
    73
################################################################
576a7e0fd9e0 Prefer native Windows Emacs, so use it if available.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 386
diff changeset
    74
# Targets.
576a7e0fd9e0 Prefer native Windows Emacs, so use it if available.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 386
diff changeset
    75
260
437507e141b4 Write .PHONY exactly before target.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 165
diff changeset
    76
.PHONY: all
43
7c9cd891400b Added makefile to install dot-emacs.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    77
all: install
7c9cd891400b Added makefile to install dot-emacs.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    78
750
db9827b0fdf5 Add some headlines.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 700
diff changeset
    79
################################################################
db9827b0fdf5 Add some headlines.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 700
diff changeset
    80
# Install/uninstall targets.
db9827b0fdf5 Add some headlines.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 700
diff changeset
    81
1199
dff272add01e Move all configs to "~/.emacs.d/my".
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1150
diff changeset
    82
.PHONY: upgrade
dff272add01e Move all configs to "~/.emacs.d/my".
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1150
diff changeset
    83
upgrade:
dff272add01e Move all configs to "~/.emacs.d/my".
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1150
diff changeset
    84
	\
dff272add01e Move all configs to "~/.emacs.d/my".
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1150
diff changeset
    85
if [ ! -d $(mylispdir) ]; then \
dff272add01e Move all configs to "~/.emacs.d/my".
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1150
diff changeset
    86
  if [ -d $(emacsdir)/my-lisp ]; then \
dff272add01e Move all configs to "~/.emacs.d/my".
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1150
diff changeset
    87
    rm -f $(emacsdir)/autoload-my.el; \
dff272add01e Move all configs to "~/.emacs.d/my".
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1150
diff changeset
    88
    mv $(emacsdir)/my-lisp $(mylispdir); \
dff272add01e Move all configs to "~/.emacs.d/my".
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1150
diff changeset
    89
  else \
dff272add01e Move all configs to "~/.emacs.d/my".
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1150
diff changeset
    90
    mkdir -p $(mylispdir); \
dff272add01e Move all configs to "~/.emacs.d/my".
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1150
diff changeset
    91
  fi; \
dff272add01e Move all configs to "~/.emacs.d/my".
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1150
diff changeset
    92
  mv ~/.emacs-my $(mylispdir)/.emacs || true; \
dff272add01e Move all configs to "~/.emacs.d/my".
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1150
diff changeset
    93
  mv ~/.emacs-custom.el $(mylispdir)/.emacs-custom || true; \
dff272add01e Move all configs to "~/.emacs.d/my".
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1150
diff changeset
    94
  mv ~/.emacs-pre $(mylispdir) || true; \
dff272add01e Move all configs to "~/.emacs.d/my".
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1150
diff changeset
    95
  mv ~/.emacs-post $(mylispdir) || true; \
dff272add01e Move all configs to "~/.emacs.d/my".
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1150
diff changeset
    96
  mv ~/.emacs-places $(mylispdir) || true; \
dff272add01e Move all configs to "~/.emacs.d/my".
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1150
diff changeset
    97
  mv ~/.emacs.desktop $(mylispdir) || true; \
dff272add01e Move all configs to "~/.emacs.d/my".
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1150
diff changeset
    98
  rm -f ~/.emacs-autogen; \
dff272add01e Move all configs to "~/.emacs.d/my".
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1150
diff changeset
    99
fi
dff272add01e Move all configs to "~/.emacs.d/my".
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1150
diff changeset
   100
268
b2cd8fbe5ec3 Install mode file under '.emacs.d' dir.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 267
diff changeset
   101
.PHONY: install-all
b2cd8fbe5ec3 Install mode file under '.emacs.d' dir.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 267
diff changeset
   102
install-all: install
1199
dff272add01e Move all configs to "~/.emacs.d/my".
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1150
diff changeset
   103
	cp .emacs-pre $(mylispdir)/.emacs-pre
dff272add01e Move all configs to "~/.emacs.d/my".
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1150
diff changeset
   104
	cp .emacs-post $(mylispdir)/.emacs-post
164
d7ed163b397e Added installation of template for -pre/-post scripts.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 111
diff changeset
   105
268
b2cd8fbe5ec3 Install mode file under '.emacs.d' dir.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 267
diff changeset
   106
.PHONY: install
1199
dff272add01e Move all configs to "~/.emacs.d/my".
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1150
diff changeset
   107
install:
dff272add01e Move all configs to "~/.emacs.d/my".
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1150
diff changeset
   108
	mkdir -p $(mylispdir)
dff272add01e Move all configs to "~/.emacs.d/my".
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1150
diff changeset
   109
	find $(mylispdir) -type f -name '*.el' -delete
111
fcea9d3b79e1 Rename -my{-pre/-post} to {-pre/-post}.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 103
diff changeset
   110
	for file in .emacs-pre .emacs-post; do \
1199
dff272add01e Move all configs to "~/.emacs.d/my".
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1150
diff changeset
   111
		[ -f $(mylispdir)/$$file ] || cp $$file $(mylispdir)/$$file; \
93
99f967be941a Rename files .emacs-my-custom* to .emacs-my*.
"Oleksandr Gavenko <gavenkoa@gmail.com>"
parents: 45
diff changeset
   112
	done
103
7c16c6cab2b0 By default .emacs also overwrite.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 96
diff changeset
   113
	cp .emacs $(HOME)/.emacs
1199
dff272add01e Move all configs to "~/.emacs.d/my".
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1150
diff changeset
   114
	cp .emacs-my $(mylispdir)/.emacs-my
908
e3b3e9f4d759 New scoring rules.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 833
diff changeset
   115
	mkdir -p $(HOME)/.gnus/scores
e3b3e9f4d759 New scoring rules.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 833
diff changeset
   116
	cp all.SCORE $(HOME)/.gnus/scores
1060
53526ea61f74 Add autoloads to debian-doc.el.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1008
diff changeset
   117
	for file in $(EL_FILES); do \
1199
dff272add01e Move all configs to "~/.emacs.d/my".
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1150
diff changeset
   118
		cp -f $$file $(mylispdir); \
164
d7ed163b397e Added installation of template for -pre/-post scripts.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 111
diff changeset
   119
	done
1199
dff272add01e Move all configs to "~/.emacs.d/my".
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1150
diff changeset
   120
	$(EMACS) -Q --batch --eval='(let ((generated-autoload-file "$(mylispdir)/loaddefs.el")) (update-directory-autoloads "$(mylispdir)"))'
dff272add01e Move all configs to "~/.emacs.d/my".
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1150
diff changeset
   121
	./.emacs-autogen.sh $(mylispdir)/.emacs-autogen
1150
dad3fb58f710 Add srecode templates.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1082
diff changeset
   122
	cp -r srecode/ $(HOME)/.emacs.d/
164
d7ed163b397e Added installation of template for -pre/-post scripts.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 111
diff changeset
   123
269
81c80df45b37 Udded uninstall target.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 268
diff changeset
   124
.PHONY: uninstall
81c80df45b37 Udded uninstall target.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 268
diff changeset
   125
uninstall:
1199
dff272add01e Move all configs to "~/.emacs.d/my".
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1150
diff changeset
   126
	rm -f $(HOME)/.emacs $(mylispdir)/.emacs-my $(mylispdir)/.emacs-autogen
dff272add01e Move all configs to "~/.emacs.d/my".
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1150
diff changeset
   127
	find $(mylispdir) -type f -name '*.el' -delete
dff272add01e Move all configs to "~/.emacs.d/my".
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1150
diff changeset
   128
	rm -f -r $(emacsdir)/srecode
269
81c80df45b37 Udded uninstall target.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 268
diff changeset
   129
260
437507e141b4 Write .PHONY exactly before target.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 165
diff changeset
   130
.PHONY: tar
165
9f5dd505a4cf Correct target name.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 164
diff changeset
   131
tar:
85
2bb7e6aceac9 Added target dist-tar.
gavenkoa@gavenko.bifit.int
parents: 45
diff changeset
   132
	tar cf dot-emacs.tar .emacs .emacs-my
86
0cf1b0216dac Added target clean.
gavenkoa@gavenko.bifit.int
parents: 85
diff changeset
   133
750
db9827b0fdf5 Add some headlines.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 700
diff changeset
   134
################################################################
752
079c2e27357a Add terget to convert RST to HTML.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 750
diff changeset
   135
# Documentation targets.
079c2e27357a Add terget to convert RST to HTML.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 750
diff changeset
   136
079c2e27357a Add terget to convert RST to HTML.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 750
diff changeset
   137
.PHONY: html
079c2e27357a Add terget to convert RST to HTML.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 750
diff changeset
   138
html: $(HTML_FILES)
079c2e27357a Add terget to convert RST to HTML.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 750
diff changeset
   139
079c2e27357a Add terget to convert RST to HTML.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 750
diff changeset
   140
$(HTML_FILES): %.html: %.rst
079c2e27357a Add terget to convert RST to HTML.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 750
diff changeset
   141
	$(RST2HTML) --stylesheet=rst.css $*.rst $@
079c2e27357a Add terget to convert RST to HTML.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 750
diff changeset
   142
079c2e27357a Add terget to convert RST to HTML.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 750
diff changeset
   143
################################################################
750
db9827b0fdf5 Add some headlines.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 700
diff changeset
   144
# Clean targets.
db9827b0fdf5 Add some headlines.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 700
diff changeset
   145
260
437507e141b4 Write .PHONY exactly before target.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 165
diff changeset
   146
.PHONY: distclean
437507e141b4 Write .PHONY exactly before target.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 165
diff changeset
   147
distclean: clean
437507e141b4 Write .PHONY exactly before target.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 165
diff changeset
   148
437507e141b4 Write .PHONY exactly before target.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 165
diff changeset
   149
.PHONY: clean
86
0cf1b0216dac Added target clean.
gavenkoa@gavenko.bifit.int
parents: 85
diff changeset
   150
clean:
752
079c2e27357a Add terget to convert RST to HTML.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 750
diff changeset
   151
	rm -f dot-emacs.tar $(HTML_FILES)