ENH: Patch from Toni Timonen to allow cross-compiling of DLLs.
This commit is contained in:
parent
64231a20a2
commit
d458764791
|
@ -367,6 +367,11 @@ bool cmInstallCommand::HandleTargetsMode(std::vector<std::string> const& args)
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Check whether this is a DLL platform.
|
||||||
|
bool dll_platform = (this->Makefile->IsOn("WIN32") ||
|
||||||
|
this->Makefile->IsOn("CYGWIN") ||
|
||||||
|
this->Makefile->IsOn("MINGW"));
|
||||||
|
|
||||||
// Compute destination paths.
|
// Compute destination paths.
|
||||||
std::string archive_dest;
|
std::string archive_dest;
|
||||||
std::string library_dest;
|
std::string library_dest;
|
||||||
|
@ -389,7 +394,8 @@ bool cmInstallCommand::HandleTargetsMode(std::vector<std::string> const& args)
|
||||||
// platforms. All windows platforms are DLL platforms
|
// platforms. All windows platforms are DLL platforms
|
||||||
// including cygwin. Currently no other platform is a DLL
|
// including cygwin. Currently no other platform is a DLL
|
||||||
// platform.
|
// platform.
|
||||||
#if defined(_WIN32) || defined(__CYGWIN__)
|
if(dll_platform)
|
||||||
|
{
|
||||||
// This is a DLL platform.
|
// This is a DLL platform.
|
||||||
if(archive_destination)
|
if(archive_destination)
|
||||||
{
|
{
|
||||||
|
@ -409,7 +415,9 @@ bool cmInstallCommand::HandleTargetsMode(std::vector<std::string> const& args)
|
||||||
runtime_configurations,
|
runtime_configurations,
|
||||||
runtime_component.c_str()));
|
runtime_component.c_str()));
|
||||||
}
|
}
|
||||||
#else
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
// This is a non-DLL platform.
|
// This is a non-DLL platform.
|
||||||
if(library_destination)
|
if(library_destination)
|
||||||
{
|
{
|
||||||
|
@ -428,7 +436,7 @@ bool cmInstallCommand::HandleTargetsMode(std::vector<std::string> const& args)
|
||||||
this->SetError(e.str().c_str());
|
this->SetError(e.str().c_str());
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
#endif
|
}
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case cmTarget::STATIC_LIBRARY:
|
case cmTarget::STATIC_LIBRARY:
|
||||||
|
|
Loading…
Reference in New Issue