Bug#892979: FLTKConfig.cmake: self-conflicting add_executable(fluid IMPORTED)
Helmut Grohnewrites: > In any case, this constellation of add_executable is a pretty obvious > bug, because FLTKConfig.cmake includes FLTK-Targets.cmake. It just isn't > obvious how to fix it. Thanks for the report! AFAICT, simply commenting out (or further conditionalizing) FLTKConfig.cmake's add_executable call solves the problem; I'll upload a fix soon. -- Aaron M. Ucko, KB1CJC (amu at alum.mit.edu, ucko at debian.org) http://www.mit.edu/~amu/ | http://stuff.mit.edu/cgi/finger/?a...@monk.mit.edu
Bug#892979: FLTKConfig.cmake: self-conflicting add_executable(fluid IMPORTED)
Package: libfltk1.3-dev Version: 1.3.4-6 User: helm...@debian.org Usertags: rebootstrap Control: affects -1 + src:yoshimi yoshimi fails to cross build from source. The relevant part of the build failure looks like this: | CMake Error at /usr/lib/fltk/FLTKConfig.cmake:32 (add_executable): | add_executable cannot create imported target "fluid" because another target | with the same name already exists. | Call Stack (most recent call first): | /usr/share/cmake-3.10/Modules/FindFLTK.cmake:136 (include) | CMakeLists.txt:244 (find_package) As it happens libfltk1.3-dev ships add_executable(fluid IMPORTED) twice. Once in /usr/lib/fltk/FLTKConfig.cmake:32 and another time in /usr/lib/fltk/FLTK-Targets.cmake:59. They should somehow agree on who adds it. Potentially, the whole "if(CMAKE_CROSSCOMPILING)" block in FLTKConfig.cmake is completely untested and should be discarded in favour of the native way. Unfortunately, I understand too little CMake to fix this, so this bug report sadly comes without a patch. Can you help me find a solution? In any case, this constellation of add_executable is a pretty obvious bug, because FLTKConfig.cmake includes FLTK-Targets.cmake. It just isn't obvious how to fix it. Helmut