]> git.lyx.org Git - lyx.git/commitdiff
Roundtrip tex2lyx, cmake-build:
authorKornel Benko <kornel@lyx.org>
Mon, 30 Jul 2012 08:04:45 +0000 (10:04 +0200)
committerKornel Benko <kornel@lyx.org>
Mon, 30 Jul 2012 08:04:45 +0000 (10:04 +0200)
1.) test.ltx, test.lyx.tex in build-dir (missed this one in previous commit)
2.) Added dependency to "lyx" to work on clean build dir too

src/tex2lyx/test/CMakeLists.txt

index 19abf65affc38e7222acb51c496ad1e6f2499a23..196a1937cf7bb441bf86c4b7984ac5e631570a51 100644 (file)
@@ -6,8 +6,8 @@
 
 project(test)
 
-set(_test_depend "${TOP_SRC_DIR}/src/tex2lyx/test/test.ltx")
-set(_test_output "${TOP_SRC_DIR}/src/tex2lyx/test/test.lyx.tex")
+set(_test_depend "${CMAKE_CURRENT_BINARY_DIR}/test.ltx")
+set(_test_output "${CMAKE_CURRENT_BINARY_DIR}/test.lyx.tex")
 foreach(_arg runtests.py DummyDocument.tex test.ltx foo.eps foo.png)
   configure_file("${TOP_SRC_DIR}/src/tex2lyx/test/${_arg}" "${CMAKE_CURRENT_BINARY_DIR}/${_arg}" COPYONLY)
 endforeach(_arg)
@@ -29,7 +29,8 @@ ADD_CUSTOM_COMMAND(
   ARGS "${CMAKE_CURRENT_BINARY_DIR}/runtests.py" "${TOP_BINARY_DIR}/bin/${_tex2lyx}" "${TOP_SRC_DIR}/lib/scripts"
   WORKING_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}"
   DEPENDS ${_tex2lyx} ${_test_depend}
+  COMMENT "${LYX_PYTHON_EXECUTABLE}" "${CMAKE_CURRENT_BINARY_DIR}/runtests.py" "${TOP_BINARY_DIR}/bin/${_tex2lyx}" "${TOP_SRC_DIR}/lib/scripts"
 )
 
-ADD_CUSTOM_TARGET(test DEPENDS ${_tex2lyx} ${_test_output})
+ADD_CUSTOM_TARGET(test DEPENDS ${_tex2lyx} ${_lyx} ${_test_output})