MantisBT - CMake
View Issue Details
0015268CMakeModulespublic2014-11-28 11:192015-05-04 09:05
GreatEmerald 
Brad King 
normalminoralways
closedfixed 
LinuxopenSUSE13.1
CMake 3.0.2 
CMake 3.2CMake 3.2 
0015268: FindOpenGL.cmake incorrectly depends on X11 on Linux
Currently on Linux the FindOpenGL.cmake module includes FindX11.cmake. That is not right, because there is little reason to ever link against X11 explicitly, and the checks will outright fail on Wayland. Furthermore, having FindX11 included adds quite a bit more complexity to builds (takes more time, doesn't work if you don't have a C compiler enabled etc.), and projects can always use find_package(X11) manually if need be.
It seems that the blanket check for X11 was added back in 2002, and didn't change much since: https://github.com/Kitware/CMake/commit/079e8469abd4a2b404fd460ff41012e8d8b6fd1d [^]
No tags attached.
Issue History
2014-11-28 11:19GreatEmeraldNew Issue
2014-12-01 11:09Brad KingNote Added: 0037326
2014-12-01 11:09Brad KingAssigned To => Brad King
2014-12-01 11:09Brad KingStatusnew => resolved
2014-12-01 11:09Brad KingResolutionopen => fixed
2014-12-01 11:09Brad KingFixed in Version => CMake 3.2
2014-12-01 11:09Brad KingTarget Version => CMake 3.2
2015-05-04 09:05Robert MaynardNote Added: 0038681
2015-05-04 09:05Robert MaynardStatusresolved => closed

Notes
(0037326)
Brad King   
2014-12-01 11:09   
Thanks. I think the only way to find out if anything really needed this to remove it:

 FindOpenGL: Drop explicit dependency on X11
 http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=d051cbda [^]
(0038681)
Robert Maynard   
2015-05-04 09:05   
Closing resolved issues that have not been updated in more than 4 months.