mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-07 02:28:35 +00:00
57ca9ee073
1.) Filenames for export changed 2.) Usage of wmctrl 3.) More temporary file to remove
25 lines
710 B
CMake
Executable File
25 lines
710 B
CMake
Executable File
|
|
file(GLOB lyx_files "${LYX_ROOT}/lib/doc/*.lyx")
|
|
message(STATUS "lyx_files = ${lyx_files}")
|
|
|
|
set(ERRORS)
|
|
foreach(format lyx16x xhtml)
|
|
foreach(f ${lyx_files})
|
|
message(STATUS "Executing ${lyx} -E ${format} localtest.${format} ${f}")
|
|
execute_process(COMMAND ${CMAKE_COMMAND} -E remove localtest.xhtml localtest.16.lyx)
|
|
execute_process(
|
|
COMMAND ${lyx} -E ${format} localtest.${format} ${f}
|
|
RESULT_VARIABLE _err)
|
|
string(COMPARE NOTEQUAL ${_err} 0 _erg)
|
|
if(_erg)
|
|
list(APPEND ERRORS "Exporting ${f} to ${format}")
|
|
endif()
|
|
endforeach()
|
|
endforeach()
|
|
if(ERRORS)
|
|
foreach(m ${ERRORS})
|
|
message(STATUS ${m})
|
|
endforeach()
|
|
message(FATAL_ERROR "Export failed")
|
|
endif()
|