View Issue Details Jump to Notes ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0001100CMakepublic2004-08-19 07:492005-02-17 10:52
Reportertom d 
Assigned ToBrad King 
PrioritynormalSeverityminorReproducibilityalways
StatusclosedResolutionfixed 
PlatformOSOS Version
Product Version 
Target VersionFixed in Version 
Summary0001100: small patch to fix the (annoying) make warnings: 'Circular ... dependency dropped'
Descriptionproblem:
if EXECUTABLE_OUTPUT_PATH is a relative path, then cmake adds an additional
empty dependency to the Makefile
 ${TARGET} : ${TARGET_WITH_RELATIVE_PATH}

the problem is though that if the relative path is "." then the Makefile
contains a circular dependency. This leads to make warning
about this while compiling, all the time.

solution:
the easiest fix is to do an easy string test to see if target and
dependfile are the same

to do this one adds a single line near the end of the method
cmLocalUnixMakefileGenerator::OutputExecutableRule in the
file cmLocalUnixMakefileGenerator.cxx, approx. line 1534

above the last call of this->OutputMakeRulethis->OutputMakeRule(...)
add the line: if("./"+target!=depend)

effect:
the last call of this->OutputMakeRule does not create the Makefile entries
if they are circular.
(it's not 100% proof since I could also have a longer relative path leading
to "." also but it fixes 99% of the cases...)
TagsNo tags attached.
Attached Files

 Relationships

  Notes
(0002051)
Brad King (manager)
2005-02-10 08:23

Fixed in CVS version:

/cvsroot/CMake/CMake/Source/cmLocalUnixMakefileGenerator.cxx,v <-- cmLocalUnixMakefileGenerator.cxx
new revision: 1.196; previous revision: 1.195

Basically using a relative path for an output path should be expanded by CMake into a path relative to each build directory.


 Issue History
Date Modified Username Field Change


Copyright © 2000 - 2018 MantisBT Team