summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Source/cmTarget.cxx8
1 files changed, 7 insertions, 1 deletions
diff --git a/Source/cmTarget.cxx b/Source/cmTarget.cxx
index dfdde50..a3fb589 100644
--- a/Source/cmTarget.cxx
+++ b/Source/cmTarget.cxx
@@ -693,6 +693,12 @@ void cmTarget::SetProperty(const char* prop, const char* value)
void cmTarget::UpdateLocation()
{
+ // make sure we have a makefile
+ if (!m_Makefile)
+ {
+ return;
+ }
+
// set the LOCATION property of the target
std::string target_location;
switch( this->GetType() )
@@ -712,7 +718,7 @@ void cmTarget::UpdateLocation()
}
if ( target_location.size() == 0 )
{
- target_location += m_Makefile->GetCurrentOutputDirectory();
+ target_location += m_Makefile->GetStartOutputDirectory();
}
if ( target_location.size() > 0 )
{