Open sheepdestroyer opened 9 years ago
Thanks for reporting this issue, I'll take a look at it.
I know how to fix this issue, since this affects me too (I'm also a Fedora user). I think even the main Fedora distribution (the Workstation, as opposed to the spins) still uses the X libraries for graphics.
On the "CMakeLists.txt" file, add the following lines:
find_package(X11 REQUIRED) target_link_libraries(${NAME} ${X11_LIBRARIES})
If you don't want to bother rewriting CMakeLists.txt, you can grab the fixed "CMakeLists.txt" file on the following pastebin: http://pastebin.com/raw.php?i=XbgSak3Q
However, this file will only work on Linux (that uses X for displaying graphics). Placing it on the main tree would break the code on other OSes.
Also, after compilation, the program will still not work. The reason for that is because the "enumlist.xml" file isn't copied to the folder where the program was build with CMake, so you'll need to manually copy that file to the output folder. This could be added to CMakeLists.txt, but I did not bother.
I have seen this bug months ago. However, I'm shy, and therefore I didn't fill a proper bug report (followed by the fix).
Hi frederico,
sorry for my later answer, and thanks for this detailed comment on how to fix this for issue. I'm currently pretty busy with other stuff, so I don't know when I'll get around incorporating this, but just wanted to let you know that it's still on my radar.
And thanks for submitting the mesa reports :+1:
@frederico-miranda As a data point, it's possible to put platform specific bits into a CMakeLists.txt.
For stuff that's just for Linux/BSD/similar, something like this would probably work:
if(UNIX AND NOT APPLE)
#X11
find_package(X11 REQUIRED)
target_link_libraries(${NAME} ${X11_LIBRARIES})
endif(UNIX AND NOT APPLE)
Note that the indentation there is tabs and not spaces. I don't remember off hand if that's important or not, as I don't personally touch CMake bits very often. I just happened to remember this thing about platform specific stuff. :smile: