-
Notifications
You must be signed in to change notification settings - Fork 123
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
63 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,23 +1,68 @@ | ||
EMACS = emacs | ||
BATCH = $(EMACS) -Q -batch -L . | ||
# This file is part of el.make. | ||
# | ||
# Copyright: 2024- casch-at (Christian Anders Schwarzgruber) | ||
# | ||
# Version: 0.1.0 | ||
## | ||
#### | ||
## | ||
# el.make is free software: you can redistribute it and/or modify it | ||
# under the terms of the GNU General Public License as published by the Free | ||
# Software Foundation, either version 3 of the License, or | ||
# (at your option) any later version. | ||
# | ||
# el.make is distributed in the hope that it will be useful, | ||
# but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
# GNU General Public License for more details. | ||
# | ||
# You should have received a copy of the GNU General Public License along | ||
# with el.make. If not, see <http://www.gnu.org/licenses/>. | ||
## | ||
#### | ||
## | ||
# hier koennte ihre werbung stehen | ||
# | ||
# el.make | ||
# | ||
# a GNU Emacs Lisp `make` file | ||
## | ||
|
||
export LC_ALL=C | ||
# TODO(cschwarzgruber): hmm? | ||
export LC_ALL = C | ||
|
||
all: clean compile gen-autoloads test | ||
emacs = emacs | ||
flags = -q --batch --no-site-file | ||
batch = $(emacs) $(flags) | ||
|
||
# Forcefully remove files ignored by Git. | ||
clean: | ||
git clean -Xf | ||
## test directory | ||
testdir = tests | ||
|
||
## source directory | ||
srcdir = src | ||
|
||
## all source files | ||
elfiles = $(wildcard $(srcdir)/*.el) | ||
|
||
## all test files | ||
testfiles = $(wildcard $(testdir)/*.el) | ||
|
||
## all compiled files | ||
elcfiles = $(addprefix $(srcdir)/, $(notdir $(elfiles:.el=.elc))) | ||
|
||
compile: | ||
$(BATCH) -f batch-byte-compile org-journal.el | ||
.phony: all compile test clean | ||
|
||
gen-autoloads: | ||
$(BATCH) \ | ||
--eval "(require 'autoload)" \ | ||
--eval '(setq make-backup-files nil)' \ | ||
--eval "(setq generated-autoload-file (concat command-line-default-directory \"/\" \"org-journal-autoloads.el\"))" \ | ||
-f batch-update-autoloads "." | ||
all: compile test | ||
|
||
test: | ||
$(BATCH) -l tests/org-journal-test -f ert-run-tests-batch-and-exit | ||
compile: $(elcfiles) | ||
|
||
test: $(elcfiles) | ||
@echo "running tests... " | ||
@$(batch) -L $(srcdir) -l $(testfiles) -f ert-run-tests-batch-and-exit | ||
|
||
$(srcdir)/%.elc: $(srcdir)/%.el | ||
@echo "compiling $<..." | ||
@$(batch) -f batch-byte-compile $< | ||
|
||
clean: | ||
rm -f $(elcfiles) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Makefile |
File renamed without changes.