Skip to content

Commit b5d61f6

Browse files
authored
Make separate compilation aware of non byte compiled files (#392)
1 parent 5f0a642 commit b5d61f6

File tree

3 files changed

+13
-25
lines changed

3 files changed

+13
-25
lines changed

ChangeLog

+5
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,10 @@
11
2023-10-07 Mats Lidell <[email protected]>
22

3+
* hsys-org-roam.el: Byte compile. Warning is handled by declaration.
4+
5+
* Makefile (EL_SRC): Add macro for all el-files, both compiled and not
6+
compiled.
7+
38
* hui-mini.el: Update defcustom type for hui-mini menus.
49

510
2023-10-05 Mats Lidell <[email protected]>

Makefile

+7-17
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
# Author: Bob Weiner
44
#
55
# Orig-Date: 15-Jun-94 at 03:42:38
6-
# Last-Mod: 3-Oct-23 at 15:47:37 by Mats Lidell
6+
# Last-Mod: 6-Oct-23 at 00:22:25 by Mats Lidell
77
#
88
# Copyright (C) 1994-2023 Free Software Foundation, Inc.
99
# See the file HY-COPY for license information.
@@ -185,10 +185,12 @@ EL_COMPILE = hact.el hactypes.el hargs.el hbdata.el hbmap.el hbut.el \
185185
hpath.el hrmail.el hsettings.el hsmail.el hsys-org.el hsys-org-roam.el \
186186
hsys-www.el hsys-youtube.el htz.el \
187187
hycontrol.el hui-jmenu.el hui-menu.el hui-mini.el hui-mouse.el hui-select.el \
188-
hui-treemacs.el hui-window.el hui.el hvar.el hversion.el hvm.el hypb.el hyperbole.el \
188+
hui-treemacs.el hui-window.el hui.el hvar.el hversion.el hypb.el hyperbole.el \
189189
hyrolo-demo.el hyrolo-logic.el hyrolo-menu.el hyrolo.el hywconfig.el set.el hypb-ert.el \
190190
hui-dired-sidebar.el hypb-maintenance.el hui-em-but.el hui-register.el
191191

192+
EL_SRC = $(EL_COMPILE) hvm.el
193+
192194
EL_KOTL = kotl/kexport.el kotl/kfile.el kotl/kfill.el kotl/kimport.el kotl/klabel.el \
193195
kotl/klink.el kotl/kmenu.el kotl/kotl-mode.el kotl/kotl-orgtbl.el \
194196
kotl/kcell.el kotl/kproperty.el kotl/kview.el kotl/kvspec.el
@@ -199,7 +201,7 @@ ELC_KOTL = $(EL_KOTL:.el=.elc)
199201

200202
HY-TALK = HY-TALK/.hypb HY-TALK/HYPB HY-TALK/HY-TALK.org
201203

202-
HYPERBOLE_FILES = dir info html $(EL_COMPILE) $(EL_KOTL) \
204+
HYPERBOLE_FILES = dir info html $(EL_SRC) $(EL_KOTL) \
203205
$(ELC_COMPILE) $(HY-TALK) ChangeLog COPYING Makefile HY-ABOUT HY-ANNOUNCE \
204206
HY-CONCEPTS.kotl HY-NEWS \
205207
HY-WHY.kotl INSTALL DEMO DEMO-ROLO.otl FAST-DEMO MANIFEST README README.md TAGS _hypb \
@@ -208,7 +210,7 @@ HYPERBOLE_FILES = dir info html $(EL_COMPILE) $(EL_KOTL) \
208210

209211
TEST_ERT_FILES = $(wildcard test/*tests.el) $(wildcard test/hy-test-*.el)
210212

211-
EL_TAGS = $(EL_COMPILE) $(EL_KOTL) $(TEST_ERT_FILES)
213+
EL_TAGS = $(EL_SRC) $(EL_KOTL) $(TEST_ERT_FILES)
212214

213215
.SUFFIXES: # Delete the default suffixes
214216
.SUFFIXES: .el .elc # Define the list of file suffixes to match to rules
@@ -319,24 +321,12 @@ remove-elc:
319321

320322
# Remove and then rebuild all byte-compiled .elc files, even those .elc files
321323
# which do not yet exist, plus build TAGS file.
322-
#
323-
# Use this to suppress docstring warnings.
324-
# $(EMACS_BATCH) --eval="(setq-default byte-compile-warnings '(not docstrings))" \
325-
# -f batch-byte-compile $(EL_KOTL) $(EL_COMPILE)
326324
bin: src remove-elc new-bin
327325

328326
# Native compilation (Requires Emacs built with native compilation support.)
329327
eln: src
330328
HYPB_NATIVE_COMP=yes make new-bin
331329

332-
# Create -l file.el load-file command-line args for each Hyperbole .el file for use in
333-
# eln native compile target below.
334-
LOAD_EL = $(shell echo "$(EL_KOTL) $(EL_COMPILE)" | sed -e 's+^+./+' -e 's+ + -l ./+g' -e 's+^+-l +')
335-
336-
load-hyperbole:
337-
$(EMACS_BATCH) \
338-
$(LOAD_EL)
339-
340330
tags: TAGS
341331
TAGS: $(EL_TAGS)
342332
$(ETAGS) --regex='/(ert-deftest[ \t]+\([^ \t\n\r\f()]+\) ?/' $(EL_TAGS)
@@ -520,4 +510,4 @@ package-lint:
520510
--eval "(setq package-lint-main-file \"hyperbole.el\")" \
521511
--eval "(load-file \"test/hy-test-dependencies.el\")" \
522512
-l package-lint.el -f package-lint-batch-and-exit \
523-
$(EL_KOTL) $(EL_COMPILE)
513+
$(EL_KOTL) $(EL_SRC)

hsys-org-roam.el

+1-8
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
;; Author: Bob Weiner
44
;;
55
;; Orig-Date: 26-Feb-23 at 11:20:15 by Bob Weiner
6-
;; Last-Mod: 23-Apr-23 at 22:05:38 by Mats Lidell
6+
;; Last-Mod: 6-Oct-23 at 00:11:40 by Mats Lidell
77
;;
88
;; SPDX-License-Identifier: GPL-3.0-or-later
99
;;
@@ -54,12 +54,5 @@ Prompt for the search pattern."
5454

5555
(provide 'hsys-org-roam)
5656

57-
;; Don't byte-compile since may not have org-roam package and then
58-
;; will get an 'org-roam-directory' undefined error.
59-
60-
;; Local Variables:
61-
;; no-byte-compile: t
62-
;; End:
63-
6457
;;; hsys-org-roam.el ends here
6558

0 commit comments

Comments
 (0)