Skip to content

Commit e04a3d7

Browse files
dimpasecodex
andcommitted
Keep M2-emacs target available when package is skipped
Preserve explicit CI and build-script invocations with an empty target when Emacs or its submodule is unavailable. Co-authored-by: Codex <noreply@openai.com>
1 parent fa63096 commit e04a3d7

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

M2/Macaulay2/editors/CMakeLists.txt

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,9 +32,11 @@ add_custom_command(OUTPUT ${GRAMMAR_FILES}
3232

3333
find_program(EMACS NAMES emacs)
3434
if(NOT EMACS)
35-
message(STATUS "Emacs not found; skipping M2-emacs target")
35+
message(STATUS "Emacs not found; skipping Emacs package")
36+
add_custom_target(M2-emacs)
3637
elseif(NOT EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/emacs/make-M2-emacs-help.m2)
37-
message(WARNING "Macaulay2/editors/emacs submodule is missing; skipping M2-emacs target")
38+
message(WARNING "Macaulay2/editors/emacs submodule is missing; skipping Emacs package")
39+
add_custom_target(M2-emacs)
3840
else()
3941
# TODO: only the emacs target is installed in usr-dist by default
4042
set(M2_INSTALL_EMACSDIR

0 commit comments

Comments
 (0)