ENH: Support exporting/importing of Framework targets.

- Imported frameworks have the FRAMEWORK property set
  - Added cmTarget::IsFrameworkOnApple method to simplify checks
  - Also remove separate IMPORTED_ENABLE_EXPORTS property and just use ENABLE_EXPORTS since, like FRAMEWORK, it just represents the target type.
  - Document FRAMEWORK keyword in INSTALL command.
  - Updated IMPORTED_LOCATION property documentation for Frameworks
This commit is contained in:
Brad King
2008-01-28 13:05:58 -05:00
parent 3d94b3b717
commit 28ea034737
11 changed files with 62 additions and 65 deletions

View File

@@ -237,10 +237,21 @@ cmExportFileGenerator
default: // should never happen
break;
}
// Mark the imported executable if it has exports.
if(target->IsExecutableWithExports())
{
os << "SET_PROPERTY(TARGET " << targetName
<< " PROPERTY IMPORTED_ENABLE_EXPORTS 1)\n";
<< " PROPERTY ENABLE_EXPORTS 1)\n";
}
// Mark the imported framework. This is done even on non-Apple
// platforms for reference and consistency purposes.
if(target->GetType() == cmTarget::SHARED_LIBRARY &&
target->GetPropertyAsBool("FRAMEWORK"))
{
os << "SET_PROPERTY(TARGET " << targetName
<< " PROPERTY FRAMEWORK 1)\n";
}
os << "\n";
}