Crascit/DownloadProject

gmake: No rule to make target error with cmake 3.6.3

Closed this issue · 4 comments

The UPDATE_DISCONNECTED command is broken in cmake 3.5 and cmake 3.6. Here is the bug report: https://cmake.org/Bug/view.php?id=15904. Currently its use is recommended in your docs:

https://github.com/Crascit/DownloadProject/blob/master/DownloadProject.cmake#L58

Please consider removing this advice.

Thanks for reminding me of this one (I had already commented on the original bug report you linked to). I've poked the CMake devs about this and there's some discussion going on about it on their gitlab instance where their bug reports have moved to. You can follow along here if you want. I'll wait until that discussion has run its course before deciding what changes to make here.

The discussions in the relevant Kitware issues, merge requests and commits seem to indicate that this issue was fixed in CMake 3.6, but your comments suggest you still see it with CMake 3.6.3. Can you please confirm that you do in fact still see it with 3.6.3? If you do, can you provide a reproducible example to Kitware so they can see what's still left to address (attach it to the bug you referenced but on the gitlab issue instead)

As mentioned by Brad King, there is still an issue that UPDATE_DISCONNECTED does not work with empty update steps in CMake 3.6. This is exactly the case for DownloadProject. Brad posted a fix, but I think that fix is not in any release yet. As is, the CMakeLists.txt example from DownloadProject should fail with CMake 3.6. So it is misleading that you add a comment saying there was a problem only prior to CMake 3.6.

Indeed, I saw that second issue but misread where it's fix was applied to. Updated commit coming shortly.