X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;ds=sidebyside;f=source%2Farchitecture.cpp;h=c2e91620de962b3246de8cf4f28434fe3fc53f94;hb=4629d189a531c962cf15a511df787f30c3adcb02;hp=50013e88de7adc955dbb37b10f0ac381edbf65a9;hpb=329dc80e392faf7354338621e73dba1880fc767d;p=builder.git diff --git a/source/architecture.cpp b/source/architecture.cpp index 50013e8..c2e9162 100644 --- a/source/architecture.cpp +++ b/source/architecture.cpp @@ -1,7 +1,7 @@ /* $Id$ This file is part of builder -Copyright © 2006-2007 Mikko Rasa, Mikkosoft Productions +Copyright © 2007-2009 Mikko Rasa, Mikkosoft Productions Distributed under the LGPL */ @@ -11,9 +11,10 @@ Distributed under the LGPL using namespace std; using namespace Msp; -Architecture::Architecture(Builder &b, const string &n): +Architecture::Architecture(Builder &b, const string &n, bool a): builder(b), - name(n) + name(n), + native(a) { } void Architecture::set_tool(const string &t, const string &p) @@ -32,10 +33,10 @@ std::string Architecture::get_tool(const string &t) const return i->second; } - if(name!="native") + if(!native) { - const Architecture &native=builder.get_architecture("native"); - return prefix+"-"+native.get_tool(t); + const Architecture &native_arch=builder.get_native_arch(); + return prefix+"-"+native_arch.get_tool(t); } else throw KeyError("Unknown tool");