|
@@ -2298,10 +2298,9 @@ cmLocalUnixMakefileGenerator3::ConvertToQuotedOutputPath(const char* p,
|
|
|
// Now add the rest of the components separated by the proper slash
|
|
// Now add the rest of the components separated by the proper slash
|
|
|
// direction for this platform.
|
|
// direction for this platform.
|
|
|
bool first = true;
|
|
bool first = true;
|
|
|
- for(unsigned int i=1; i < components.size(); ++i)
|
|
|
|
|
|
|
+ for(unsigned int i=1; i < components.size() - 1; ++i)
|
|
|
{
|
|
{
|
|
|
- // Only the last component can be empty to avoid double slashes.
|
|
|
|
|
- if(!components[i].empty() || (i == (components.size()-1)))
|
|
|
|
|
|
|
+ if(!components[i].empty())
|
|
|
{
|
|
{
|
|
|
if(!first)
|
|
if(!first)
|
|
|
{
|
|
{
|
|
@@ -2311,6 +2310,15 @@ cmLocalUnixMakefileGenerator3::ConvertToQuotedOutputPath(const char* p,
|
|
|
first = false;
|
|
first = false;
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
|
|
+ if (components.size() > 1)
|
|
|
|
|
+ {
|
|
|
|
|
+ // Only the last component can be empty to avoid double slashes.
|
|
|
|
|
+ if(!first)
|
|
|
|
|
+ {
|
|
|
|
|
+ result += slash;
|
|
|
|
|
+ }
|
|
|
|
|
+ result += components.back();
|
|
|
|
|
+ }
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
// Close the quoted result.
|
|
// Close the quoted result.
|