X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Farchitecture.cpp;h=1f578af409f72ce367f5fb09ee0fa968e5020976;hb=3585dea6eabf5f1565886bf09c2bdb2eee978912;hp=50013e88de7adc955dbb37b10f0ac381edbf65a9;hpb=3772879ebdf452eeb9e8e2c04c07338c4933a3ed;p=builder.git diff --git a/source/architecture.cpp b/source/architecture.cpp index 50013e8..1f578af 100644 --- a/source/architecture.cpp +++ b/source/architecture.cpp @@ -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");