MantisBT - CMake
View Issue Details
0014398CMakeModulespublic2013-09-10 23:072014-03-05 09:58
Jean-Christophe Fillion-Robin 
Brad King 
normalminoralways
closedfixed 
 
CMake 2.8.12CMake 2.8.12 
0014398: FindPNG - Fixes for /Bug/view.php?id=14301 breaks backward compatibility
For details see http://viewvc.slicer.org/viewvc.cgi/Slicer4?view=revision&revision=22411 [^]

The module FindPNG should still be able to understand the option -DPNG_LIBRARY

No tags attached.
related to 0014416closed Brad King FindPNG prints out debugging information 
patch 0001-FindPNG-Honor-old-PNG_LIBRARY-if-provided-14398.patch (2,071) 2013-09-13 11:57
https://public.kitware.com/Bug/file/4877/0001-FindPNG-Honor-old-PNG_LIBRARY-if-provided-14398.patch
Issue History
2013-09-10 23:07Jean-Christophe Fillion-RobinNew Issue
2013-09-11 08:29Brad KingAssigned To => Rolf Eike Beer
2013-09-11 08:29Brad KingStatusnew => assigned
2013-09-13 11:57Brad KingFile Added: 0001-FindPNG-Honor-old-PNG_LIBRARY-if-provided-14398.patch
2013-09-13 11:57Brad KingNote Added: 0033818
2013-09-13 11:58Brad KingTarget Version => CMake 2.8.12
2013-09-13 11:58Brad KingDescription Updatedbug_revision_view_page.php?rev_id=1259#r1259
2013-09-13 13:03Rolf Eike BeerNote Added: 0033820
2013-09-13 13:06Brad KingNote Added: 0033821
2013-09-13 13:07Brad KingNote Added: 0033822
2013-09-16 08:58Brad KingNote Added: 0033828
2013-09-16 09:50Rolf Eike BeerNote Added: 0033830
2013-09-16 09:53Brad KingNote Added: 0033831
2013-09-16 12:46Rolf Eike BeerNote Added: 0033832
2013-09-16 12:49Brad KingNote Added: 0033833
2013-09-16 14:17Rolf Eike BeerNote Added: 0033835
2013-09-16 14:17Rolf Eike BeerAssigned ToRolf Eike Beer => Brad King
2013-09-16 15:34Jean-Christophe Fillion-RobinNote Added: 0033836
2013-09-16 16:04Brad KingStatusassigned => resolved
2013-09-16 16:04Brad KingResolutionopen => fixed
2013-09-16 16:04Brad KingFixed in Version => CMake 2.8.12
2013-09-16 16:05Brad KingRelationship addedrelated to 0014416
2014-03-05 09:58Robert MaynardNote Added: 0035259
2014-03-05 09:58Robert MaynardStatusresolved => closed

Notes
(0033818)
Brad King   
2013-09-13 11:57   
Please review and test "0001-FindPNG-Honor-old-PNG_LIBRARY-if-provided-14398.patch".
(0033820)
Rolf Eike Beer   
2013-09-13 13:03   
That would break as it doesn't cache that variable, no? So if it is once specified on the command line it is taken, on the next CMake run it's not set anymore and the default search is started, changing the value.
(0033821)
Brad King   
2013-09-13 13:06   
If it is specified on the command line with -D then it will be cached and used every time.
(0033822)
Brad King   
2013-09-13 13:07   
Re 0014398:0033821: To clarify, "cmake -Dfoo=bar" will put foo in the cache whether it is referenced or used by the project or not.
(0033828)
Brad King   
2013-09-16 08:58   
Change applied here for next RC:

 http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=68160448 [^]

I hope it works since I haven't heard back here.
(0033830)
Rolf Eike Beer   
2013-09-16 09:50   
You probably want to move the next 3 lines (2 lines comment and unset(PNG_FOUND)) into the if, too.
(0033831)
Brad King   
2013-09-16 09:53   
Re 0014398:0033830: The PNG_FOUND still needs to be set below by FPHSA. The other two unset variables set prior to the block in question so they still need to be unset since they are only for local use.
(0033832)
Rolf Eike Beer   
2013-09-16 12:46   
Read the comment ;) PNG_FOUND is unset because it was set by select_library_configurations(), but we want it to be set by FPHSA later.
(0033833)
Brad King   
2013-09-16 12:49   
Re 0014398:0033832: Who cares what set PNG_FOUND before? It still needs to be unset so that FPHSA will set it.
(0033835)
Rolf Eike Beer   
2013-09-16 14:17   
Go for it!
(0033836)
Jean-Christophe Fillion-Robin   
2013-09-16 15:34   
Just tested and it works as expected. Thanks for working on this.
(0035259)
Robert Maynard   
2014-03-05 09:58   
Closing resolved issues that have not been updated in more than 4 months