Hello,
when I run qmllint from the command line to test an error I get:
C:\Tests>C:\Qt\5.6\msvc2015\bin\qmllint.exe test.qml
test.qml:1 : Syntax error
C:\Tests>echo %ERRORLEVEL%
-1
C:\Tests>
If I call this from a CMake script
execute_process(COMMAND C:/Qt/5.6/msvc2015/bin/qmllint.exe C:/Tests/test.qml
RESULT_VARIABLE _resVar
OUTPUT_VARIABLE _outVar
ERROR_VARIABLE _errVar
OUTPUT_STRIP_TRAILING_WHITESPACE
ERROR_STRIP_TRAILING_WHITESPACE)
message("_resVar: ${_resVar}")
message("_outVar: ${_outVar}")
message("_errVar: ${_errVar}")
The output is:
1> _resVar: -1
1> _outVar:
1> _errVar:
It seems that the error pipe isn’t read correctly, because _errVar is empty.
And hints?
Regards
Roman
--
Powered by www.kitware.com
Please keep messages on-topic and check the CMake FAQ at:
http://www.cmake.org/Wiki/CMake_FAQ
Kitware offers various services to support the CMake community. For more
information on each offering, please visit:
CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html
Visit other Kitware open-source projects at
http://www.kitware.com/opensource/opensource.html
Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake-developers