X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;ds=inline;f=source%2Fpackagemanager.h;h=48c3c16fd4fcbdb486368fa2dfed5147af7f7b8b;hb=373e9bb43c24d38316c5bb0393f4a369563319d3;hp=9fb373ec48152b70a16a5e56b93604c08176b38c;hpb=7c61a1e64153bac91431e1a72d946208dd61eb30;p=builder.git diff --git a/source/packagemanager.h b/source/packagemanager.h index 9fb373e..48c3c16 100644 --- a/source/packagemanager.h +++ b/source/packagemanager.h @@ -28,6 +28,7 @@ private: SearchPath binpkg_files; bool no_externals; PackageMap packages; + Package *main_pkg; std::set not_found; bool env_set; @@ -50,6 +51,10 @@ public: /** Returns a package from the cache. */ Package *get_package(const std::string &); + /** Returns the package that was added first. This should be considered + the primary build target. */ + Package &get_main_package() const; + const PackageMap &get_packages() const { return packages; } /** Locates a package and loads it if necessary. */