MantisBT - CMake
View Issue Details
0014722CMake(No Category)public2014-01-27 15:402016-04-17 15:46
Felix Schwitzer 
Alex Neundorf 
normalminoralways
closedfixed 
ubuntu 13.10Linux
 
 
0014722: eclipse generator creates invalid .cproject file
When in a project 'find_package(Qt4)' is used, the generated .cproject file is invalid. After opening such a project in eclipse via 'File->import...->existing projects into workspace' eclipse reports repeatedly

[Fatal Error] :24:30: The value of attribute "name" associated with an element type "null" must not contain the '<' character.

slowing down eclipse and filling the terminal from which I started eclipse with garbage.

Minimal CMakeLists.txt in ~/src:
   cmake_minimum_required(VERSION 2.8.11)
   project(ttt)
   find_package(Qt4 REQUIRED)
   include(${QT_USE_FILE})

Generate the project with
    cmake -G"Eclipse CDT4 - Unix Makefiles" ../src
in ~/build and import it into eclipse, started from a terminal to see the output
This only happens if 'include(${QT_USE_FILE})' is present in the CMakeLists.txt

the invalid line in .cproject looks like
    <pathentry kind="mac" name="$<$<NOT:$<CONFIG:Debug>>:QT_NO_DEBUG>" path="" value=""/>
and a xml-editor reports an error (I use emacs with nXML-mode)

The error is preesent in the actual master-branch.
No tags attached.
Issue History
2014-01-27 15:40Felix SchwitzerNew Issue
2014-01-27 15:57Alex NeundorfAssigned To => Alex Neundorf
2014-01-27 15:57Alex NeundorfStatusnew => assigned
2015-04-16 15:50Felix SchwitzerNote Added: 0038535
2016-04-17 15:46Alex NeundorfNote Added: 0040875
2016-04-17 15:46Alex NeundorfStatusassigned => closed
2016-04-17 15:46Alex NeundorfResolutionopen => fixed

Notes
(0038535)
Felix Schwitzer   
2015-04-16 15:50   
This issue has been fixed with

http://www.cmake.org/gitweb?p=cmake.git;a=commit;h=311c0b9 [^]

please resolve/close it as fixed
(0040875)
Alex Neundorf   
2016-04-17 15:46   
It seems Stephen fixed this already in 2014.