scel: add option to install without bytecode compilation

Signed-off-by: Tim Blechmann <tim@klingt.org>
This commit is contained in:
Tim Blechmann 2012-03-04 17:37:24 +01:00
parent 67d100d7d7
commit dfb69f398b

View file

@ -3,6 +3,8 @@ if(NOT EMACS_EXECUTABLE)
message(SEND_ERROR "Emacs could not be found") message(SEND_ERROR "Emacs could not be found")
endif() endif()
option(SC_EL_BYTECOMPILE "Build emacs-based IDE." ON)
file(GLOB scel_sources file(GLOB scel_sources
RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} *.el) RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} *.el)
@ -17,7 +19,8 @@ endforeach()
set(all_scel_sources ${scel_sources} sclang-vars.el) set(all_scel_sources ${scel_sources} sclang-vars.el)
foreach (el ${all_scel_sources}) if (SC_EL_BYTECOMPILE)
foreach (el ${all_scel_sources})
add_custom_command(OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/${el}c add_custom_command(OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/${el}c
COMMAND ${EMACS_EXECUTABLE} -batch COMMAND ${EMACS_EXECUTABLE} -batch
-L ${CMAKE_CURRENT_BINARY_DIR} -L ${CMAKE_CURRENT_BINARY_DIR}
@ -32,4 +35,8 @@ foreach (el ${all_scel_sources})
install(FILES ${CMAKE_CURRENT_BINARY_DIR}/${el}c install(FILES ${CMAKE_CURRENT_BINARY_DIR}/${el}c
DESTINATION share/emacs/site-lisp/SuperCollider) DESTINATION share/emacs/site-lisp/SuperCollider)
endforeach() endforeach()
else()
install (FILES ${scel_sources} ${CMAKE_CURRENT_BINARY_DIR}/sclang-vars.el
DESTINATION share/emacs/site-lisp/SuperCollider)
endif()