From: Mikko Rasa Date: Sat, 21 Apr 2012 19:33:34 +0000 (+0300) Subject: Derive BuildInfo::Loader from ObjectLoader X-Git-Url: http://git.tdb.fi/?a=commitdiff_plain;h=0bf7d92472d829d21fc5901060cab4e032170a4b;p=builder.git Derive BuildInfo::Loader from ObjectLoader --- diff --git a/source/buildinfo.cpp b/source/buildinfo.cpp index 0ac20c9..e9dcec0 100644 --- a/source/buildinfo.cpp +++ b/source/buildinfo.cpp @@ -67,7 +67,7 @@ void BuildInfo::unique() BuildInfo::Loader::Loader(BuildInfo &bi): - binfo(bi) + DataFile::ObjectLoader(bi) { add("cflag", &Loader::cflag); add("incpath", &Loader::incpath); @@ -80,35 +80,35 @@ BuildInfo::Loader::Loader(BuildInfo &bi): void BuildInfo::Loader::cflag(const std::string &s) { - binfo.cflags.push_back(s); + obj.cflags.push_back(s); } void BuildInfo::Loader::incpath(const std::string &s) { - binfo.incpath.push_back(s); + obj.incpath.push_back(s); } void BuildInfo::Loader::define(const std::string &s) { - binfo.defines.push_back(s); + obj.defines.push_back(s); } void BuildInfo::Loader::ldflag(const std::string &s) { - binfo.ldflags.push_back(s); + obj.ldflags.push_back(s); } void BuildInfo::Loader::libpath(const std::string &s) { - binfo.libpath.push_back(s); + obj.libpath.push_back(s); } void BuildInfo::Loader::library(const std::string &s) { - binfo.libs.push_back(s); + obj.libs.push_back(s); } void BuildInfo::Loader::warning(const std::string &s) { - binfo.warnings.push_back(s); + obj.warnings.push_back(s); } diff --git a/source/buildinfo.h b/source/buildinfo.h index 11de3b0..0d7b64a 100644 --- a/source/buildinfo.h +++ b/source/buildinfo.h @@ -3,7 +3,7 @@ #include #include -#include +#include #include "misc.h" /** @@ -13,11 +13,8 @@ form. Allows combining with other BuildInfos to support package dependencies. class BuildInfo { public: - class Loader: public Msp::DataFile::Loader + class Loader: public Msp::DataFile::ObjectLoader { - private: - BuildInfo &binfo; - public: Loader(BuildInfo &); private: