Skip to content

Commit

Permalink
[style] make lines shorter
Browse files Browse the repository at this point in the history
  • Loading branch information
wjwwood committed May 22, 2018
1 parent ca48992 commit dd14240
Showing 1 changed file with 11 additions and 2 deletions.
13 changes: 11 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -63,12 +63,21 @@ configure_file(
set(rcutils_module_path ${CMAKE_CURRENT_SOURCE_DIR})
set(python_code
"import em"
"em.invoke(['-o', 'include/rcutils/logging_macros.h', '-D', 'rcutils_module_path=\"${rcutils_module_path}\"', '${CMAKE_CURRENT_SOURCE_DIR}/resource/logging_macros.h.em'])")
"\
em.invoke( \
[ \
'-o', 'include/rcutils/logging_macros.h', \
'-D', 'rcutils_module_path=\"${rcutils_module_path}\"', \
'${CMAKE_CURRENT_SOURCE_DIR}/resource/logging_macros.h.em' \
] \
)")
string(REPLACE ";" "$<SEMICOLON>" python_code "${python_code}")
add_custom_command(OUTPUT include/rcutils/logging_macros.h
COMMAND ${CMAKE_COMMAND} -E make_directory "include/rcutils"
COMMAND ${PYTHON_EXECUTABLE} ARGS -c "${python_code}"
DEPENDS "${CMAKE_CURRENT_BINARY_DIR}/logging_macros.h.em.watch" "${CMAKE_CURRENT_BINARY_DIR}/logging.py.watch"
DEPENDS
"${CMAKE_CURRENT_BINARY_DIR}/logging_macros.h.em.watch"
"${CMAKE_CURRENT_BINARY_DIR}/logging.py.watch"
COMMENT "Expanding logging_macros.h.em"
VERBATIM
)
Expand Down

0 comments on commit dd14240

Please sign in to comment.